diff options
Diffstat (limited to 'src/server/scripts/Commands')
| -rw-r--r-- | src/server/scripts/Commands/cs_gm.cpp | 2 | ||||
| -rw-r--r-- | src/server/scripts/Commands/cs_list.cpp | 6 | ||||
| -rw-r--r-- | src/server/scripts/Commands/cs_misc.cpp | 2 |
3 files changed, 5 insertions, 5 deletions
diff --git a/src/server/scripts/Commands/cs_gm.cpp b/src/server/scripts/Commands/cs_gm.cpp index f6c0b021367..5aa36785018 100644 --- a/src/server/scripts/Commands/cs_gm.cpp +++ b/src/server/scripts/Commands/cs_gm.cpp @@ -142,7 +142,7 @@ public: handler->SendSysMessage("========================"); } std::string const& name = itr->second->GetName(); - uint8 size = name.size(); + uint8 size = uint8(name.size()); uint8 security = itrSec; uint8 max = ((16 - size) / 2); uint8 max2 = max; diff --git a/src/server/scripts/Commands/cs_list.cpp b/src/server/scripts/Commands/cs_list.cpp index 6c5fb2f70c9..89c21c324c6 100644 --- a/src/server/scripts/Commands/cs_list.cpp +++ b/src/server/scripts/Commands/cs_list.cpp @@ -244,7 +244,7 @@ public: if (count > resultCount) count -= resultCount; - else if (count) + else count = 0; } @@ -291,7 +291,7 @@ public: if (count > resultCount) count -= resultCount; - else if (count) + else count = 0; } @@ -366,7 +366,7 @@ public: if (count > resultCount) count -= resultCount; - else if (count) + else count = 0; } diff --git a/src/server/scripts/Commands/cs_misc.cpp b/src/server/scripts/Commands/cs_misc.cpp index 13df3bdcc2c..c9594eb29d5 100644 --- a/src/server/scripts/Commands/cs_misc.cpp +++ b/src/server/scripts/Commands/cs_misc.cpp @@ -1491,7 +1491,7 @@ public: // the max level of the new profession. uint16 max = maxPureSkill ? atoul(maxPureSkill) : targetHasSkill ? target->GetPureMaxSkillValue(skill) : uint16(level); - if (level <= 0 || level > max || max <= 0) + if (level <= 0 || level > max) return false; // If the player has the skill, we get the current skill step. If they don't have the skill, we |
