SA-MP Forums Archive
Errors, help, please. - 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: Errors, help, please. (/showthread.php?tid=368272)



Errors, help, please. - SpaMaster - 12.08.2012

Making a two language script with this tutorial: https://sampforum.blast.hk/showthread.php?tid=317264, but i have one errors on this line:
Код:
Код:
INI_Int("Jezik", player_Language[MAX_PLAYERS] = 1);
Error is:
Код:
IC_war.pwn(879) : error 032: array index out of bounds (variable "player_Language")



Re: Errors, help, please. - FalconX - 12.08.2012

Quote:
Originally Posted by SpaMaster
Посмотреть сообщение
Making a two language script with this tutorial: https://sampforum.blast.hk/showthread.php?tid=317264, but i have one errors on this line:
Код:
Код:
INI_Int("Jezik", player_Language[MAX_PLAYERS] = 1);
Error is:
Код:
IC_war.pwn(879) : error 032: array index out of bounds (variable "player_Language")
Hmm, try this:

pawn Код:
player_Language[playerid] = 1;
INI_Int("Jezik", player_Language[playerid] );
Make sure you have

pawn Код:
new player_Language[ MAX_PLAYERS ]; //at top
Hope this helps


Re: Errors, help, please. - SpaMaster - 12.08.2012

Quote:
Originally Posted by FalconX
Посмотреть сообщение
Hmm, try this:

pawn Код:
player_Language[playerid] = 1;
INI_Int("Jezik", player_Language[playerid] );
Make sure you have

pawn Код:
new player_Language[ MAX_PLAYERS ]; //at top
Hope this helps
Helps, thanks