Original Post
Im working on a level editor, and the maps are stroed as text files, and I use RLE (runetime-length encoding) to compress them. This works fine, but im having a lot of trouble trying to think up how to make the loading algorithm work. The problem in my mind is that once i find the repetions of the tiles and run through another for loop to set the tiles ID, X, Y, and Z positions, im not sure how this would affect my regular loop, and how I would calculate the Y and Z positions, given the Hight Width and Depth of the map. If anyone has example code or the algo in pseudo-code I would be grateful!