Tile editor

BlitzMax Forums/BlitzMax Beginners Area/Tile editor

You need either this

Field Tiles:Tile[,] = New Tiles[MaxMapX,MaxMapY]
In side Type Tilemap

or

Field Tiles:Tiles[,]
'Then in the create:TileMap 
TM.Tiles = new Tile[MaxMapx,MaxMapy]
As you can see You need to do two things. First tell the type that it will have an array "Field ArrayName:ArrayType[,]" then you need to make the space "New ArrayType[num,num]"
If you know how big the map in tile map is going to be, put everything into the field. To be able to have different map sizes then put it into the Create

NOTE
---------------------------------------------
Field ANY:Int[,] = New Int[20,22], will produce an error in some versions of the community IDE. If you have this problem, delete any spaces inside the [] that the ide adds, then use the up or down keys to leave the line