08.10.2014, 21:57
Hi
How do I make a players marker on the map invisible?
I cant use "ShowPlayerMarkers(0);" because I need it so
when a admin goes on duty it will show the admin on the map.
and then when he goes off admin duty then he will be invisible again...
How do I make a players marker on the map invisible?
I cant use "ShowPlayerMarkers(0);" because I need it so
when a admin goes on duty it will show the admin on the map.
and then when he goes off admin duty then he will be invisible again...
Code:
CMD:adminduty(playerid, params[]) { if(pInfo[playerid][pAdminLevel] < 2) return SendClientMessage(playerid, COLOR_GREY, "You are not authorised to use that command."); if(GetPVarInt(playerid, "AdminDuty") == 0) { new str[126]; SetPlayerColor(playerid, 0xFF9900AA); format(str, sizeof(str), "%s is now on duty.", GetName(playerid)); SendClientMessageToAdmins(COLOR_ORANGE, str, 1); SendClientMessageToAll(COLOR_ORANGE, "There is an admin on duty."); SetPVarInt(playerid, "AdminDuty", 1); return 1; } if(GetPVarInt(playerid, "AdminDuty") == 1) { new str[126]; SetPlayerColor(playerid, 0xFFFFFFFF); format(str, sizeof(str), "%s is now off duty.", GetName(playerid)); SendClientMessageToAdmins(COLOR_ORANGE, str, 1); SetPVarInt(playerid, "AdminDuty", 0); } return 1; }