Movement types and related macros.
Detailed Description
Those flags are all possible movement types.
If you add new movement types, you may need to update describe_item() so properly describe those types. change_abil() probably should be updated also.
Define Documentation
Mask of all movement types.
Definition at line 656 of file define.h.
#define MOVE_BLOCK_DEFAULT MOVE_SWIM |
The normal assumption is that objects are walking/flying. So often we don't want to block movement, but still don't want to allow all types (swimming is rather specialized) - I also expect as more movement types show up, this is likely to get updated. Basically, this is the default for spaces that allow movement - anything but swimming right now. If you really want nothing at all, then can always set move_block to 0
Definition at line 667 of file define.h.
Boats/sailing.
Definition at line 655 of file define.h.
#define MOVE_FLY_HIGH 0x4 |
High flying object.
Definition at line 652 of file define.h.
Low flying object.
Definition at line 651 of file define.h.
Combo of fly_low and fly_high.
Definition at line 653 of file define.h.
Swimming object.
Definition at line 654 of file define.h.
#define OB_MOVE_BLOCK |
( |
ob1, |
|
|
ob2 |
|
) |
((ob1->move_type&ob2->move_block) == ob1->move_type) |
Basic macro to see if ob2 blocks ob1 from moving onto this space. Basically, ob2 has to block all of ob1 movement types.
Definition at line 681 of file define.h.
#define OB_TYPE_MOVE_BLOCK |
( |
ob1, |
|
|
type |
|
) |
((type != 0) && (ob1->move_type&type) == ob1->move_type) |
Basic macro to see if if ob1 can not move onto a space based on the 'type' move_block parameter Add check - if type is 0, don't stop anything from moving onto it.
Definition at line 690 of file define.h.
Typedef Documentation
Typdef here to define type large enough to hold bitmask of all movement types. Make one declaration so easy to update. uint8 is defined yet, so just use what that would define it at anyways.
Definition at line 675 of file define.h.