Mivčo 90 Odesláno: 14. Červen, 2013 Share Odesláno: 14. Červen, 2013 Sojte robim si taký script a mam jeden error a neviem ho opravit Error: error 047: array sizes do not match, or destination array is too small Riadok: PlayerName(playerid) = dini_Get(cesta, "Meno"); tu je celí cod: #include a_samp stock PlayerName(playerid) { new name[MAX_PLAYER_NAME]; GetPlayerName(playerid,name,MAX_PLAYER_NAME); return name; } public OnPlayerDisconnect(playerid, reason) { new cesta[50]; format(cesta, sizeof(cesta), "%s-pos.sav", PlayerName(playerid)); if(!dini_Exists(cesta)) // Ak neexistuje { dini_Create(cesta); // Vytvorý ho } new Float:X, Float:Y, Float:Z; GetPlayerPos(playerid, X, Y, Z); dini_Set(cesta, "Meno", PlayerName(playerid)); dini_FloatSet(cesta, "X", X); // Zapíše pozíciu (vytvorený bol v prechádzajúcom kroku takže žiadna podmienka nieje nutná) dini_FloatSet(cesta, "Y", Y); dini_FloatSet(cesta, "Z", Z); return 1; } public OnPlayerSpawn(playerid) { new Float:X,Float:Y,Float:Z; new cesta[50]; format(cesta, sizeof(cesta), "%s-pos.sav", PlayerName(playerid)); if(!dini_Exists(cesta)) { SetPlayerPos(playerid,1685.7253,-2334.6877,13.5469); } else { PlayerName(playerid) = dini_Get(cesta, "Meno"); X = dini_Float(cesta, "X"); Y = dini_Float(cesta, "Y"); Z = dini_Float(cesta, "Z"); SetPlayerPos(playerid, X, Y, Z); } return 1; } Prosim pomožte mi Dakujem Link to comment Share on other sites More sharing options...
0 Quiter 99 Odesláno: 14. Červen, 2013 Share Odesláno: 14. Červen, 2013 si už úplny deb*l ? už si to sem raz hádzal a niekto (už si nepamätám kto) ti napísal že nemôžeš zisťovacej funkcii nastaviť hodnotu pomocou = !!!!! buď to zmaž (ten riadok) alebo použi takto : SetPlayerName(playerid,dini_Get(cesta, "Meno")); // Ale nebude to mať žiadny účinok !! Link to comment Share on other sites More sharing options...
Dotaz
Mivčo 90
Sojte
robim si taký script a mam jeden error a neviem ho opravit
Error:
Riadok:
tu je celí cod:
Prosim pomožte mi Dakujem
Link to comment
Share on other sites
1 odpověd na tuto otázku
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now