Quote:
Originally Posted by Shadow_
pawn Code:
public OnPlayerConnect(playerid) { new pName[MAX_PLAYER_NAME]; GetPlayerName(playerid, pName, sizeof(pName)); if(strcmp(pName, "Test", true) || strcmp(pName, "Test1", true) || strcmp(pName, "test2", true)) { ShowPlayerDialog(playerid, 1, DIALOG_STYLE_INPUT, "Password", "Please enter the server password", "Enter", "Quit"); } return 1; }
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[]) { if(dialogid == 1) { if(response) { new password = strval(inputtext); if(password == strval("Testing")) { // GivePlayerAdmin } else return Kick(playerid); } else return Kick(playerid); } return 1; }
Not tested it, not even sure if it will work. but i imagine it will be something very similar to that.
|
I Will test it after lunch and tell here if it works! Thanks a lot at the moment bro!