SA-MP Forums Archive
array must be indexed - 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: array must be indexed (/showthread.php?tid=652572)



array must be indexed - Zeus666 - 14.04.2018

PHP код:
 error 033: array must be indexed (variable "RentedBy")
Pawn compiler 3.2.3664              Copyright (c1997-2006ITB CompuPhase
1 Error

Error
PHP код:
new RentedBy[MAX_VEHICLES][24];  // top of script
RentedBy[vID] = GetPlayerName(playeridnamesizeof(name)); 



Re: array must be indexed - UFF - 14.04.2018

new RentedBy[MAX_VEHICLES];


Re: array must be indexed - Lokii - 14.04.2018

PHP код:
GetPlayerName(playeridnamesizeof(name));
RentedBy[vID] = name



Re: array must be indexed - Mugala - 14.04.2018

guys, just stop typing random codes please, you're making it worse.

OT: use this.
PHP код:
GetPlayerName(playeridRentedBy[vID], 24);