-
- Downloads
NPC Class Autoleveling
Updated the way NPCs (randbosses) are assigned character classes (game.state:applyRandomClass). The new method makes high level NPCs with character classes scale like player levels and tends to increase the number of talents randomly learned while limiting the maximum talent levels. This is a nerf for high level randbosses (including those enhanced due to game difficulty) and a buff for fixed bosses that are updated, while making turning their difficulty much simpler. This replaces the previous method of assigning an increasing number of class talents at maximum level, that could result in boss's skills scaling much faster than its actor level. Talents are learned randomly one level at a time and are restricted by the normal progression of talent and stat points and all normal talent restrictions. After setup, NPCs automatically advance in their character classes when gaining levels, tending to focus their talent choices with randomly determined preferred categories. Random bosses and bosses enhanced for game difficulty can use "partial" character classes. Game balance tuning is handled my adjusting the number of added classes. Adjusted the number of character classes assigned at higher difficulties: NIGHTMARE -- max 1 random class (BUFF), INSANE -- max 2 random classes , MADNESS -- max 3 random classes NPC (fixed boss) definitions can be updated to specify automatic class advancement begining at a certain level and rate. This allows many bosses that become unchallenging on advanced difficulties or when spawning in the I.D. to be easily buffed by specifying character class advancement based on level. Summary of function changes: Actor:learnStats(statorder, repeats) Updated to maintain the current stat index within the passed statorder table. This allows multiple stat progressions to be applied to the same Actor and repeated multiple times with the same function call. Actor:levelupClass(c_data) New function to automatically assign character class levels to an actor according to c_data. Sets up the self.auto_classes table, retrieves data as needed from class birth descriptors. Assigns stat/talent/category points randomly on a level-by-level basis. Actor:resolveLevelTalents() Updated to process any self.auto_classes defined game.state:applyRandomClass(b, data, instant) Works as before, but is updated to use Actor:levelupClass to set up class definitions. nb_classes can be a flotaing point number, allowing "fractional" classes to be assigned: (1.5 == one class at 100% actor level plus another class at 50% of actor level). The instant parameter forces advancement in the class(es) immediately. Fixed a bug where auto_equip_filters were being copied even when forbid_equip was set. game.state:createRandomBoss(base, data) By default, randombosses are nerfed slightly, getting 1.75 random classes by default. NPC:addedToLevel(level, x, y) Higher game difficulties assign fewer randomclasses based on rank, which may be partial classes: NIGHTMARE -- up to 1 random class, INSANE -- up to 2 random classes, MADNESS -- up to 3 random classes Random bosses gain extra character classes at 1/2 the rate of fixed bosses. resolvers.sustains_at_birth() Will check that a talent is inactive before trying to activate it. resolvers.talented_ai_tactic(method, tactic_emphasis, weight_power) May specify "instant" as the method to force recalculating the talent table immediately when resolved (instead of through on_added_to_level). RandomActor debug Dialog: updated Help reference to show header for Actor:levelupClass SummonCreature debug Dialog: updated to spawn the alchemy golem if needed
parent
e96a567f
No related branches found
No related tags found
Showing
- game/modules/tome/class/Actor.lua 395 additions, 17 deletionsgame/modules/tome/class/Actor.lua
- game/modules/tome/class/GameState.lua 98 additions, 160 deletionsgame/modules/tome/class/GameState.lua
- game/modules/tome/class/NPC.lua 10 additions, 18 deletionsgame/modules/tome/class/NPC.lua
- game/modules/tome/dialogs/debug/RandomActor.lua 9 additions, 4 deletionsgame/modules/tome/dialogs/debug/RandomActor.lua
- game/modules/tome/dialogs/debug/SummonCreature.lua 2 additions, 0 deletionsgame/modules/tome/dialogs/debug/SummonCreature.lua
- game/modules/tome/resolvers.lua 17 additions, 9 deletionsgame/modules/tome/resolvers.lua
Please register or sign in to comment