diff options
Diffstat (limited to 'src/net/manaserv')
-rw-r--r-- | src/net/manaserv/inventoryhandler.cpp | 4 | ||||
-rw-r--r-- | src/net/manaserv/inventoryhandler.h | 4 | ||||
-rw-r--r-- | src/net/manaserv/partyhandler.cpp | 2 | ||||
-rw-r--r-- | src/net/manaserv/partyhandler.h | 11 | ||||
-rw-r--r-- | src/net/manaserv/playerhandler.cpp | 8 | ||||
-rw-r--r-- | src/net/manaserv/playerhandler.h | 8 |
6 files changed, 20 insertions, 17 deletions
diff --git a/src/net/manaserv/inventoryhandler.cpp b/src/net/manaserv/inventoryhandler.cpp index 75823be51..5e38354fb 100644 --- a/src/net/manaserv/inventoryhandler.cpp +++ b/src/net/manaserv/inventoryhandler.cpp @@ -151,7 +151,7 @@ void InventoryHandler::dropItem(const Item *item, int amount) gameServerConnection->send(msg); } -bool InventoryHandler::canSplit(const Item *item) +bool InventoryHandler::canSplit(const Item *item) const { return item && !item->isEquipment() && item->getQuantity() > 1; } @@ -212,7 +212,7 @@ size_t InventoryHandler::getSize(int type) const } } -int InventoryHandler::convertFromServerSlot(int eAthenaSlot) +int InventoryHandler::convertFromServerSlot(int eAthenaSlot) const { return eAthenaSlot; } diff --git a/src/net/manaserv/inventoryhandler.h b/src/net/manaserv/inventoryhandler.h index 6b24699b0..fbe53d735 100644 --- a/src/net/manaserv/inventoryhandler.h +++ b/src/net/manaserv/inventoryhandler.h @@ -84,7 +84,7 @@ class InventoryHandler : public MessageHandler, Net::InventoryHandler void dropItem(const Item *item, int amount); - bool canSplit(const Item *item); + bool canSplit(const Item *item) const; void splitItem(const Item *item, int amount); @@ -99,7 +99,7 @@ class InventoryHandler : public MessageHandler, Net::InventoryHandler size_t getSize(int type) const; - int convertFromServerSlot(int eAthenaSlot); + int convertFromServerSlot(int eAthenaSlot) const; private: EquipBackend mEquips; diff --git a/src/net/manaserv/partyhandler.cpp b/src/net/manaserv/partyhandler.cpp index b3d69e826..9a5f19678 100644 --- a/src/net/manaserv/partyhandler.cpp +++ b/src/net/manaserv/partyhandler.cpp @@ -186,7 +186,7 @@ void PartyHandler::chat(const std::string &text A_UNUSED) // TODO } -void PartyHandler::requestPartyMembers() +void PartyHandler::requestPartyMembers() const { //MessageOut msg(PCMSG_GUILD_GET_MEMBERS); diff --git a/src/net/manaserv/partyhandler.h b/src/net/manaserv/partyhandler.h index 45cc39e05..7403d0e36 100644 --- a/src/net/manaserv/partyhandler.h +++ b/src/net/manaserv/partyhandler.h @@ -65,13 +65,16 @@ public: void chat(const std::string &text); - void requestPartyMembers(); + void requestPartyMembers() const; - PartyShare getShareExperience() { return PARTY_SHARE_NO; } + PartyShare getShareExperience() const + { return PARTY_SHARE_NO; } - void setShareExperience(PartyShare share A_UNUSED) {} + void setShareExperience(PartyShare share A_UNUSED) + { } - PartyShare getShareItems() { return PARTY_SHARE_NO; } + PartyShare getShareItems() const + { return PARTY_SHARE_NO; } void setShareItems(PartyShare share A_UNUSED) {} private: diff --git a/src/net/manaserv/playerhandler.cpp b/src/net/manaserv/playerhandler.cpp index 5ac058b7e..1194cb9f2 100644 --- a/src/net/manaserv/playerhandler.cpp +++ b/src/net/manaserv/playerhandler.cpp @@ -417,22 +417,22 @@ void PlayerHandler::ignoreAll(bool ignore A_UNUSED) // TODO } -bool PlayerHandler::canUseMagic() +bool PlayerHandler::canUseMagic() const { return true; } -bool PlayerHandler::canCorrectAttributes() +bool PlayerHandler::canCorrectAttributes() const { return true; } -int PlayerHandler::getJobLocation() +int PlayerHandler::getJobLocation() const { return -1; } -Vector PlayerHandler::getDefaultWalkSpeed() +Vector PlayerHandler::getDefaultWalkSpeed() const { // Return translation in pixels per ticks. return ManaServ::BeingHandler::giveSpeedInPixelsPerTicks(6.0f); diff --git a/src/net/manaserv/playerhandler.h b/src/net/manaserv/playerhandler.h index 2460877ec..dcd05d5fc 100644 --- a/src/net/manaserv/playerhandler.h +++ b/src/net/manaserv/playerhandler.h @@ -70,12 +70,12 @@ class PlayerHandler : public MessageHandler, public Net::PlayerHandler void ignorePlayer(const std::string &player, bool ignore); void ignoreAll(bool ignore); - bool canUseMagic(); - bool canCorrectAttributes(); + bool canUseMagic() const; + bool canCorrectAttributes() const; - int getJobLocation(); + int getJobLocation() const; - Vector getDefaultWalkSpeed(); + Vector getDefaultWalkSpeed() const; private: void handleMapChangeMessage(Net::MessageIn &msg); |