How to get victim name?
Hey, I am creating this plugin which blocks vote command from console, but i want to show the people in the server that who is using the command and who is the victim.
I was able to get users name using get_user_id but how do i get victim's name? thank you. |
Re: How to get victim name?
Can you clarify victim? Do you mean dead player? Give an example of what you're trying to do
|
Re: How to get victim name?
I mean, there is a command for client called "vote".
when a player types vote in console a list of joined players with #number appears. they can use the command to kick people like vote #113. I have disabled that command but want to print the message in chat as User1(voter) is trying to kick User2(Victim). I have got user1's ID but dont know how to get user2's. |
Re: How to get victim name?
Check find_player API or cmd_target
|
Re: How to get victim name?
Can you give an example?
|
Re: How to get victim name?
If the hash code(#123) is the actual user id, then just get the name using this value.
Code:
|
Re: How to get victim name?
@Relaxing that will not work. get_user_name() expects a 1-32 client id.
PHP Code:
|
| All times are GMT -4. The time now is 04:43. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.