PDA

View Full Version : Array Error


SytonicX
07/10/2017, 12:50 PM
../gamemodes/Build.pwn(6221) : error 006: must be assigned to an array
../gamemodes/Build.pwn(6223) : warning 217: loose indentation
That is the error I am getting and those are the lines:
6218: new mtlist[9065];
6219: for(new i = 0; i < sizeof(MaterialIDs); i++)
6220: {
6221: mtlist[i] = MaterialIDs[i];
6222: }
6223: ShowModelSelectionMenuEx(playerid, mtlist, sizeof(MaterialIDs), "Material List", 500, 16.0, 0.0, -55.0);

Dayrion
07/10/2017, 12:59 PM
Can you show declarations of mtlist & MaterialIDs? You are probably missing a dimenson in your code.
warning 217: loose indentation
The indentation of this line is different of the next and previous line.

SytonicX
07/10/2017, 01:39 PM
Fixed the code, Thanks for your help! :D