Prodan Posted May 21, 2017 Posted May 21, 2017 (edited) sal am facut si eu niste cp de pizza si vr sa fie random. Iau erori aiurea si nu inteleg de ce. Erori: ../inc/jobs.inc(79) : warning 219: local variable "random" shadows a variable at a preceding level ../inc/jobs.inc(79) : error 012: invalid function call, not a valid address ../inc/jobs.inc(79) : error 001: expected token: ";", but found "sizeof" ../inc/jobs.inc(79) : warning 215: expression has no effect ../inc/jobs.inc(79) : error 001: expected token: ";", but found ")" ../inc/jobs.inc(79) : fatal error 107: too many error messages on one line Comanda: CMD:pizza(playerid, params[]) { PizzaCP[playerid] = 1; new random = random(sizeof(RandomPizza)); // linia 79 SetPlayerCheckpoint(playerid, RandomPizza[random][1], RandomPizza[random][2], RandomPizza[random][3], 5.0); return 1; } RandomPizza: new Float:RandomPizza[3][3] = { {178.8973,-86.9468,1.5808}, {178.8973,-86.9468,1.5808}, {252.7400,-92.5441,3.5354} }; Edited May 21, 2017 by MiHAi.VALUPALATiN Quote
W A R E N K Posted May 21, 2017 Posted May 21, 2017 Schimba variabila 'random' cu alta variabila, de ex: new rand = random(sizeof(RandomPizza)); 4 Quote
Zooky. Posted May 21, 2017 Posted May 21, 2017 Schimba variabila 'random' cu alta variabila, de ex: new rand = random(sizeof(RandomPizza)); Quote
CrImA Posted May 22, 2017 Posted May 22, 2017 Cel mai bine te folosesti de o variabila cu o valoare random si coordonatele din exteriorul caselor. ( daca vrei sa faci sa livreze pizza la o casa random de pe server ) Quote
Prodan Posted May 22, 2017 Author Posted May 22, 2017 Schimba variabila 'random' cu alta variabila, de ex: new rand = random(sizeof(RandomPizza)); Schimba variabila 'random' cu alta variabila, de ex: new rand = random(sizeof(RandomPizza)); Mersii :**. Cel mai bine te folosesti de o variabila cu o valoare random si coordonatele din exteriorul caselor. ( daca vrei sa faci sa livreze pizza la o casa random de pe server ) Am sa fac asta dupa ce fac sistemul de case, deocamdata am inceput un GM de la 0 pe include-uri. Quote
RewardK Posted December 1, 2017 Posted December 1, 2017 NU STIU CE ARE, DE UNDE VRETI SA STIU, SUNT PROST Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.