roguish/devices.cpp

19 lines
519 B
C++

#include "devices.hpp"
#include "events.hpp"
namespace components {
void StairsDown(DinkyECS::Entity player_ent, json &, DinkyECS::World &world) {
world.send<Events::GUI>(Events::GUI::STAIRS, player_ent, {});
}
void StairsUp(DinkyECS::Entity player_ent, json &, DinkyECS::World &world) {
world.send<Events::GUI>(Events::GUI::STAIRS, player_ent, {});
}
void Device::hit(DinkyECS::Entity ent, DinkyECS::World &world) {
for(auto& action : actions) {
action(ent, config, world);
}
}
}