… | |
… | |
299 | // maximum supported subtype number + 1, can be increased to 256 |
299 | // maximum supported subtype number + 1, can be increased to 256 |
300 | // currently (2007-09) in use: 50 |
300 | // currently (2007-09) in use: 50 |
301 | #define NUM_SUBTYPES 64 |
301 | #define NUM_SUBTYPES 64 |
302 | |
302 | |
303 | /* Subtypes for BUILDER */ |
303 | /* Subtypes for BUILDER */ |
304 | #define ST_BD_BUILD 1 /* Builds an item */ |
304 | #define ST_BD_BUILD 1 /* Builds an item */ |
305 | #define ST_BD_REMOVE 2 /* Removes an item */ |
305 | #define ST_BD_REMOVE 2 /* Removes an item */ |
306 | |
306 | |
307 | /* Subtypes for MATERIAL */ |
307 | /* Subtypes for MATERIAL */ |
308 | #define ST_MAT_FLOOR 1 /* Floor */ |
308 | #define ST_MAT_FLOOR 1 /* Floor */ |
309 | #define ST_MAT_WALL 2 /* Wall */ |
309 | #define ST_MAT_WALL 2 /* Wall */ |
310 | #define ST_MAT_ITEM 3 /* All other items, including doors & such */ |
310 | #define ST_MAT_ITEM 3 /* All other items, including doors & such */ |
… | |
… | |
759 | // also make sure that this is a float, not double, constant |
759 | // also make sure that this is a float, not double, constant |
760 | #define MIN_ACTIVE_SPEED (1.f / 65536.f) |
760 | #define MIN_ACTIVE_SPEED (1.f / 65536.f) |
761 | |
761 | |
762 | #define RANDOM() (rndm.next () & 0xffffffU) |
762 | #define RANDOM() (rndm.next () & 0xffffffU) |
763 | |
763 | |
764 | /* Returns the weight of the given object. Note: it does not take the number of |
|
|
765 | * items (nrof) into account. |
|
|
766 | * (this looks rather bogus, schmorp) |
|
|
767 | */ |
|
|
768 | #define WEIGHT(op) ((op)->nrof ? (op)->weight : (op)->weight + (op)->carrying) |
|
|
769 | |
|
|
770 | /* |
764 | /* |
771 | * Warning! |
765 | * Warning! |
772 | * If you add message types here, don't forget |
766 | * If you add message types here, don't forget |
773 | * to keep the client up to date too! |
767 | * to keep the client up to date too! |
774 | */ |
768 | */ |