Data Size Glitch
The Data Size Glitch is an error in Microsoft's version of Chip's Challenge which occurs when the size of a level's data in memory exceeds an internal limit of the program. This glitch causes MSCC to terminate abnormally when the level is accessed in certain ways (listed below), although in other cases the level can be played as usual. Tile World does not suffer from this glitch.
The glitch is triggered when the level is entered in the following ways:
- Using Ctrl+P / Ctrl+N to navigate to that level from the next / previous level
- When starting the program with the Current Level as that level. This includes the case when the program is started for the purpose of playtesting a level from a level editor.
The glitch can be avoid by accessing the level in other ways:
- Completing the previous level
- Jumping to the level using Go To...
The error occurs when the size of a level's "non-map" data exceeds 544 bytes. Non-map data includes everything other than the data that specifies the tiles constituting the two layers of the map. It can be calculated as follows:
- title size = length of title + 3
- password size = 7
- hint size = length of hint + 3, 0 if no hint
- trap connections list size = number of connections * 10 + 2, 0 if none
- clone machine connections list size = number of connections * 8 + 2, 0 if none
- monster list size = number of monsters * 2 + 2, 0 if none
(The above information was originally posted by ccexplore at the Chip's Challenge newsgroup, but that post has since been archived.)
Unlike the Termination Glitch, there is no utility or patch available to fix the glitch. Hence, the only way to ensure that it does not occur is to modify an offending level so that its data size is brought within limits. Changes that can be done without severely altering the level are:
- Rewrite the hint in a fewer number of characters. Note that in any case, MSCC will not display hints that don't fit into the Hint pane.
- Remove monsters that cannot move from the monster list by marking them as "stationary". This includes monsters on clone machines and unconnected traps.
- Use a shorter level name.