Raised This Month: $85 Target: $400
 21% 

Solved Right Моusе Аttасk


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Rhyme
Member
Join Date: Aug 2010
Location: Russia (Moscow)
Old 01-14-2018 , 01:22   Right Моusе Аttасk
Reply With Quote #1

Hello guys Sorry for my bad english. How do I make the client_print work only when victim is die from the right mоusе buttоn, as is known thе knifе has 2 types of attack
PHP Code:
#include <amxmodx>

public plugin_init()
{
    
register_plugin("0""1""2")
    
register_event("DeathMsg""Event_Death""a")
}

public 
Event_Death(id)
{
    new 
iAttackerID read_data(1)
    new 
iVictimID read_data(2)

    if(!
is_user_connected(iAttackerID) || iVictimID == iAttackerID)
        return 
PLUGIN_CONTINUE;

    new 
nameA[33], nameV[33]
    
get_user_name(iAttackerIDnameA32)
    
get_user_name(iVictimIDnameV32)

    
client_print(iAttackerID"[AMXX] You kill %s by аttасk2 mоusе"nameV)

and further still it would be nice to find out how to make it written only when victim is die from attacker which be in air , in jump

Last edited by Rhyme; 01-14-2018 at 04:15.
Rhyme is offline
Send a message via ICQ to Rhyme Send a message via Skype™ to Rhyme
Bugsy
AMX Mod X Moderator
Join Date: Feb 2005
Location: NJ, USA
Old 01-14-2018 , 01:28   Re: Right Моusе Аttасk
Reply With Quote #2

See if this helps: https://forums.alliedmods.net/showthread.php?t=97393
__________________

Last edited by Bugsy; 01-14-2018 at 01:28.
Bugsy is offline
Rhyme
Member
Join Date: Aug 2010
Location: Russia (Moscow)
Old 01-14-2018 , 01:32   Re: Right Моusе Аttасk
Reply With Quote #3

Quote:
Originally Posted by Bugsy View Post
In addition, I would like to still catch the headshot and jump
Oh it has a headshot, but does not have a jump
Bugsy THX Friend)

Last edited by Rhyme; 01-14-2018 at 04:15.
Rhyme is offline
Send a message via ICQ to Rhyme Send a message via Skype™ to Rhyme
TheWhitesmith
Senior Member
Join Date: Oct 2017
Location: Morocco :c
Old 01-14-2018 , 09:43   Re: Right Моusе Аttасk
Reply With Quote #4

PHP Code:
    if( !(pev(attackerpev_flags) & FL_ONGROUND) ) // attacker is not on the ground
        
client_print(victim,print_chat,"[AMXX] That boi got you while in the air."
__________________

Last edited by TheWhitesmith; 01-14-2018 at 09:43. Reason: forgot [/PHP]
TheWhitesmith 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 04:20.


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