CabCon

Head Administrator
Staff member
Head Staff Team
Messages
5,093
Reaction score
2,881
Points
1,103
Is there a way to see when a player melees (a notify like reload_start)? And who he melees?
You can use self meleeButtonPressed() to get when someone is knifing. For what exactly do you want to use the script? :smile:

Regards,
CabCon.
 

request_method

New Member
Messages
4
Reaction score
1
Points
3
If I use self meleeButtonPressed() I'd have to do something like this:
Code:
function example()
{
    for(;;)
    {
        if(self meleeButtonPressed())
            self thread doDamageToPlayer(); //to the player I hit

        //wait until I can knife someone again
    }
}

//or

function example()
{
    while(self meleeButtonPressed())
    {
        self thread doDamageToPlayer();
        //wait until I can knife someone again
    }
}
You could say I'm trying to increase melee damage or kill any player by knifing him
 
Last edited:

CabCon

Head Administrator
Staff member
Head Staff Team
Messages
5,093
Reaction score
2,881
Points
1,103
If I use self meleeButtonPressed() I'd have to do something like this:
Code:
function example()
{
    for(;;)
    {
        if(self meleeButtonPressed())
            self thread doDamageToPlayer(); //to the player I hit

        //wait until I can knife someone again
    }
}

//or

function example()
{
    while(self meleeButtonPressed())
    {
        self thread doDamageToPlayer();
        //wait until I can knife someone again
    }
}
You could say I'm trying to increase melee damage or kill any player by knifing him
So you want to kill someone with just one melee? :smile:
 
Top