26 virtual QJsonObject
toJson()
const override;
27 virtual void doWork()
override;
The ProjectileFiredCommand indicates that a projectile has been fired and contains the position as we...
Definition: projectilefiredcommand.h:20
QVector3D startPosition() const
Definition: projectilefiredcommand.cpp:51
QVector3D m_startPosition
Definition: projectilefiredcommand.h:36
QVector3D m_velocity
Definition: projectilefiredcommand.h:37
QVector3D velocity() const
Definition: projectilefiredcommand.cpp:56
Commands
The Commands enum stores all command types with corresponding ID.
Definition: commands.h:9
signed int TimerMSec
Definition: timer.h:22
ProjectileFiredCommand(Timer::TimerMSec timeStamp, QVector3D startPosition, QVector3D velocity)
Definition: projectilefiredcommand.cpp:11
virtual void doWork() override
Every Commands must define its effects on the receiving game.
Definition: projectilefiredcommand.cpp:34
Definition: eventhandler.cpp:18
Timer::TimerMSec timeStamp() const
get the time as counted by the sending game that this command was created and sent ...
Definition: abstractcommand.cpp:54
virtual QJsonObject toJson() const override
Every command must define how its members can be serialized.
Definition: projectilefiredcommand.cpp:26
virtual Commands commandType() const override
Every Command must specify its type.
Definition: projectilefiredcommand.cpp:46
The AbstractCommand class defines the interface that every command has to implement.
Definition: abstractcommand.h:23