Skip to content
cyrite edited this page Jan 14, 2024 · 3 revisions

Overview

The Buffer role is responsible for casting buffs on itself and its party members.

Modes

See AutoBuffMode

How it works

A Buffer will maintain a list of buffs on both itself and its party members as specified in the job settings when AutoBuffMode is set to Auto. There is a cooldown of 8 seconds between each buff. Buffs will be applied in the following order:

Self Buffs (Job Abilities)

These include buffs that can be applied using a Job Ability, e.g. Berserk, Aggressor, Light Arts or Composure.

Self Buffs (Spells)

These include buffs that can be applied to the Buffer using Enhancing Magic, Blue Magic, Black Magic or Ninjutsu. For Summoning Magic, see SMN.

Party Buffs (Spells)

These include buffs that can be applied to party members using Enhancing Magic, Blue Magic, Black Magic or Ninjutsu. For Summoning Magic, see SMN.

Settings

Example settings from addons/Trust/data/RDM.lua:

JobAbilities = L{
  JobAbility.new('Composure', L{}, L{}, nil),
},
SelfBuffs = L{
  Buff.new('Refresh'),
  Buff.new('Haste'),
  Buff.new('Temper', L{}, L{}, nil, L{ InBattleCondition.new() }),
  Spell.new('Enblizzard', L{}, L{}, nil, L{ InBattleCondition.new() }),
  Spell.new('Gain-INT', L{}, L{}, nil, L{ IdleCondition.new() }),
  Spell.new('Gain-STR', L{}, L{}, nil, L{ InBattleCondition.new() }),
  Spell.new('Phalanx'),
  Buff.new('Protect'),
  Buff.new('Shell')
},
PartyBuffs = L{
  Buff.new('Refresh', L{}, L{'DRK','PUP','PLD','BLU','BLM','BRD','GEO','SMN','WHM','RUN'}),
  Buff.new('Haste', L{}, job_util.melee_jobs():extend(L{'SCH','BLM'})),
  Buff.new('Haste', L{}, L{ 'COR' }, nil, L{ InBattleCondition.new() }),
  Buff.new('Flurry', L{}, L{'RNG','COR'}, nil, L{ IdleCondition.new() }),
  Spell.new('Phalanx II', L{}, job_util.melee_jobs(), nil, L{ InBattleCondition.new() }),
}

Job Abilities

A list of job abilities that apply buffs, e.g. Berserk, Aggressor, Light Arts or Composure. Used in JobAbilities. A new job ability can be created with the syntax JobAbility.new(job_ability_name, conditions, job_names, target).

Parameter Values Description Example
job_ability_name Any job ability name in res/job_abilities.lua that applies a buff Name of the job ability Berserk or Composure
conditions L{condition1, condition2,..., conditionN} or L{} (see Conditions) List of conditions that must be satisfied before using this job ability L{InBattleCondition.new()}, L{IdleCondition.new()}, or L{} (none)
job_names L{} (other options not currently supported) If the job ability can target other player's it will only be used on players on these jobs L{'COR', 'RNG'} or job_util.all_jobs()
target nil (automatically determine), bt, p0, p1, p2, p3, p4, p5 Job ability target override. Recommended to use nil and let Buffer automatically determine the target nil

Spells

A list of spells that apply buffs with configurable conditions. Use this if you always want the Buffer to cast a specific spell. A new spell can be created with the syntax Spell.new(spell_name, job_abilities, job_names, target, conditions, consumable).

Parameter Values Description Example
spell_name Any spell name in res/spells.lua Name of the spell Refresh II or Haste
job_abilities L{JobAbilityName1, JobAbilityName2,..., JobAbilityNameN} or L{} (see Job Abilities) List of job ability names to be used before casting this spell L{'Accession', 'Perpetuance'} or L{} (none)
job_names job_util.all_jobs(), job_util.melee_jobs(), L{JobShort1, JobShort2,..., JobShortN} The spell will only be cast on these jobs L{'COR', 'RNG'} or job_util.all_jobs()
target nil (automatically determine), bt, p0, p1, p2, p3, p4, p5 Spell target override. Recommended to use nil and let Buffer automatically determine the target nil
conditions See Conditions A list of conditional checks that must pass before casting the buff L{ InBattleCondition.new() } or L{}
consumable Any item name in res/items.lua A consumable that must be used to cast the spell Shihei

Buffs

A list of buffs to apply with configurable conditions. Unlike a Spell, a Buff will automatically determine the highest tier spell that can be cast to apply the buff, e.g. Buff.new('Haste') will cast Haste if the Buffer is a White Mage but Haste II if the Buffer is a Red Mage. A new buff can be created with the syntax Buff.new(spell_name, job_abilities, job_names, spell_prefix, conditions).

Parameter Values Description Example
spell_name Any spell name in res/spells.lua Name of the lowest tier of the spell Refresh or Regen
job_abilities L{JobAbilityName1, JobAbilityName2,..., JobAbilityNameN} or L{} (see Job Abilities) List of job ability names to be used before casting this spell L{'Accession', 'Perpetuance'} or L{} (none)
job_names job_util.all_jobs(), job_util.melee_jobs(), L{JobShort1, JobShort2,..., JobShortN} The spell will only be cast on these jobs L{'COR', 'RNG'} or job_util.all_jobs()
spell_prefix nil Deprecated, use a value of nil. nil
conditions See Conditions A list of conditional checks that must pass before casting the buff L{ IdleCondition.new() } or L{}

Jobs

  • BLM
  • BLU
  • DNC
  • DRK
  • GEO
  • MNK
  • NIN
  • PLD
  • PUP
  • RDM
  • RNG
  • RUN
  • SAM
  • SCH
  • WAR
  • WHM

Explore the code

Clone this wiki locally