… | |
… | |
131 | sint8 ACC (RW, light); /* How much light this space provides */ |
131 | sint8 ACC (RW, light); /* How much light this space provides */ |
132 | MoveType ACC (RW, move_block); /* What movement types this space blocks */ |
132 | MoveType ACC (RW, move_block); /* What movement types this space blocks */ |
133 | MoveType ACC (RW, move_slow); /* What movement types this space slows */ |
133 | MoveType ACC (RW, move_slow); /* What movement types this space slows */ |
134 | MoveType ACC (RW, move_on); /* What movement types are activated */ |
134 | MoveType ACC (RW, move_on); /* What movement types are activated */ |
135 | MoveType ACC (RW, move_off); /* What movement types are activated */ |
135 | MoveType ACC (RW, move_off); /* What movement types are activated */ |
136 | uint16_t ACC (RW, nrof_); // saturates at 64k |
136 | uint16_t ACC (RW, items_); // saturates at 64k |
137 | uint32_t ACC (RW, volume_); // ~dm³ (not cm³) (factor is actually 1024) |
137 | uint32_t ACC (RW, volume_); // ~dm³ (not cm³) (factor is actually 1024) |
138 | uint32_t ACC (RW, smell); // the last count a player was seen here, or 0 |
138 | uint32_t ACC (RW, smell); // the last count a player was seen here, or 0 |
139 | static uint32_t ACC (RW, smellcount); // global smell counter |
139 | static uint32_t ACC (RW, smellcount); // global smell counter |
140 | |
140 | |
141 | uint32_t pad1_, pad2_; // pad to 64 bytes on 64 bit systems |
141 | uint32_t pad1_, pad2_; // pad to 64 bytes on 64 bit systems |
… | |
… | |
151 | assert (sint8 (-1 & ~P_UPTODATE) >= 0); |
151 | assert (sint8 (-1 & ~P_UPTODATE) >= 0); |
152 | |
152 | |
153 | if (expect_false (sint8 (flags_) >= 0)) |
153 | if (expect_false (sint8 (flags_) >= 0)) |
154 | update_ (); |
154 | update_ (); |
155 | |
155 | |
156 | // must be true by now |
156 | // must be true by now (gcc seems content with only the second test) |
157 | assume (sint8 (flags_) < 0); |
157 | assume (sint8 (flags_) < 0); |
158 | assume (flags_ & P_UPTODATE); |
158 | assume (flags_ & P_UPTODATE); |
159 | } |
159 | } |
160 | |
160 | |
161 | MTH uint8 flags () |
161 | MTH uint8 flags () |
… | |
… | |
180 | op = 0; |
180 | op = 0; |
181 | |
181 | |
182 | return op; |
182 | return op; |
183 | } |
183 | } |
184 | |
184 | |
185 | MTH uint32 nrof () |
185 | MTH uint32 items() |
186 | { |
186 | { |
187 | update (); |
187 | update (); |
188 | return nrof_; |
188 | return items_; |
189 | } |
189 | } |
190 | |
190 | |
191 | // return the item volume on this mapspace in cm³ |
191 | // return the item volume on this mapspace in cm³ |
192 | MTH uint64 volume () |
192 | MTH uint64 volume () |
193 | { |
193 | { |
… | |
… | |
298 | shstr ACC (RW, msg); /* Message map creator may have left */ |
298 | shstr ACC (RW, msg); /* Message map creator may have left */ |
299 | shstr ACC (RW, maplore); /* Map lore information */ |
299 | shstr ACC (RW, maplore); /* Map lore information */ |
300 | shstr ACC (RW, tile_path[4]); /* path to adjoining maps */ |
300 | shstr ACC (RW, tile_path[4]); /* path to adjoining maps */ |
301 | maptile *ACC (RW, tile_map[4]); /* Next map, linked list */ |
301 | maptile *ACC (RW, tile_map[4]); /* Next map, linked list */ |
302 | shstr ACC (RW, path); /* Filename of the map */ |
302 | shstr ACC (RW, path); /* Filename of the map */ |
303 | int ACC (RW, max_nrof); // maximum nrof of any single item on a mapspace |
|
|
304 | uint64 ACC (RW, max_volume); // maximum volume for all items on a mapspace |
303 | uint64 ACC (RW, max_volume); // maximum volume for all items on a mapspace |
305 | int ACC (RW, max_items); // maximum number of items on a mapspace |
304 | int ACC (RW, max_items); // maximum number of items on a mapspace |
306 | |
305 | |
307 | //-GPL |
306 | //-GPL |
308 | |
307 | |