fgo-docs

Buff actions values are calculated using the following formula:

num = buffAction.baseParam + (total plusTypes buffs values) - (total minusTypes buff values)

if buffAction.limit in (normal, lower):
    if num < 0:
        num = 0

num = num - buffAction.baseValue;

if buffAction.limit in (normal, upper):
    if maxRate < num:
        num = maxRate

return num