12.11.2016, 18:10
hey guys i have this sistem but i have a problem if i use /test and someone after me is using is not giving him the message that a mission is already on progress , but if i use it i get a message like i already do a mission
this is the hole script , some ideas?
EDIT: SOLVED
Код HTML:
new OwnerMisiune[MAX_PLAYERS], MisiuneActiva[MAX_PLAYERS]; public OnPlayerConnect(playerid) { OwnerMisiune[playerid] = -1; return 1; } CMD:test(playerid) { if(gLogged[playerid] == 0) return SendClientMessage(playerid, -1, "Tu nu esti logat si nu poti sa folosesti aceasta comanda!"); if(OwnerMisiune[playerid] == 0) return SendClientMessage(playerid, -1, "Nu poti folosi aceasta comanda deoarece faci deja o misiune."); if(MisiuneActiva[playerid] == 1) return SendClientMessage(playerid, -1, "Este deja o misiune in desfasurare, te rog asteapta."); defer ComeBack(playerid); OwnerMisiune[playerid] = 1; MisiuneActiva[playerid] = 1; CreateMisiuneSpecialaObjects(); TogglePlayerControllable(playerid, 0); SetPlayerCameraPos(playerid, 1530.5032, -1703.4867, 18.6505); SetPlayerCameraLookAt(playerid, 1529.7816, -1693.8020, 14.5093); SendClientMessage(playerid, -1, "Vizualizezi locatia obiectului ce trebuie distrus."); return 1; }
EDIT: SOLVED