In my game, I have mounted characters and their base attack ability has to change when they're mounted or afoot. Because there is no condition for Weapons/Attack Settings/Override Attack, I can't specify which ability to use as an override depending on a status effect or something. However, I use grid combat and an Attack of Opportunity mechanic that uses the Grid Move Out of Range node in which uses the base attack for its use range. So, the best think I thought I should do was to set the base attack through code. I tried it with Combatant.Setting.baseAttack (which requires a ActiveAbilitySelection[] type, which I create and populate with the ability I want). However, I'm not sure it changes the combatant instance or the editor combatant. Also, when I use combatant.Abilities.GetCurrentBaseAttack(), it does not return the new base attack. Is there a function to set the current base attack?
combatant.Abilities.InitAttacks();
I think the best option would be to use a special, hidden weapon and hidden equipment part for this. The weapon can override the base attack, so just equip the weapon when mounting, and unequip it when dismounting.
Having the weapon on a different (hidden) equipment part would prevent interference with your other equipment, and the player doesn't know anything bout it :)
If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
Do you foresee any problem with this method?
Hm, I don't think there's currently an easy way to get them - you'd have to go through the equipment's ability settings and get the abilities from the combatant via the ability's ID.
If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
EquipAbilityShortcut equipAbilityShortcut= abilityShortcutList[i] as EquipAbilityShortcut;
This enables me to check equipAbilityShortcut.Equipment.