08.11.2016, 09:07
So look, im trying to make a coinflip thingy, and idk whats happening to this, i've i already read:https://sampwiki.blast.hk/wiki/random, i tried following whats there, but im getting errorz.
My new stuff
THE STUFF I MADE:
MY ERRORS:
Can Anyone help me?
My new stuff
Код:
new value = random(2);
new string1[128];
new Float:RandomSpawn[][2] =
{
{"%s flipped a coin! landed on heads"};
{"%s flipped a coin! landed on tails"};
};
Код:
if (strcmp("/coin", cmdtext, true, 10) == 0)
{
new name[128];
new string[128];
GetPlayerName(playerid,name,128);
format(string, sizeof(name), RandomSpawn[0], RandomSpawn[1], GetPlayerName);
SendClientMessageToAll(0xA586B8FF, name);
return 1;
}
Код:
C:\Users\PC1\Desktop\CZCNRSF\CZCNRSF\CNRSF\filterscripts\flipcoin.pwn(122) : error 017: undefined symbol "RandomSpawn" C:\Users\PC1\Desktop\CZCNRSF\CZCNRSF\CNRSF\filterscripts\flipcoin.pwn(122) : warning 215: expression has no effect C:\Users\PC1\Desktop\CZCNRSF\CZCNRSF\CNRSF\filterscripts\flipcoin.pwn(122) : error 001: expected token: ";", but found "]" C:\Users\PC1\Desktop\CZCNRSF\CZCNRSF\CNRSF\filterscripts\flipcoin.pwn(122) : error 029: invalid expression, assumed zero C:\Users\PC1\Desktop\CZCNRSF\CZCNRSF\CNRSF\filterscripts\flipcoin.pwn(122) : fatal error 107: too many error messages on one line


