21 #ifndef ULTIMA4_GAME_OBJECT_H 22 #define ULTIMA4_GAME_OBJECT_H 24 #include "ultima/ultima4/core/coords.h" 25 #include "ultima/ultima4/map/map_tile.h" 26 #include "ultima/ultima4/core/types.h" 35 enum ObjectMovementBehavior {
38 MOVEMENT_FOLLOW_AVATAR,
39 MOVEMENT_ATTACK_AVATAR
50 Object(Type type = UNKNOWN) :
53 _movementBehavior(MOVEMENT_FIXED),
69 const Coords &getCoords()
const {
72 const Coords &getPrevCoords()
const {
75 ObjectMovementBehavior getMovementBehavior()
const {
76 return _movementBehavior;
78 Type getType()
const {
81 bool hasFocus()
const {
84 bool isVisible()
const {
87 bool isAnimated()
const {
94 void setTile(
Tile *t) {
100 void setCoords(
Coords c) {
101 _prevCoords = _coords;
104 void setPrevCoords(
Coords c) {
107 void setMovementBehavior(ObjectMovementBehavior b) {
108 _movementBehavior = b;
110 void setType(Type t) {
113 void setFocus(
bool f =
true) {
116 void setVisible(
bool v =
true) {
119 void setAnimated(
bool a =
true) {
123 void setMap(
class Map *m);
127 bool setDirection(Direction d);
129 void animateMovement();
134 Coords _coords, _prevCoords;
135 ObjectMovementBehavior _movementBehavior;
Definition: containers.h:186
Std::deque< class Map * > _maps
Definition: object.h:137
Definition: detection.h:27
Definition: map_tile.h:34