error 006: must be assigned to an array - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: error 006: must be assigned to an array (
/showthread.php?tid=534391)
error 006: must be assigned to an array -
HerBan - 29.08.2014
pawn Код:
new str5[256];
(1369): TempTotalTime = dini_Get(rFile,"BestRacerTime_0",1);
ConvertTime(var1, TempTotalTime, TempTime[0], TempTime[1], TempTime[2]);
format(str, sizeof str5, "with %d:%d.%d seconds", rTime[0], rTime[1], rTime[2]);
SendClientMessageToAll(-1, str5);
error:
Код:
1369: error 006: must be assigned to an array
AW: error 006: must be assigned to an array -
CutX - 29.08.2014
pawnlang makes it clear and says
Quote:
Originally Posted by CompuPhase
Regarding error 006 - must be assigned to an array
String literals or arrays must be assigned to an array.
This error message may also indicate a missing index (or indices) at the
array on the right side of the “=” sign.
|
doesen't dini_get return the data as string?
i think it does
that's your mistake.
either make TempoTotalTime a string or use dini_int & use unix timestamp
example assignments:
pawn Код:
integer = array;//won't work
integer = integer;//works