Raised This Month: $ Target: $400
 0% 

Player should evade all bullets


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Sylwester
Veteran Member
Join Date: Oct 2006
Location: Poland
Old 06-22-2009 , 15:29   Re: Player should evade all bullets
Reply With Quote #5

You can use traceline if you want...
PHP Code:
public TRIGGER_TraceLine(Float:v1[3], Float:v2[3], noMonsterspentToSkip){
    new 
iAttacker pentToSkip;
    new 
iVictim get_tr(TR_pHit);
    if ( 
iVictim >= && iVictim <= 32 && iAttacker >= && iAttacker <= 32){
        new 
Float:rand random_float(0.0,1.0)
        new 
Float:chance 0.3
        
if (is_user_alive(iVictim) && (rand <= chance)){
            
set_tr(TR_flFraction1.0);
            return 
FMRES_SUPERCEDE;
        }
    }
    return 
FMRES_IGNORED;

__________________
Impossible is Nothing
Sylwester is offline
 



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 15:32.


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