Raised This Month: $51 Target: $400
 12% 

Nade trail


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
MuzzMikkel
Member
Join Date: Aug 2010
Location: Denmark
Old 06-04-2011 , 02:31   Nade trail
Reply With Quote #1

I really wanted to get some nice trail on my awp model hero with Super Nade XD
If anybody would help
MuzzMikkel is offline
Send a message via MSN to MuzzMikkel
RollerBlades
Senior Member
Join Date: Feb 2011
Location: Sweden
Old 06-04-2011 , 02:46   Re: Nade trail
Reply With Quote #2

search before posting
RollerBlades is offline
MuzzMikkel
Member
Join Date: Aug 2010
Location: Denmark
Old 06-04-2011 , 05:41   Re: Nade trail
Reply With Quote #3

Quote:
Originally Posted by RollerBlades View Post
search before posting
so i found some nade trail and its working but, i added a bot and he does have the nade trail too, without the hero. How do i fix that?

PHP Code:
#include <superheromod> 

new gHeroID 
new gHasAwpLover[SH_MAXSLOTS+1
new const 
gAwpLoverAwp[] = "models/shmod/AwpLover_awp.mdl" 
new const gAwpLoverDeagle[] = "models/shmod/AwpLover_deagle.mdl"  
new const gAwpLoverPlayer[] = "models/player/AwpLover/AwpLover.mdl" 
new const gAwpLoverNade[] = "models/shmod/AwpLover_hegrenade.mdl"

new g_cvar_tr
new g_cvar_he
new g_trail

public plugin_init() 

    
register_plugin("SUPERHERO AwpLover""1.1""MuzzMikkel"
    
    new 
pcvarLevel register_cvar("AwpLover_level""4"
    new 
pcvarHealth register_cvar("AwpLover_health""350"
    new 
pcvarArmor register_cvar("AwpLover_armor""800"
    new 
pcvarSpeed register_cvar("AwpLover_speed""320"
    new 
pcvarGrav register_cvar("AwpLover_grav""0.7"
    new 
pcvarAwpMult register_cvar("AwpLover_awpmult""40.0"
    new 
pcvarDeagleMult register_cvar("AwpLover_deaglemult""10.0")
    new 
pcvarNadeMult register_cvar("AwpLover_hegrenademult""50.0")
    
g_cvar_tr register_cvar("AwpLover_grenade_tr""2")
    
g_cvar_he register_cvar("AwpLover_grenade_he""3413934")
    
    
gHeroID sh_create_hero("AwpLover"pcvarLevel
    
sh_set_hero_info(gHeroID"Awp Lover!""Get's a powerfull Awp / deagle that does 1shot1kill! + super nade"
    
    
sh_set_hero_dmgmult(gHeroIDpcvarAwpMultCSW_AWP
    
sh_set_hero_dmgmult(gHeroIDpcvarDeagleMultCSW_DEAGLE
    
sh_set_hero_dmgmult(gHeroIDpcvarNadeMultCSW_HEGRENADE)
    
sh_set_hero_hpap(gHeroIDpcvarHealthpcvarArmor
    
sh_set_hero_speed(gHeroIDpcvarSpeed
    
sh_set_hero_grav(gHeroIDpcvarGrav
    
    
register_event("CurWeapon""weapon_change""be""1=1"
    


public 
sh_hero_init(idheroIDmode

    if ( 
gHeroID != heroID ) return 
    
    switch(
mode
    { 
        case 
SH_HERO_ADD
        { 
            
gHasAwpLover[id] = true 
            AwpLover_weapons
(id
            
switch_model(id
            
AwpLover_morph(id
            
        } 
        
        case 
SH_HERO_DROP
        { 
            
gHasAwpLover[id] = false 
            AwpLover_unmorph
(id
            if (
is_user_alive(id)) 
            { 
                
sh_drop_weapon(idCSW_AWPtrue
                
sh_drop_weapon(idCSW_DEAGLEtrue
                
            } 
        } 
    } 


public 
sh_client_spawn(id

    if (
gHasAwpLover[id]) 
    { 
        
AwpLover_weapons(id
        
AwpLover_morph(id
    } 


public 
weapon_change(id

    
    if ( !
sh_is_active() || !gHasAwpLover[id] ) return   
    
    if(
read_data(2) == CSW_AWP || read_data(2) == CSW_DEAGLE || read_data(2) == CSW_HEGRENADE)
    {
        
switch_model(id
            
        if (
read_data(3) == 0
        { 
            
sh_reload_ammo(id1
        } 
    } 
}
public 
plugin_precache() 

    
precache_model(gAwpLoverAwp)
    
precache_model(gAwpLoverDeagle)
    
precache_model(gAwpLoverNade)
    
precache_model(gAwpLoverPlayer)
    
g_trail precache_model("sprites/laserbeam.spr")


AwpLover_weapons(id

if (
sh_is_active() && is_user_alive(id) && gHasAwpLover[id] ) 

    
sh_give_weapon(idCSW_AWP
    
sh_give_weapon(idCSW_DEAGLE)
    
sh_give_weapon(idCSW_HEGRENADE)



switch_model(id
{
if (!
sh_is_active() || !is_user_alive(id) || !gHasAwpLover[id] ) return  


if ( 
get_user_weapon(id) == CSW_AWP)  

    
set_pev(idpev_viewmodel2gAwpLoverAwp)  


else if ( 
get_user_weapon(id) == CSW_DEAGLE

    
set_pev(idpev_viewmodel2gAwpLoverDeagle)  
}

else if ( 
get_user_weapon(id) == CSW_HEGRENADE

    
set_pev(idpev_viewmodel2gAwpLoverNade)  
    }
}

AwpLover_morph(id

cs_set_user_model(id"AwpLover!"


AwpLover_unmorph(id

cs_reset_user_model(id
}  

public 
grenade_throw(idgidwid)
{
    new 
gtm get_pcvar_num(g_cvar_tr)
    if(!
gtm) return
    new 
rgb
    
switch(gtm)
    {
        case 
1:
        {
            
random(34)
            
random(139)
            
random(34)
        }
        case 
2:
        {
            new 
nadecolor[10]
            switch(
wid)
            {
                case 
CSW_HEGRENADE:    nade g_cvar_he
            
}
            
get_pcvar_string(nadecolor9)
            new 
str_to_num(color)
            
1000000
            c 
%= 1000000 
            g 
1000
            b 
1000
        
}
        case 
3:
        {
            switch(
get_user_team(id))
            {
                case 
1255
                
case 2255
            
}
        }
    }
    
message_begin(MSG_BROADCASTSVC_TEMPENTITY)
    
write_byte(TE_BEAMFOLLOW)
    
write_short(gid)
    
write_short(g_trail)
    
write_byte(10)
    
write_byte(5)
    
write_byte(r)
    
write_byte(g)
    
write_byte(b)
    
write_byte(192)
    
message_end()

MuzzMikkel is offline
Send a message via MSN to MuzzMikkel
The Art of War
Veteran Member
Join Date: Dec 2009
Location: Sweden Rock Festival
Old 06-04-2011 , 06:28   Re: Nade trail
Reply With Quote #4

For starters, stop posting completely unncessary threads please.

Secondly, perhaps you should start with a check if the user has the hero?.......................

MSG_BROADCAST will see too it that all players can see the effect, but you have to make a check if the user has the hero if you dont want everyone to have a trail.


PHP Code:
if ( gHasAwpLover[id] )
{} 
or

PHP Code:
if ( !gHasAwpLover[id] ) return 
Stop posting random crap. As you can see, you could have done that with some easy searching and a "has hero check", which is the most basic thing ever in SHMod.
__________________
The Art of War is offline
jonpeter001
BANNED
Join Date: Jun 2011
Old 06-29-2011 , 07:06   Re: Nade trail
Reply With Quote #5

here is a little mod to put straight into your main folder hope you like it have fun!!!!:classic: :classic: :classic: Second mitochondria-derived activator of caspase (Smac) has been implicated in the activation of apoptosis in response to cell stress. We screened for Smac/DIABLO-binding protein for further understanding of Smac-mediated apoptosis. We identified NADE, previously known as p75NTR-associated cell death executor, as a Smac-binding protein. Smac-NADE interaction was mapped to the N-terminal region of Samc and the C-terminal region of NADE. Co-expression of NADE and Smac promotes TRAIL-induced apoptosis in MCF-7 cells. Interestingly, the co-presence of Smac and NADE inhibits XIAP-mediated Smac ubiquitination. In conclusion, our results provide the first evidence that the interaction between Smac and NADE regulates apoptosis through the inhibition of Smac ubiquitination.
jonpeter001 is offline
Reply



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 14:21.


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