quest-wizard/models/events/qw_changelocationevent.h

33 lines
755 B
C
Raw Permalink Normal View History

2023-02-09 08:41:24 -05:00
#ifndef QUESTCHANGELOCATIONEVENT_H
#define QUESTCHANGELOCATIONEVENT_H
#include "qw_abstractsceneevent.h"
/* QWChangeLocationEvent
* Moves player to new location by replacing scene triggers. */
class QWTrigger;
class QWLocation;
class QWChangeLocationEvent : public QWAbstractSceneEvent
{
private:
std::shared_ptr<QWLocation> target_location;
public:
explicit QWChangeLocationEvent(const std::shared_ptr<QWLocation> &location);
virtual ~QWChangeLocationEvent() override {}
void execute() override;
////////////////////////
void setLocation(const std::shared_ptr<QWLocation> &location) noexcept;
////////////////////////
void writeToJson(QJsonObject &event_data) override;
};
#endif // QUESTCHANGELOCATIONEVENT_H