diff --git a/apps/openmw-mp/Books.cpp b/apps/openmw-mp/Books.cpp index 9f788a016..cffe4281a 100644 --- a/apps/openmw-mp/Books.cpp +++ b/apps/openmw-mp/Books.cpp @@ -56,4 +56,4 @@ void Books::processUpdate() packet->setPlayer(player); packet->Send(/*toOthers*/ false); -} \ No newline at end of file +} diff --git a/apps/openmw-mp/Inventory.cpp b/apps/openmw-mp/Inventory.cpp index 87e18cfa0..fde8df3e5 100644 --- a/apps/openmw-mp/Inventory.cpp +++ b/apps/openmw-mp/Inventory.cpp @@ -46,7 +46,7 @@ Inventory::~Inventory() void Inventory::update() { printf("Inventory::update()"); - /*if(isEquipmentChanged()) + /*if (isEquipmentChanged()) { if (netActor->isPlayer()) { @@ -100,7 +100,7 @@ void Inventory::equipItem(unsigned short slot, const std::string& refId, unsigne if (!Utils::vectorContains(&netActor->getNetCreature()->equipmentIndexChanges, slot)) netActor->getNetCreature()->equipmentIndexChanges.push_back(slot); - if(!equipmentChanged && netActor->isPlayer()) + if (!equipmentChanged && netActor->isPlayer()) netActor->toPlayer()->addToUpdateQueue(); equipmentChanged = true; @@ -114,7 +114,7 @@ void Inventory::unequipItem( unsigned short slot) void Inventory::addItem(const std::string &refId, unsigned int count, int charge, float enchantmentCharge) { - if(!inventoryChanged) + if (!inventoryChanged) resetInventoryFlag(); mwmp::Item item; @@ -131,7 +131,7 @@ void Inventory::addItem(const std::string &refId, unsigned int count, int charge void Inventory::removeItem(const std::string &refId, unsigned short count) { - if(!inventoryChanged) + if (!inventoryChanged) resetInventoryFlag(); mwmp::Item item; item.refId = refId; diff --git a/apps/openmw-mp/NetActor.cpp b/apps/openmw-mp/NetActor.cpp index 09228a507..f4d7c6677 100644 --- a/apps/openmw-mp/NetActor.cpp +++ b/apps/openmw-mp/NetActor.cpp @@ -40,7 +40,7 @@ void NetActor::setPosition(float x, float y, float z) netCreature->position.pos[1] = y; netCreature->position.pos[2] = z; - if(!positionChanged && isPlayer()) + if (!positionChanged && isPlayer()) toPlayer()->addToUpdateQueue(); positionChanged = true; } diff --git a/apps/openmw-mp/Players.cpp b/apps/openmw-mp/Players.cpp index 58fea7c7f..fdde20188 100644 --- a/apps/openmw-mp/Players.cpp +++ b/apps/openmw-mp/Players.cpp @@ -145,4 +145,4 @@ void Players::processUpdated() void Players::addToQueue(Player *player) { updateQueue.push(player); -} \ No newline at end of file +} diff --git a/apps/openmw-mp/Script/CommandController.hpp b/apps/openmw-mp/Script/CommandController.hpp index 7be9b173c..eff95aead 100644 --- a/apps/openmw-mp/Script/CommandController.hpp +++ b/apps/openmw-mp/Script/CommandController.hpp @@ -60,4 +60,4 @@ public: private: std::deque cmdParser(const std::string &message); Container commands; -}; \ No newline at end of file +}; diff --git a/apps/openmw-mp/Script/EventController.hpp b/apps/openmw-mp/Script/EventController.hpp index b94d10084..d9adfa87c 100644 --- a/apps/openmw-mp/Script/EventController.hpp +++ b/apps/openmw-mp/Script/EventController.hpp @@ -185,7 +185,7 @@ public: template R Call(Args&&... args) { - if(canProvideOldState) + if (canProvideOldState) events.at(event).callWOld(std::forward(args)...); else return events.at(event).call(CallbackCollection::type_tag{}, std::forward(args)...); diff --git a/apps/openmw-mp/Timer.cpp b/apps/openmw-mp/Timer.cpp index f2193bd71..5847a72e3 100644 --- a/apps/openmw-mp/Timer.cpp +++ b/apps/openmw-mp/Timer.cpp @@ -72,7 +72,7 @@ void Timer::tick() if (time - startTime >= targetMsec) { end = true; - if(callback.valid()) + if (callback.valid()) { LOG_MESSAGE_SIMPLE(Log::LOG_TRACE, "Timer::tick time expired, callback %p valid", callback.registry_index()); callback.call(data); @@ -126,7 +126,7 @@ void TimerController::tick() LOG_MESSAGE_SIMPLE(Log::LOG_TRACE, "Deleted %d timers\n", deleted); } - if(!newTimersQueue.empty()) + if (!newTimersQueue.empty()) { timers.insert(timers.begin(), make_move_iterator(newTimersQueue.begin()), make_move_iterator(newTimersQueue.end())); LOG_MESSAGE_SIMPLE(Log::LOG_TRACE, "Created %d timers\n", newTimersQueue.size());