Spawn Thing
#1

hey guys i have a sistem that is not working well so i will explain it

If you are a Cop and you get spawned you will be automaticaly setted on "OnDuty 0" and if you go "OnDuty 1" and spawn again same you will be automaticaly setted to 0 so i have at my paintball game if you are a Cop you can enter only if you are setted on 0 so after the Cop joins and he die he get's the message like "You are now spawned as off duty!" so ... what i want is to make if the Cop is at paintball to spawn him without the message and his skin 29 i putted lastskin overthere it works but it change's to 29 cause is forced to.

The script under onplayerspawn

Код HTML:
if(IsACop(playerid))
		{
		    if(PlayerPaintballing[playerid] == 1)
		    {
				OnDuty[playerid] = 0;
				SetPlayerColor(playerid,0xFFFFFFFF);
				SetPlayerHealthEx(playerid, 100);
				SetPlayerArmourEx(playerid, 0);
				SetPlayerSkin(playerid, LastSkin[playerid]);
			}
   			else
			{
			    if(OnDuty[playerid] == 1)
				{
				    OnDuty[playerid] = 0;
					SetPlayerColor(playerid,0xFFFFFFFF);
					SetPlayerHealthEx(playerid, 100);
					SetPlayerArmourEx(playerid, 0);
					SetPlayerSkin(playerid, 29);
					SendClientMessage(playerid, COLOR_SYN, "(F) {FFFFFF}Ai fost spawnat ca find off duty!");
				}
				else
				{
				    OnDuty[playerid] = 0;
					SetPlayerColor(playerid,0xFFFFFFFF);
					SetPlayerHealthEx(playerid, 100);
					SetPlayerArmourEx(playerid, 0);
					SetPlayerSkin(playerid, 29);
					SendClientMessage(playerid, COLOR_SYN, "(F) {FFFFFF}Ai fost spawnat ca find off duty!");
				}
			}
		}
when i am in paint and i die or get respawned in that zone from paintball why i get skin 29 if i am at paintball and is 1 and not 0 , why ?

EDIT: now i am not getting the message anymore but the skin is still setted on 29, pls help
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)