Iron Realms Entertainment
Maps are large, two dimensional grids of data. Much like a bitmap or an image, it stores data at a two dimensional point (or at least that’s the interface provided). Rapture is responsible for manipulating and accessing these much like it does for databases. Maps can be anonymous or persistent (just like <databases>), however there is one distinction: anonymous maps are not cleared when an executable is reloaded, they stay resident (unlike anonymous databases which are cleared upon a reload). Perhaps you’re wondering just what use maps provide. Well, let’s see a couple examples:
Here to use maps
Access one element of the map using two dimentional coordinates. It is treated as a two dimensional array with the x value varying between 0 and width-1, and the y value varying between 0 and height-1. This may be used to read the value (in an expression) or to set it (in an assignment statement).
Access one element of the map using a single offset value. It is treated as a linear array of elements. That is, the offset can be anywhere between 0 and (width×height)-1. The addressing is row-major meaning that elements 0 through width-1 refer to the first row, width through (2×width)-1 is the second row, etc. This may be used to read the value (in an expression) or to set it (in an assignment statement).