#pragma once

#include "td/protocol/Protocol.h"
#include "td/game/BaseGame.h"

namespace td {
namespace protocol {

class UpdateGameStatePacket : public Packet {
private:
	game::GameState m_GameState;
public:
	UpdateGameStatePacket() {}
	UpdateGameStatePacket(game::GameState gameState) : m_GameState(gameState) {}
	virtual ~UpdateGameStatePacket() {}

	virtual DataBuffer Serialize(bool packetID = true) const;
	virtual void Deserialize(DataBuffer& data);
	virtual void Dispatch(PacketHandler* handler) const;

	game::GameState GetGameState() const { return m_GameState; }

	virtual PacketType GetType() const { return PacketType::UpdateGameState; }
};

} // namespace protocol
} // namespace td
