Help on blocking player to use a command on himself
#1

Ok, so I have a /Race [Player you want to challange ID] command, but the thing is that you can challange yourself, and when you do such, you go alone, leaving an infinite car there that was supposed to belong to the other player until I restart the server. How can I make something that when you use it on yourself you get a message like "You can't challange yourself!"?

Thanks
Reply
#2

PHP код:
if(targetid == playerid) return SendClientMessage(playerid, -1"You can't challange yourself!"); 
Edit it to meet your command ofc.
Reply
#3

Thanks! It worked like a charm...
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)