Abilities

Attacks, skills, magic … a crucial part of any role-playing game – in ORK Framework all of this is handled using abilities.

Ability Types #

Ability types are used to organize abilities by separating them into different types. Ability types also define the damage type of it’s abilities (each ability can optionally override it) – learn more about damage types in this documentation.

You’ll mainly use them to filter abilities in the editor and in-game menus (menu screens, battle menus). Ability types can be sub-types of other ability types for a more detailed organization.

The ability type also defines the item type of it’s abilities, e.g. for when they’re sold in shops.

Ability types are set up in Status > Ability Types.

Abilities #

Abilities are used as a combatant’s base attack (i.e. their default ability, you can also use support abilities like heal as a base attack), their counter attack and learnable abilities. Classes can also have a class ability.

There are two types of abilities:

  • Active abilities
    They are used on a target combatant and change their status (e.g. an attack dealing damage or a healing spell recovering health).
  • Passive abilities
    They can’t be used, but give status bonuses to a combatant who has the ability.

If an ability is active or passive is determined by the Useable In setting – None makes it a passive ability.

Abilities can have multiple levels – leveling up can be done in different ways:

  • None
    The ability can’t be leveled up.
    New levels must be learned through ability development (class/combatant level up), research trees, items or schematics.
  • Auto
    The ability will automatically receive the defined Experience type status value when the combatant receives experience points.
  • Spend
    The player must spend experience points on the ability to level it up.
    This can e.g. be done using menu screens.
  • Uses
    The ability must be used a defined number of times to level up.

Abilities are set up in Status > Abilities.

Active Abilities #

Active abilities can either be used in the field, in battles, or in both. If the ability can be used can also be decided by certain status conditions (like having a special attack stance in form of a status effect that must be applied to the user), or only if another ability has been used prior to the ability (i.e. ability combos).

If the ability will hit a target can optionally epend on a hit chance – an optional critical hit chance with other status changes is available as well.

An ability can optionally be set up as a priority action, i.e. it’ll be used before other actions.

An ability can optionally be cancelable, i.e. if the user is hit by another ability or item that is set up to cancel actions while using the ability, the use is canceled. When the ability is animated using schematics, only nodes that have Execute On Stop enabled will be used.

Target Selection #

An active ability is used on a target combatant. The target can be the user itself, an ally or enemy – or just any combatant. It can target a single combatant, the whole group or be used as an AoE (area of effect) spell.

The Use Range of the ability defines how far away a target can be from the user. Grid battles can also use complex grid shapes for this. Combatants that are nearby a target can be affected using the Affect Range of the ability.
You can use Battle Range Templates to create reusable range settings in Templates > Battle Range Templates.

If a target is available can also depend on certain conditions, e.g. a status condition or physical orientation (e.g. only available when at the back of a target).

Use Costs #

An ability can optionally require costs to use it – the ability can only be used if the costs are covered.

The following use costs are available.

  • Use Count
    The ability can be used a number of times.
    The use count can be reset automatically, e.g. at the start of a battle or end of a turn.
  • Status Changes
    The use costs can perform status changes, e.g. subtract MP.
    See below for details on status changes.
  • Consume Items
    Using the ability will consume defined items.

Status Changes #

Status changes are used by use costs, user and target changes.

User changes (normal and critical) use the user of the ability as both user and target in any calculation and are used once.

Target changes (normal and critical) use the user of the ability as user, and each individual target as target – they’re used for each user/target combination. E.g. an ability targeting multiple combatants will have a calculation for each target.

The following status changes are available.

  • Status Value
    Uses a defined status value change, e.g. dealing damage, healing, etc.
    This can change any status value and optionally consider attack/defence modifiers for the outcome.
  • Status Effect
    Uses a defined status effect change, e.g. adding poison.
    You can use status effects or status effect types, e.g. removing all negative status effects via a type.
    Learn more about status effects in this documentation.
  • Schematics
    Uses a defined schematic.
    The user is the Machine Object, the target the Starting Object.
    The ability is available as local selected data via the selected key action.

You can extend the available status changes with custom classes by deriving from the BaseStatusChangeType class.

Steal #

Active abilities can optionally steal items or currency from a target.

The settings can be found in Use Settings > Battle Settings > Steal Settings of the ability.

Animating an ability’s use #

Using an ability can be animated using schematics.

This can e.g. be used to let the user run to the target, play an attack animation, handle damage calculation at the right time and return to the original position. Or throw a fireball prefab at the enemy – the full potential of the schematic system can be used and also extended with custom code.

The schematics can also be used to greatly increase the functionality of an ability, e.g. capturing an enemy by adding it to the player group, cause damage multiple times and many other things.

Abilities can also use default schematics before and after their own schematics. The Ability Start Animation and Ability End Animation schematics are set up in Combatants > Combatants > General Settings in Battle Settings > Default Battle Animations.

Passive Abilities #

A passive ability can’t be used – instead it can give a constant bonus to various  statuses:

  • Status values
  • Attack/defence attributes
  • Status effects (auto effects, immunity to effects)
  • Chances (hit, counter, block, critical, escape, steal)
  • Movement speeds (walk, run, sprint)
  • Equipment slot changes (blocking slots, adding slots)

Most of the bonuses are handled by status bonuses – learn more about them in this documentation.

Toggleable #

Passive abilities can optionally be turned on or off – this is defined by the Passive State Type.

  • Always Enabled
    The ability is always turned on and can’t be toggled on/off.
  • Start Enabled
    The ability starts enabled (e.g. when learned) and can be toggled on/off.
  • Start Disabled
    The ability starts disabled (e.g. when learned) and can be toggled on/off.

Toggleable abilities can be turned on/off in menu screens and battle menus.

If an ability is turned off, it’ll not give any of it’s bonuses or other benefits.

Other uses #

Passive abilities can be used for status condition checks, which makes them a useful permanent marker for combatants.

You can e.g. use them in a combatant’s conditional prefabs to change the look of the combatant, check for them in formulas to influence a calculation and in many other parts of ORK.

UI #

Define UI related settings for the ability.

Shortcut UI #

Abilities are shortcuts and use the Shortcut UI settings to control how they’re displayed in menu screens and shortcut HUDs.

Learn more in this HUD documentation.

Portraits #

Add portraits to abilities and display them in menu screens or HUDs.

Information Overrides #

Abilities can override default number formatting, battle info, notifications and console texts.

Custom Schematics #

Custom schematics can be used on an instance of an ability in other schematics using a Custom Selected Data Schematic node. The ability is available as (local) selected data via the key action.

They can be used to create custom systems, e.g. a custom ability leveling system.

Ability Variables #

Both active and passive abilities can use custom variables that are attached to their individual instances. These variables can be accessed in schematics via abilities stored in selected data.

This allows adding custom systems and functionality to abilities. The ability is available as selected data via the selected key action in all of it’s formula calculations, as well as all schematics used by it (e.g. for animating or in status changes).

Learning Abilities #

Combatants can learn abilities in different ways.

Ability Development #

Ability developments define which abilities will be learned at which level or class level.

They’re used by combatants and classes as templates for a reusable setup. Combatants/classes can use multiple ability developments, but also add custom setups to learn an ability at a specific level or class level.

Ability developments are set up in Status > Ability Developments.

Research Trees #

Research trees are used to learn different things, e.g. abilities, status value changes or creating items. Each research item can depend on certain conditions and require costs to learn (e.g. items, currency or status values).

Using research trees allow setting up purchaseable abilities, that can e.g. be learned by spending Experience type status values on them.

Research trees are set up in Combatants > Research Trees.

Items #

Items can learn abilities to the target when used.

The settings can be found in Use Settings > Ability Settings of an item.

Schematics #

Schematics can change the abilities of a combatant. Beside learning new abilities, schematics can also remove abilities or change their level.

See the Combatant > Ability nodes for all available nodes.

Setup Examples #

Here are some examples for setting up different kinds of abilities.

These examples will only focus on the ability setup, i.e. it’ll not cover setting up a used formula or animating via schematics.

Base Attack #

This ability setup is used for regular physical attacks – using a hit chance, critical chance and no use costs.

Ability Settings #

  • Useable In
    Select Battle.
    The attack is only available while in battle.

Use Settings #

  • Counterable
    Enable this setting.
    The attack can be countered (i.e. the attacked combatant will use it’s counter attack).
  • Hit Chance
    Enable this setting.
  • Hit Chance (%)
    Select Value > Formula.
    Select your Hit Chance formula.
    Or use whatever other value you want for the hit chance.
    Using a formula will automatically set up User and Target settings to use the ability’s user and target.
  • Critical Hit
    Enable this setting.
  • Critical Chance (%)
    Select Value > Formula.
    Select your Critical Chance formula.
    Or use whatever other value you want for the critical chance.

Target Selection Settings #

  • Target Type
    Select Enemy.
  • Target Range
    Select Single.

Target Settings > Target Changes #

Click on Add Target Changes.

  • Use Attack Effects
    Enable this setting.
  • Use Defence Effects
    Enable this setting.

Click on Add Status Change.

  • Change Type
    Select Status Value.
  • Status Value
    Select HP (or however your health consumable status value is named).
  • Operator
    Select Sub.
  • Change Value
    Select Value > Formula.
    Select your Physical Damage formula.
    Or use whatever other value you want for the damage.
  • Use Change Modifiers
    Enable this setting.
    This will make the damage calculation take selected attack/defence modifiers into account.
  • Use Effect Modifiers
    Select Replace.
    This’ll use attack modifiers from status effects to allow enchanting the attack.

Click on Add Attack Modifier.

  • Attack Modifier
    Select Element (or whatever modifier you want to use).
  • Attribute
    Select Normal (or whatever element/attribute you want to use).

Target Settings > Target Critical Changes #

The setup here is used for calculating the result of a critical hit and is the same as for Target Settings > Target Changes, just with either a different Change Value (e.g. using a different formula) or a higher Efficiency value.

Healing Magic #

A magical spell recovering health, costing MP and available both in battle and the field.

Ability Settings #

  • Useable In
    Select Both.

Target Selection Settings #

  • Target Type
    Select Ally.
  • Target Range
    Select Single.

User Settings > Use Cost > Status Changes #

Click on Add Status Change.

  • Change Type
    Select Status Value.
  • Status Value
    Select MP (or however your magic consumable status value is named).
  • Operator
    Select Sub.
  • Change Value
    Select Value > Value.
    Set to 5.
    Or use whatever other value you want for the cost.
  • Use Change Modifiers
    Disable this setting.
    Use costs should usually not be influenced by attack/defence modifiers.

Target Settings > Target Changes #

Click on Add Target Changes.

Click on Add Status Change.

  • Change Type
    Select Status Value.
  • Status Value
    Select HP (or however your health consumable status value is named).
  • Operator
    Select Add.
  • Change Value
    Select Value > Formula.
    Select your Healing formula.
    Or use whatever other value you want for the recovery.
  • Use Change Modifiers
    Disable this setting.
    Like with use costs, health recovery is usually not influenced by modifiers.

Buff Magic #

Buffs the whole group with a status effect – I’ll not use a use cost here, see the Healing Magic example for that setup.

Ability Settings #

  • Useable In
    Select Battle.

Target Selection Settings #

  • Target Type
    Select Ally.
  • Target Range
    Select Group.

Target Settings > Target Changes #

Click on Add Target Changes.

Click on Add Status Change.

  • Change Type
    Select Status Effect.
  • Change
    Select Add.
  • Status Effect
    Select the buff effect you want to use.

Passive Health Bonus #

A passive ability that gives status bonuses (increases maximum health) and immunity to poison status effect (i.e. the status effect can no longer be applied).

Ability Settings #

  • Useable In
    Select None.

Status Bonuses #

  • Custom Bonus
    Enable this setting.
    We’ll define a custom bonus here – you can also use a reusable Status Bonus templates.

Status Bonuses > Status Value Bonuses #

Click on Add Status Value Bonus.

  • Status Value
    Select Max HP (or whatever your maximum health status value is named).
  • Status Bonus
    Set to 50.
    Gives 50 more maximum health.
  • Percent Bonus
    Set to 10.
    Gives 10% more maximum health.

Status Effect Settings > Auto Status Effects #

Click on Add Status Effect Change.

  • Change
    Select Remove.
  • Status Effect
    Select poison effect (or whatever other effect you want to add immunity to).