04.08.2011, 10:48
(
Последний раз редактировалось [JnA]DukeNukem; 04.08.2011 в 14:06.
)
here's the script:
and here are the errors
:
EDIT : works fine, but doesn't SAVE AMMO
Код:
new bullets[MAX_PLAYERS][12]; new weapons[MAX_PLAYERS][12]; GetPlayerWeaponData(playerid,1,weapons[playerid][0],bullets[playerid][0]); GetPlayerWeaponData(playerid,2,weapons[playerid][1],bullets[playerid][1]); GetPlayerWeaponData(playerid,3,weapons[playerid][2],bullets[playerid][2]); GetPlayerWeaponData(playerid,4,weapons[playerid][3],bullets[playerid][3]); GetPlayerWeaponData(playerid,5,weapons[playerid][4],bullets[playerid][4]); GetPlayerWeaponData(playerid,6,weapons[playerid][5],bullets[playerid][5]); GetPlayerWeaponData(playerid,7,weapons[playerid][6],bullets[playerid][6]); GetPlayerWeaponData(playerid,8,weapons[playerid][7],bullets[playerid][7]); GetPlayerWeaponData(playerid,9,weapons[playerid][8],bullets[playerid][8]); GetPlayerWeaponData(playerid,10,weapons[playerid][9],bullets[playerid][9]); GetPlayerWeaponData(playerid,11,weapons[playerid][10],bullets[playerid][10]); GetPlayerWeaponData(playerid,12,weapons[playerid][11],bullets[playerid][11]); dini_IntSet(playerFile,"weapon0",weapons[playerid][0]); dini_IntSet(playerFile,"weapon1",weapons[playerid][1]); dini_IntSet(playerFile,"weapon2",weapons[playerid][2]); dini_IntSet(playerFile,"weapon3",weapons[playerid][3]); dini_IntSet(playerFile,"weapon4",weapons[playerid][4]); dini_IntSet(playerFile,"weapon5",weapons[playerid][5]); dini_IntSet(playerFile,"weapon6",weapons[playerid][6]); dini_IntSet(playerFile,"weapon7",weapons[playerid][7]); dini_IntSet(playerFile,"weapon8",weapons[playerid][8]); dini_IntSet(playerFile,"weapon9",weapons[playerid][9]); dini_IntSet(playerFile,"weapon10",weapons[playerid][10]); dini_IntSet(playerFile,"weapon11",weapons[playerid][11]); dini_IntSet(playerFile,"weapon12",weapons[playerid][12]); dini_IntSet(playerFile,"bullets0",bullets[playerid][0]); dini_IntSet(playerFile,"bullets1",bullets[playerid][1]); dini_IntSet(playerFile,"bullets2",bullets[playerid][2]); dini_IntSet(playerFile,"bullets3",bullets[playerid][3]); dini_IntSet(playerFile,"bullets4",bullets[playerid][4]); dini_IntSet(playerFile,"bullets5",bullets[playerid][5]); dini_IntSet(playerFile,"bullets6",bullets[playerid][6]); dini_IntSet(playerFile,"bullets7",bullets[playerid][7]); dini_IntSet(playerFile,"bullets8",bullets[playerid][8]); dini_IntSet(playerFile,"bullets9",bullets[playerid][9]); dini_IntSet(playerFile,"bullets10",bullets[playerid][10]); dini_IntSet(playerFile,"bullets11",bullets[playerid][11]); dini_IntSet(playerFile,"bullets12",bullets[playerid][12]);
:
Код:
C:\DOCUME~1\Admin\Desktop\srvr\GAMEMO~1\test.pwn(223) : error 032: array index out of bounds (variable "weapons") C:\DOCUME~1\Admin\Desktop\srvr\GAMEMO~1\test.pwn(237) : error 032: array index out of bounds (variable "bullets")