mirror of
https://github.com/EQEmu/Server.git
synced 2025-12-12 09:31:30 +00:00
[Cleanup] Default skill type to Hand to Hand in #npcedit meleetype (#3422)
# Notes - We default to `28` in the database, so we need to default to this in `#npcedit meleetype` in case the operator only sets the first melee type this avoids the NPC hitting with `1H Blunt (Skill ID 0)`.
This commit is contained in:
parent
5fcc83b4b6
commit
71ca7f9b39
@ -549,7 +549,7 @@ void command_npcedit(Client *c, const Seperator *sep)
|
|||||||
} else if (!strcasecmp(sep->arg[1], "meleetype")) {
|
} else if (!strcasecmp(sep->arg[1], "meleetype")) {
|
||||||
if (sep->IsNumber(2)) {
|
if (sep->IsNumber(2)) {
|
||||||
auto primary_type = Strings::ToUnsignedInt(sep->arg[2]);
|
auto primary_type = Strings::ToUnsignedInt(sep->arg[2]);
|
||||||
uint32_t secondary_type = sep->IsNumber(3) ? Strings::ToUnsignedInt(sep->arg[3]) : 0;
|
uint32_t secondary_type = sep->IsNumber(3) ? Strings::ToUnsignedInt(sep->arg[3]) : EQ::skills::SkillHandtoHand;
|
||||||
|
|
||||||
auto primary_skill = EQ::skills::GetSkillName(static_cast<EQ::skills::SkillType>(primary_type));
|
auto primary_skill = EQ::skills::GetSkillName(static_cast<EQ::skills::SkillType>(primary_type));
|
||||||
auto secondary_skill = EQ::skills::GetSkillName(static_cast<EQ::skills::SkillType>(secondary_type));
|
auto secondary_skill = EQ::skills::GetSkillName(static_cast<EQ::skills::SkillType>(secondary_type));
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user