Raised This Month: $ Target: $400
 0% 

Grenade Trails


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
SamuraiBarbi
Senior Member
Join Date: Aug 2006
Location: United States
Old 07-21-2007 , 00:40   Re: Grenade Trails
Reply With Quote #5

awww, i get the feeling it's close but when i compile the following

PHP Code:
#include <amxmodx>
#include <fakemeta>

#define PLUGIN "New Plug-In"
#define VERSION "1.0"
#define AUTHOR "Jim/Drak"
 
new g_cvar_tr
new g_cvar_color
new g_trail

new const gModel[] = "models/rpgrocket.mdl" // CHANGE THIS

public plugin_init() {
    
register_plugin(PLUGINVERSIONAUTHOR)
    
register_forward(FM_SetModel,"forwardSetModel");
    
    
g_cvar_tr register_cvar("amx_grenade_trails""2")
    
g_cvar_color register_cvar("amx_grenade_color""255000000")
    
}

public 
plugin_precache()
{
    
g_trail precache_model("sprites/smoke.spr")
}

public 
forwardSetModel(ent,const model[])
{
    if(
equal(model,gModel)) 
    {
        new 
gtm get_pcvar_num(g_cvar_tr)
        if(!
gtm) return
        new 
rgb
        
switch(gtm)
        {
            case 
1:
            {
                
random(256)
                
random(256)
                
random(256)
            }
            case 
2:
            {
                new 
nadecolor[10]
                
get_pcvar_string(g_cvar_colorcolor9)
                new 
str_to_num(color)
                
1000000
                c 
%= 1000000 
                g 
1000
                b 
1000    
            
}
        }
        
message_begin(MSG_BROADCASTSVC_TEMPENTITY)
        
write_byte(TE_BEAMFOLLOW)
        
write_short(ent)
        
write_short(g_trail)
        
write_byte(10)
        
write_byte(5)
        
write_byte(r)
        
write_byte(g)
        
write_byte(b)
        
write_byte(192)
        
message_end()
    }

i get the following error code

home/groups/amxmodx/tmp3/text0SaysA.sma(0) : error 075: input line too long (after substitutions)
/home/groups/amxmodx/tmp3/text0SaysA.sma(1) : error 038: extra characters on line
/home/groups/amxmodx/tmp3/text0SaysA.sma(1) : error 075: input line too long (after substitutions)
/home/groups/amxmodx/tmp3/text0SaysA.sma(3) : error 001: expected token: ";", but found "-identifier-"
/home/groups/amxmodx/tmp3/text0SaysA.sma(3) : warning 203: symbol is never used: "c"
/home/groups/amxmodx/tmp3/text0SaysA.sma(3) : error 013: no entry point (no public functions)


what does that mean?
SamuraiBarbi is offline
Send a message via AIM to SamuraiBarbi Send a message via MSN to SamuraiBarbi Send a message via Yahoo to SamuraiBarbi
 



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 21:30.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode