[HELP] Armi diverse
#27
Inviato il 29 settembre 2010 - 13:51
il codice di rapa mi da meno errori lol
sicuramente sbaglio io
declaration of a local variable must appear in a compound block
start of function body without function header
invalid function or declaration
la seconda l'ho risolta
sicuramente sbaglio io
declaration of a local variable must appear in a compound block
start of function body without function header
invalid function or declaration
la seconda l'ho risolta
Livello Scripter: Apprendista
#30
Inviato il 29 settembre 2010 - 14:18
Ale_Gta, il 29 settembre 2010 - 14:59 ha detto:
continua a darmi errore
Ditemi dv sbaglio
public OnPlayerSpawn(playerid)
new armacaso = random(1);
asd = (armacaso == 1) ? (31):(30);
{
GivePlayerWeapon(playerid,asd,10000);
return 1;
}
Ditemi dv sbaglio
public OnPlayerSpawn(playerid)
new armacaso = random(1);
asd = (armacaso == 1) ? (31):(30);
{
GivePlayerWeapon(playerid,asd,10000);
return 1;
}
public OnPlayerSpawn(playerid)
{
new armacaso = random(1);
asd = (armacaso == 1) ? (31):(30);
{
GivePlayerWeapon(playerid,asd,10000);
}
return 1;
}
#32
Inviato il 29 settembre 2010 - 14:34
Mozilla, il 29 settembre 2010 - 15:22 ha detto:
public OnPlayerSpawn(playerid)
{
new armacaso = random(1);
new asd = (armacaso == 1) ? (31):(30);
GivePlayerWeapon(playerid,asd,10000);
return 1;
}
{
new armacaso = random(1);
new asd = (armacaso == 1) ? (31):(30);
GivePlayerWeapon(playerid,asd,10000);
return 1;
}
Scs l'OT ma visto che non so usare ? e : ho appena letto il wiki, se non erro questa funziona diventa così
if(armacaso == 1)
{
asd = 31;
}
else
{
asd = 30;
}
giusto ?