04.03.2012, 21:13
How can I create a gate where the gate opens only if the player has the name i put in the script?
CMD:gate(playerid, params[]) { new name[24]; GetPlayerName(playerid, name, sizeof name); if(strcmp(name, "nigga_please", true) == 0) { //code } return 1; }
new Name[MAX_PLAYER_NAME];
GetPlayerName(playerid, Name, sizeof(Name));
if(!strcmp("GateOwner", Name, false))
{
//stuff in here if the players name is GateOwner
}