Skip to main content

Stat Modificiation

Stat modification occurs when a buff or debuff is applied to a target, and an array of stats is changes either additively (positive or negative) or multiplicatively (with values greater than or less than 1).

apply_buff
This function applies the stat modifications of a buff to the stats_add and stats_mult dictionaries of the target, and calls the calc_current_from_base_partial function, which recalculates the modified stats with the newly updated modifiers. It uses the spell, the source name, and the target as arguments.

remove_buff
This function removes the stat modifications of a buff or debuff from the stats_add and stats_mult dictionaries of the target, and calls the calc_current_from_base_partial function, which recalculates the modified stats with the newly updated modifiers. It uses the spell, the source name, and the target as arguments.