[Quest API] Add Override Parameters to ScaleNPC() in Perl/Lua. (#2816)

# Perl
- Add `$npc->ScaleNPC(level, always_scale_stats)`.
- Add `$npc->ScaleNPC(level, always_scale_stats, always_scale_special_abilities)`.

# Lua
- Add `npc:ScaleNPC(level, always_scale_stats)`.
- Add `npc:ScaleNPC(level, always_scale_stats, always_scale_special_abilities)`.

# Notes
- Allows operators to not have to set stats to 0 in order for scaling to kick in when scripting.
- Special ability override is separate in case you don't want to override some inherent special abilities the NPC has from a script or otherwise.
This commit is contained in:
Alex King
2023-01-31 21:11:05 -05:00
committed by GitHub
parent 2e575652f6
commit f410c89815
7 changed files with 150 additions and 92 deletions
+3 -1
View File
@@ -141,7 +141,6 @@ public:
void SetSimpleRoamBox(float box_size, float move_distance, int move_delay);
void RecalculateSkills();
void ReloadSpells();
void ScaleNPC(uint8 npc_level);
bool IsRaidTarget();
bool IsRareSpawn();
void ChangeLastName(std::string last_name);
@@ -173,6 +172,9 @@ public:
void SetLDoNLockedSkill(uint16 skill_value);
bool IsLDoNTrapDetected();
void SetLDoNTrapDetected(bool is_detected);
void ScaleNPC(uint8 npc_level);
void ScaleNPC(uint8 npc_level, bool always_scale_stats);
void ScaleNPC(uint8 npc_level, bool always_scale_stats, bool always_scale_special_abilities);
};
#endif