KlassischeKeplerKriege/game/state/events/explosion_event.hpp

21 lines
644 B
C++

#pragma once
#include "state/explosion.hpp"
#include "state/state_update_event.hpp"
namespace game {
class ExplosionEvent : public StateUpdateEvent {
public:
ExplosionEvent(StateUpdateEvent::LifeCycle lifeCycle, Explosion *explosion)
: StateUpdateEvent(lifeCycle, StateUpdateEvent::EventType::Explosion)
, explosion(explosion)
{
std::string typeStr = StateUpdateEvent::lifeCycleToString(lifeCycle);
std::cout<<"created explosion event for id " << explosion->id << " of type " << typeStr << std::endl;
}
public:
const Explosion *explosion;
};
}