Raised This Month: $ Target: $400
 0% 

Block TERRO


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
FiFiX
Senior Member
Join Date: May 2008
Location: Poland
Old 08-05-2010 , 12:05   Block TERRO
Reply With Quote #1

Hello, that's the way I'm blocking TT
Code:
    //block TT
    if (ZONEMODE:zm == ZM_BLOCK_T1 && (userteam == 1)) {
        new Float: velocity[3]
        new Float: DW //Długosc wektora
        entity_get_vector(player,EV_VEC_velocity,velocity)
        DW=vector_length ( velocity )+0.0001
        velocity[0]=(velocity[0]/DW)*(-500.0)
        velocity[1]=(velocity[1]/DW)*(-500.0)
        if(velocity[2]<0) velocity[2]=velocity[2]*(-1.0)+15.0 //wyrzuca do gory
        entity_set_vector(player,EV_VEC_velocity,velocity)

    }
But really it isn;t blocking TT but pushing him away.. Is possiblity to block just TERRO? If is, tell me how
FiFiX is offline
Send a message via Skype™ to FiFiX
FiFiX
Senior Member
Join Date: May 2008
Location: Poland
Old 08-10-2010 , 16:44   Re: Block TERRO
Reply With Quote #2

Someone? Please help me here, beucose it is very important for me and my DR server.
FiFiX is offline
Send a message via Skype™ to FiFiX
naven
Veteran Member
Join Date: Jun 2008
Location: Poland, Cieszyn
Old 08-10-2010 , 17:05   Re: Block TERRO
Reply With Quote #3

In prethink, use:
PHP Code:
if(cs_get_user_team(id) & CS_TEAM_T){
new 
Float:origin[3];
    
pev(idpev_originorigin);
    new 
Float:origin2[3];
    
origin2[0] = -2123.822021;
    
origin2[1] = 1854.680664;
    
origin2[2] = 231.908569;

    if(
get_distance_f(originorigin2) < 75.0)
    {
        
user_kill(id)
        
client_print(idprint_chat"Udalo sie!")
    }
}

75.0 is distance between player and point
__________________
naven.com.pl
"At the end of the day, there are always going to be mental disorders and people who cause violence for no other reason than the fact that they're fucked up and lost. And all we can do is try to learn from it." Corey Taylor.
naven is offline
Reply


Thread Tools
Display Modes

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 00:10.


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