13.07.2010, 10:55
Could you explain why you're using two varibles? or what they do?
This is a common example, should work / point you in the right direction.
This is a common example, should work / point you in the right direction.
pawn Код:
public OnPlayerSpawn(playerid)
{
if(PlayerInDM[playerid]) // Checking if PlayerInDM is 1, add a ' ! ' infront of the varible to check for 0.
{
new
rand = random(5);
switch(rand)
{
case 1: SetPlayerPos(playerid, 0.0, 0.0, 0.0);
case 2: SetPlayerPos(playerid, 0.0, 0.0, 0.0);
case 3: SetPlayerPos(playerid, 0.0, 0.0, 0.0);
case 4: SetPlayerPos(playerid, 0.0, 0.0, 0.0);
}
return 1;
}