diff --git a/apps/openmw-mp/Networking.cpp b/apps/openmw-mp/Networking.cpp index 805d7beff..7245e791f 100644 --- a/apps/openmw-mp/Networking.cpp +++ b/apps/openmw-mp/Networking.cpp @@ -414,7 +414,7 @@ void Networking::processWorldPacket(RakNet::Packet *packet) { LOG_MESSAGE_SIMPLE(Log::LOG_WARN, "Received ID_OBJECT_DELETE from %s", player->Npc()->mName.c_str()); - + myPacket->Read(event); LOG_APPEND(Log::LOG_WARN, "- cellRef: %s, %i\n- cell: %s", diff --git a/apps/openmw-mp/Player.cpp b/apps/openmw-mp/Player.cpp index eb024dd94..75dbe38e4 100644 --- a/apps/openmw-mp/Player.cpp +++ b/apps/openmw-mp/Player.cpp @@ -12,7 +12,7 @@ void Players::deletePlayer(RakNet::RakNetGUID guid) { LOG_MESSAGE_SIMPLE(Log::LOG_INFO, "Deleting player with guid %lu", guid.g); - + if (players[guid] != 0) { LOG_APPEND(Log::LOG_INFO, "- Emptying slot %i", diff --git a/apps/openmw-mp/Script/Functions/GUI.hpp b/apps/openmw-mp/Script/Functions/GUI.hpp index df241b1f7..e75affa21 100644 --- a/apps/openmw-mp/Script/Functions/GUI.hpp +++ b/apps/openmw-mp/Script/Functions/GUI.hpp @@ -19,7 +19,7 @@ class GUIFunctions public: /* Do not rename into MessageBox to not conflict with WINAPI's MessageBox */ static void _MessageBox(unsigned short pid, int id, const char *label) noexcept; - + static void CustomMessageBox(unsigned short pid, int id, const char *label, const char *buttons) noexcept; static void InputDialog(unsigned short pid, int id, const char *label) noexcept; diff --git a/apps/openmw-mp/main.cpp b/apps/openmw-mp/main.cpp index a1c6b8ebf..a5191669e 100644 --- a/apps/openmw-mp/main.cpp +++ b/apps/openmw-mp/main.cpp @@ -236,7 +236,6 @@ int main(int argc, char *argv[]) mclient->SetMOTD(motd); thrQuery = thread(queryThread, mclient); } - int code = networking.mainLoop(); diff --git a/apps/openmw/mwmp/LocalPlayer.cpp b/apps/openmw/mwmp/LocalPlayer.cpp index 49179edd5..39373961f 100644 --- a/apps/openmw/mwmp/LocalPlayer.cpp +++ b/apps/openmw/mwmp/LocalPlayer.cpp @@ -77,7 +77,7 @@ void LocalPlayer::charGen(int stageFirst, int stageEnd) bool LocalPlayer::charGenThread() { MWBase::WindowManager *windowManager = MWBase::Environment::get().getWindowManager(); - + // If we haven't finished CharGen and we're in a menu, it must be // one of the CharGen menus, so go no further until it's closed if (windowManager->isGuiMode() && CharGenStage()->end != 0) @@ -110,7 +110,7 @@ bool LocalPlayer::charGenThread() return false; } - + // If we've reached the last stage of CharGen, send the // corresponding packets and mark CharGen as finished else if (CharGenStage()->end != 0) @@ -219,7 +219,7 @@ void LocalPlayer::updateSkills(bool forceUpdate) else if (ptrNpcStats.getSkill(i).getProgress() != NpcStats()->mSkills[i].mProgress) { ptrNpcStats.getSkill(i).writeState(NpcStats()->mSkills[i]); - } + } } for (int i = 0; i < 8; i++) @@ -421,7 +421,7 @@ void LocalPlayer::updateEquipment(bool forceUpdate) void LocalPlayer::updateInventory(bool forceUpdate) { static bool invChanged = false; - + if (forceUpdate) invChanged = true; @@ -453,7 +453,7 @@ void LocalPlayer::updateInventory(bool forceUpdate) } } } - + if (!invChanged) { for (MWWorld::ContainerStoreIterator iter(ptrInventory.begin()); iter != ptrInventory.end(); ++iter) @@ -848,7 +848,7 @@ void LocalPlayer::sendInventory() void LocalPlayer::sendSpellAddition(std::string id) { spellbook.spells.clear(); - + mwmp::Spell spell; spell.id = id; spellbook.spells.push_back(spell); diff --git a/apps/openmw/mwmp/LocalPlayer.hpp b/apps/openmw/mwmp/LocalPlayer.hpp index 987b0f1b6..a4bab099e 100644 --- a/apps/openmw/mwmp/LocalPlayer.hpp +++ b/apps/openmw/mwmp/LocalPlayer.hpp @@ -53,8 +53,6 @@ namespace mwmp void prepareAttack(Attack::TYPE type, bool state); - - private: Networking *getNetworking(); MWWorld::Ptr getPlayerPtr(); diff --git a/apps/openmw/mwmp/Networking.cpp b/apps/openmw/mwmp/Networking.cpp index 4e74e80c2..f2f4f1bbb 100644 --- a/apps/openmw/mwmp/Networking.cpp +++ b/apps/openmw/mwmp/Networking.cpp @@ -79,7 +79,7 @@ void Networking::update() LOG_MESSAGE_SIMPLE(Log::LOG_INFO, "A connection is incoming."); break; case ID_NO_FREE_INCOMING_CONNECTIONS: - errmsg = "The server is full."; + errmsg = "The server is full."; break; case ID_DISCONNECTION_NOTIFICATION: errmsg = "We have been disconnected."; diff --git a/components/openmw-mp/Base/WorldEvent.hpp b/components/openmw-mp/Base/WorldEvent.hpp index 148608639..ca27bf374 100644 --- a/components/openmw-mp/Base/WorldEvent.hpp +++ b/components/openmw-mp/Base/WorldEvent.hpp @@ -26,7 +26,7 @@ namespace mwmp ESM::Cell cell; ESM::CellRef cellRef; ESM::Position pos; - + int count; int state; int lockLevel; diff --git a/components/openmw-mp/Packets/Player/PacketInventory.cpp b/components/openmw-mp/Packets/Player/PacketInventory.cpp index 97bcbb865..2f4f41c80 100644 --- a/components/openmw-mp/Packets/Player/PacketInventory.cpp +++ b/components/openmw-mp/Packets/Player/PacketInventory.cpp @@ -23,9 +23,9 @@ void PacketInventory::Packet(RakNet::BitStream *bs, BasePlayer *player, bool sen player->inventory.items.clear(); else player->inventory.count = (unsigned int) (player->inventory.items.size()); - + RW(player->inventory.count, send); - + for (int i = 0; i < player->inventory.count; i++) { Item item; diff --git a/components/openmw-mp/Packets/Player/PacketSpellbook.cpp b/components/openmw-mp/Packets/Player/PacketSpellbook.cpp index b725c253e..7673b3966 100644 --- a/components/openmw-mp/Packets/Player/PacketSpellbook.cpp +++ b/components/openmw-mp/Packets/Player/PacketSpellbook.cpp @@ -19,7 +19,7 @@ void PacketSpellbook::Packet(RakNet::BitStream *bs, BasePlayer *player, bool sen player->spellbook.spells.clear(); else player->spellbook.count = (unsigned int) (player->spellbook.spells.size()); - + RW(player->spellbook.count, send); for (int i = 0; i < player->spellbook.count; i++)