14.02.2011, 05:36
Hey. I got a little problem with random spawn, I got only warnings (no errors). Here's code:
And the problem is tag mismatch in the coordinates. Can anyone change it to no-warnings code?
Код:
new Float:RandomSpawn[][4] = {
{419.800018,2531.705322,16.157726,180},
{2041.805,-3113.831,7.442,180},
{1319.23620600,1254.57458500,10.37386700,0}
};
Код:
public OnPlayerSpawn(playerid)
{
new rands = random(sizeof(RandomSpawn));
SetPlayerPos(playerid, RandomSpawn[rands][0], RandomSpawn[rands][1], RandomSpawn[rands][2]);
SetPlayerFacingAngle(playerid, RandomSpawn[rands][3]);
return 1;
}

