Create placeholder for ID_GAME_SPELLBOOK

coverity_scan^2
David Cernat 8 years ago
parent 6c8c0827ea
commit 6ea5f08e9c

@ -231,6 +231,14 @@ void Networking::processPlayerPacket(RakNet::Packet *packet)
break;
}
case ID_GAME_SPELLBOOK:
{
DEBUG_PRINTF("ID_GAME_SPELLBOOK\n");
myPacket->Read(player);
break;
}
case ID_GAME_ATTACK:
{
DEBUG_PRINTF("ID_GAME_ATTACK\n");

@ -341,6 +341,10 @@ void Networking::processPlayerPacket(RakNet::Packet *packet)
}
break;
}
case ID_GAME_SPELLBOOK:
{
break;
}
case ID_GAME_ATTACK:
{
if (pl != 0)

@ -155,7 +155,7 @@ add_component_dir (openmw-mp
Packets/Player/PacketDrawState Packets/Player/PacketChatMessage Packets/Player/PacketCharGen
Packets/Player/PacketAttribute Packets/Player/PacketSkill Packets/Player/PacketLevel
Packets/Player/PacketHandshake Packets/Player/PacketGUIBoxes Packets/Player/PacketClass
Packets/Player/PacketTime Packets/Player/PacketInventory
Packets/Player/PacketTime Packets/Player/PacketInventory Packets/Player/PacketSpellbook
Packets/World/PacketObjectDelete Packets/World/PacketObjectPlace Packets/World/PacketObjectLock
Packets/World/PacketObjectUnlock Packets/World/PacketObjectScale Packets/World/PacketObjectMove

@ -24,6 +24,7 @@
#include "../Packets/Player/PacketTime.hpp"
#include "../Packets/Player/PacketLoaded.hpp"
#include "../Packets/Player/PacketInventory.hpp"
#include "../Packets/Player/PacketSpellbook.hpp"
#include "../Packets/Player/PacketConsole.hpp"
#include "PlayerPacketController.hpp"
@ -64,6 +65,7 @@ mwmp::PlayerPacketController::PlayerPacketController(RakNet::RakPeerInterface *p
AddPacket<PacketTime>(&packets, peer);
AddPacket<PacketLoaded>(&packets, peer);
AddPacket<PacketInventory>(&packets, peer);
AddPacket<PacketSpellbook>(&packets, peer);
AddPacket<PacketConsole>(&packets, peer);
}

@ -32,6 +32,7 @@ enum GameMessages
ID_GUI_MESSAGEBOX,
ID_GAME_TIME,
ID_GAME_INVENTORY,
ID_GAME_SPELLBOOK,
ID_OBJECT_PLACE,
ID_OBJECT_DELETE,

@ -0,0 +1,15 @@
#include <components/openmw-mp/NetworkMessages.hpp>
#include "PacketSpellbook.hpp"
using namespace std;
using namespace mwmp;
PacketSpellbook::PacketSpellbook(RakNet::RakPeerInterface *peer) : PlayerPacket(peer)
{
packetID = ID_GAME_SPELLBOOK;
}
void PacketSpellbook::Packet(RakNet::BitStream *bs, BasePlayer *player, bool send)
{
PlayerPacket::Packet(bs, player, send);
}

@ -0,0 +1,18 @@
#ifndef OPENMW_PACKETSPELLBOOK_HPP
#define OPENMW_PACKETSPELLBOOK_HPP
#include <components/openmw-mp/Packets/Player/PlayerPacket.hpp>
namespace mwmp
{
class PacketSpellbook : public PlayerPacket
{
public:
PacketSpellbook(RakNet::RakPeerInterface *peer);
virtual void Packet(RakNet::BitStream *bs, BasePlayer *player, bool send);
};
}
#endif //OPENMW_PACKETSPELLBOOK_HPP
Loading…
Cancel
Save