struct ABILITY_DEFINITION
An ability's definition, a row of AbilityDefinitions: its targeting, ability kind, element, effect, range, PP cost and power.
Declared in battle_unit.h.
Fields
| Name | Description | |
|---|---|---|
Uint8 | targetMode | ABILITY_TARGET. |
Uint8 | flags | bits: 7 usable in battle | 6 usable in the field | 5..4 clear in every row | 3..0 ability kind (ABILITY_FORMULA_MASK). |
Uint8 | element | ELEMENT. |
Uint8 | effect | ABILITY_EFFECT. |
Uint8 | icon | The icon the menus draw. |
Uint8 | reservedAfterIcon [3] | 0 in every row. |
Uint8 | range | The aimed unit and range - 1 either side, or ABILITY_RANGE_ALL. |
Uint8 | ppCost | PP the ability costs. |
Uint16 | power | The ability's power, as its ability kind reads it: for damage, about what the aimed target loses when the user's Power in the element equals the target's Resist (a summon adds to it, see ABILITY_FORMULA_SUMMON); for healing, about what the aimed target regains from a healer with 100 Power in the element; for an attack, what it adds to the blow at an even match, and for a multiplied one the blow's multiple in tenths. |
Uint8 | fieldPsynergy | The field Psynergy the ability works as, 1 (Move) to 16 (Avoid); 0 for none. |
Uint8 | reservedAfterType [3] | 0 in every row. |
Description
An ability's definition, a row of AbilityDefinitions: its targeting, ability
kind, element, effect, range, PP cost and power.
struct ABILITY_DEFINITION
Referenced by AbilityDefinitions, btAbilityApplyToTarget(), btActionOrderSort(), btActionRunBuild(), btAIChooseAction(), btAIChooseTarget(), gmAbilityGetDefinition(), mnAbilityApplyToTargets(), mnAbilityPlayUseSound(), mnBattleClassifyEntryKind(), mnBattleCollectPartyCommands(), mnBattleDjinnMenuShowChangePreview(), mnBattlePsynergyMenuRun(), mnItemClassifyUseMode(), mnPsynergyMenuClassifySelectedPsynergy(), mnPsynergyMenuCollectActions(), mnPsynergyMenuDrawPage(), mnPsynergyMenuIsActionRestricted(), mnPsynergyMenuRunList(), mnPsynergyMenuRunSteps(), mnStatusScreenDrawPsynergyPage() and mnStatusScreenShowPsynergyRow().
Definition at line 246 of file battle_unit.h.
Fields in detail
targetMode
Uint8 targetMode
flags
Uint8 flags
bits: 7 usable in battle | 6 usable in the
field | 5..4 clear in every row | 3..0
ability kind (ABILITY_FORMULA_MASK).
element
Uint8 element
effect
Uint8 effect
icon
Uint8 icon
The icon the menus draw.
reservedAfterIcon
Uint8 reservedAfterIcon[3]
0 in every row.
range
Uint8 range
The aimed unit and range - 1 either side, or
ABILITY_RANGE_ALL.
ppCost
Uint8 ppCost
PP the ability costs.
power
Uint16 power
The ability's power, as its ability kind
reads it: for damage, about what the aimed
target loses when the user's Power in the
element equals the target's Resist (a summon
adds to it, see ABILITY_FORMULA_SUMMON); for
healing, about what the aimed target regains
from a healer with 100 Power in the element;
for an attack, what it adds to the blow at
an even match, and for a multiplied one the
blow's multiple in tenths. The battle
README's "How an ability resolves" gives the
formulas.
fieldPsynergy
Uint8 fieldPsynergy
The field Psynergy the ability works as, 1 (Move) to 16 (Avoid); 0 for none. The field effects branch on it, and the Status screen counts it as usable in the field.
reservedAfterType
Uint8 reservedAfterType[3]
0 in every row.