1 #ifndef SPRITE_MOVE_EVENT_H
2 #define SPRITE_MOVE_EVENT_H
16 glm::vec2 next_position;
35 static std::shared_ptr<SpriteMoveEvent>
create(glm::vec2& velocity,
const glm::vec2& next_position) {
return std::make_shared<SpriteMoveEvent>(velocity, next_position); }
glm::vec2 getNextPosition() const noexcept
Gets the next position.
Definition: sprite_move_event.h:47
Class for event.
Definition: event.h:10
static std::shared_ptr< SpriteMoveEvent > create(glm::vec2 &velocity, const glm::vec2 &next_position)
SpriteMoveEvent factory function.
Definition: sprite_move_event.h:35
Class for sprite move event.
Definition: sprite_move_event.h:13
SpriteMoveEvent(const glm::vec2 &velocity, const glm::vec2 &next_position)
SpriteMoveEvent constructor.
Definition: sprite_move_event.h:26
EventType
Event type enum that is used when passing events.
Definition: event_type.h:12
glm::vec2 getVelocity() const noexcept
Gets the velocity.
Definition: sprite_move_event.h:41
Event(const EventType &type)
Event constructor.
Definition: event.h:21
Definition: event_type.h:23