mirror of
https://github.com/EQEmu/Server.git
synced 2025-12-11 21:01:29 +00:00
[Commands] Overhauled #npcedit. (#1538)
* [Commands] Overhauled #npcedit. - Added missing columns like untargetable, show_name, exp_mod, etc. - Put stats in order of column appearance in table within help message and within code. - Converted StringFormat to fmt::format. - Added a GetGenderName() helper method. - Prettified response messages of nearly every #npcedit option. All tested and ready to go. Would like input about possibly changing some of the command arguments to match the table column names more closely, example being "spell" should be "npc_spells_id". * Cleanup. * Fix indentation.
This commit is contained in:
parent
6a5face0aa
commit
c0de178173
@ -2232,3 +2232,15 @@ bool PlayerAppearance::IsValidWoad(uint16 race_id, uint8 gender_id, uint8 woad_v
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
const char* GetGenderName(uint32 gender_id) {
|
||||
const char* gender_name = "Unknown";
|
||||
if (gender_id == MALE) {
|
||||
gender_name = "Male";
|
||||
} else if (gender_id == FEMALE) {
|
||||
gender_name = "Female";
|
||||
} else if (gender_id == NEUTER) {
|
||||
gender_name = "Neuter";
|
||||
}
|
||||
return gender_name;
|
||||
}
|
||||
@ -851,6 +851,7 @@
|
||||
|
||||
const char* GetRaceIDName(uint16 race_id);
|
||||
const char* GetPlayerRaceName(uint32 player_race_value);
|
||||
const char* GetGenderName(uint32 gender_id);
|
||||
|
||||
uint32 GetPlayerRaceValue(uint16 race_id);
|
||||
uint32 GetPlayerRaceBit(uint16 race_id);
|
||||
|
||||
1432
zone/command.cpp
1432
zone/command.cpp
File diff suppressed because it is too large
Load Diff
@ -3439,14 +3439,7 @@ void QuestManager::SetEXPModifierByCharID(uint32 character_id, uint32 zone_id, d
|
||||
}
|
||||
|
||||
std::string QuestManager::getgendername(uint32 gender_id) {
|
||||
auto gender_name = "Unknown";
|
||||
if (gender_id == MALE) {
|
||||
gender_name = "Male";
|
||||
} else if (gender_id == FEMALE) {
|
||||
gender_name = "Female";
|
||||
} else if (gender_id == NEUTER) {
|
||||
gender_name = "Neuter";
|
||||
}
|
||||
std::string gender_name = GetGenderName(gender_id);
|
||||
return gender_name;
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user