From: Daniel Karbach Date: Wed, 3 Oct 2012 13:05:51 +0000 (+0200) Subject: added map trigger prototype X-Git-Url: https://git.localhorst.tv/?a=commitdiff_plain;h=65f855e8181613291670bf1ef84623fabc4594d9;p=l2e.git added map trigger prototype --- diff --git a/Debug/src/map/subdir.mk b/Debug/src/map/subdir.mk index fa93078..01eb787 100644 --- a/Debug/src/map/subdir.mk +++ b/Debug/src/map/subdir.mk @@ -8,21 +8,24 @@ CPP_SRCS += \ ../src/map/Entity.cpp \ ../src/map/Map.cpp \ ../src/map/MapState.cpp \ -../src/map/Tile.cpp +../src/map/Tile.cpp \ +../src/map/Trigger.cpp OBJS += \ ./src/map/Area.o \ ./src/map/Entity.o \ ./src/map/Map.o \ ./src/map/MapState.o \ -./src/map/Tile.o +./src/map/Tile.o \ +./src/map/Trigger.o CPP_DEPS += \ ./src/map/Area.d \ ./src/map/Entity.d \ ./src/map/Map.d \ ./src/map/MapState.d \ -./src/map/Tile.d +./src/map/Tile.d \ +./src/map/Trigger.d # Each subdirectory must supply rules for building sources it contributes diff --git a/Release/src/map/subdir.mk b/Release/src/map/subdir.mk index 25e2b82..cf8c41a 100644 --- a/Release/src/map/subdir.mk +++ b/Release/src/map/subdir.mk @@ -8,21 +8,24 @@ CPP_SRCS += \ ../src/map/Entity.cpp \ ../src/map/Map.cpp \ ../src/map/MapState.cpp \ -../src/map/Tile.cpp +../src/map/Tile.cpp \ +../src/map/Trigger.cpp OBJS += \ ./src/map/Area.o \ ./src/map/Entity.o \ ./src/map/Map.o \ ./src/map/MapState.o \ -./src/map/Tile.o +./src/map/Tile.o \ +./src/map/Trigger.o CPP_DEPS += \ ./src/map/Area.d \ ./src/map/Entity.d \ ./src/map/Map.d \ ./src/map/MapState.d \ -./src/map/Tile.d +./src/map/Tile.d \ +./src/map/Trigger.d # Each subdirectory must supply rules for building sources it contributes diff --git a/src/map/Trigger.cpp b/src/map/Trigger.cpp new file mode 100644 index 0000000..4f370d9 --- /dev/null +++ b/src/map/Trigger.cpp @@ -0,0 +1,16 @@ +/* + * Trigger.cpp + * + * Created on: Oct 3, 2012 + * Author: holy + */ + +#include "Trigger.h" + +namespace map { + +Trigger::Trigger() { + +} + +} diff --git a/src/map/Trigger.h b/src/map/Trigger.h new file mode 100644 index 0000000..f1e9cb0 --- /dev/null +++ b/src/map/Trigger.h @@ -0,0 +1,35 @@ +/* + * Trigger.h + * + * Created on: Oct 3, 2012 + * Author: holy + */ + +#ifndef MAP_TRIGGER_H_ +#define MAP_TRIGGER_H_ + +#include "../geometry/Vector.h" + +namespace map { + +class Trigger { + +public: + Trigger(); + ~Trigger() { } + +public: + const geometry::Vector &TilePosition() const { return tilePosition; } + +// temporary setters +public: + void SetTilePosition(const geometry::Vector &p) { tilePosition = p; } + +private: + geometry::Vector tilePosition; + +}; + +} + +#endif /* MAP_TRIGGER_H_ */ diff --git a/src/map/fwd.h b/src/map/fwd.h index a9d1e2e..8f2603c 100644 --- a/src/map/fwd.h +++ b/src/map/fwd.h @@ -15,6 +15,7 @@ class Entity; class Map; class MapState; class Tile; +class Trigger; }