Need for SetUncappedAbilityBonus() and similar functions
Taro94
Member Posts: 125
We've got functions for changing the cap on abilities, attack bonus, skills, etc, and that's definitely a good thing. Well, we could also use a function for setting dodge AC limit, but that's not the point of this thread.
While said functions are a step in the right direction, they can't be reliably used to grant bonuses that are meant to be uncapped, like bonuses from custom feats.
As such, a very appreciated addition would be the set of the following new functions (or functions to this effect):
SetUncappedAbilityBonus(object oCreature, int nAbility, int nValue)
SetUncappedAttackBonus(object oCreature, int nValue)
SetUncappedSkillBonus(object oCreature, int nSkill, int nValue)
SetUncappedACBonus(object oCreature, int nValue)
SetUncappedDamageBonus(object oCreature, int nValue)
SetUncappedSavingThrowBonus(object oCreature, int nSavingThrow, int nValue)
And getters to compliment these.
I hope I did not forget anything.
This way custom feat bonuses could be softcoded in the module itself, without using up the limit that's currently set on the score in question.
Of course, uncapped penalties could use some love, too, but bonuses are much more important due to the main use of uncapped modifiers being implementation of custom feat effects.
While said functions are a step in the right direction, they can't be reliably used to grant bonuses that are meant to be uncapped, like bonuses from custom feats.
As such, a very appreciated addition would be the set of the following new functions (or functions to this effect):
SetUncappedAbilityBonus(object oCreature, int nAbility, int nValue)
SetUncappedAttackBonus(object oCreature, int nValue)
SetUncappedSkillBonus(object oCreature, int nSkill, int nValue)
SetUncappedACBonus(object oCreature, int nValue)
SetUncappedDamageBonus(object oCreature, int nValue)
SetUncappedSavingThrowBonus(object oCreature, int nSavingThrow, int nValue)
And getters to compliment these.
I hope I did not forget anything.
This way custom feat bonuses could be softcoded in the module itself, without using up the limit that's currently set on the score in question.
Of course, uncapped penalties could use some love, too, but bonuses are much more important due to the main use of uncapped modifiers being implementation of custom feat effects.
4
Comments
And while you could change the limit to 22, apply attack bonus effect and change it back that would only work temporarily. This differs effect from effect but most of the effects are recalculated either every other while or when next effect is applied so this is not a solution either.
What we would need is either new set of functions or just UncappedEffect (which is what I do now in my nwnx plugin fo 1.69 - this functionality exists for 1.69) or possibility to set the BonusLimit functions for specific creature. Prefferably UncappedEffect as that allows much more applications than the BonusLimit on creature would (for example, you might not want to allow player to acquire +14 to all abilities, you just want him to get permanent +2dex bonus which will not count towards +12 cap - this would be only doable via UncappedEffect).
BTW I don't think that damage is *capped. The limitation is only in the values builder can use and he can remove this limitation by modifying iprp_*.2das.
People often play through singleplayer modules with the same characters, and then also in multiplayer localvault with those. It'd be horrible if some random SP module broke their character without notice.
Also maybe set ELC to be disabled by default when creating Internet/LAN game via client (I just tried it and in advanced settings ELC was checked for some reason). That would made sure that those servers that allows localvault (which are basically only servers created via this feature) will allow invalid characters - afterall this option is mostly going to be used amongst friends (at least without the NAT tunelling feature that was proposed to BeamDog on trello).
EDIT: safety idea - such function could fail to work when used in game that has ELC on. This would give control to players against this - they can turn on ELC for singleplayer in nwnplayer.ini, similarly it would prevent the login issues on servers using ELC.
Anyway, imo what is more important is to have UncappedEffect functionality. That is quite important for singleplayer content such as PRC or 3.5 ruleset and it can be also used as a workaround for permanent ability increase (with minor drawbacks). For multiplayer, the SetAbilityScore functionality is covered by NWNX.
If I understand correctly, you mean that using them in multiplayer could create many unintended problems because of their global effects? Therefore, you might not want to use them in multiplayer.
i suppose it could be workarounded by granting every other player +1attack bonus and -1 attack penalty in same time though... not pretty but might work
I'd say each of the categories of AC should have their own untyped/uncapped versions (so dodge might be lost when flatfooted, armour not working against touch attacks, etc, etc).
I'm mulling over ideas about how to do polymorphs that rely entirely on the player's base stats with added uncapped bonuses. For example, shifting to a dire bear no longer specifies what its base STR score is. Rather, it uses the player's base score + spells/items/abilities + a bonus determined in the shifting script. This way I can make the bear grow in strength with continued dedication to druid levels and even have Great Strength feats matter.
Being able to increase the cap limits allows this, but there's the issues with other builds exceeding the caps that I may not want. UncappedEffect() would be perfect for this.
https://trello.com/c/sZVjo92A/207-setuncappedabilitybonus-and-similar-functions
Just another reminder for those who might have missed this thread or trello card - if you like this idea, please vote on it.