Posts: 53
Threads: 30
Joined: Dec 2017
Reputation:
0
Hello friends I would like to know how to make an anti ban system by names.
Example: Jhon_Miller can not be banned
Posts: 26
Threads: 2
Joined: Sep 2015
Reputation:
0
You could just have an array of names that shouldn't be banned like:
new doNotBanList[] = { "Jhon_Miller", "Harry_Potter", "Stephen_Hawking", "Donald_Trump" };
(been a while since I've used PAWN, might not be correct way to create array)
Then in your ban method or wherever you handle that logic, you can just loop through that array and see if the name matches any in the array. If it does match, then don't ban them.
Posts: 53
Threads: 30
Joined: Dec 2017
Reputation:
0
Sorry if it's in Spanish, I'm Spanish but that's the command.
Posts: 26
Threads: 2
Joined: Sep 2015
Reputation:
0
Okay well can't you figure out what to do after our comments? You can't just expect us to do it for you because you won't learn that way.
Posts: 26
Threads: 2
Joined: Sep 2015
Reputation:
0
Do you mean 'playerid' and not 'giveplayerid' in GetPlayerName(giveplayerid, NombreP, sizeof(NombreP)); ?
You can try printing the value of NombreP to make sure it has got the right player name.
Posts: 53
Threads: 30
Joined: Dec 2017
Reputation:
0
Name checks the name of the player and if the name is Jhon_Miller Not ban