Documentation / Tile Tick Core RPG

Prayer and Run Energy

Prayer and run energy are separate systems, but both plug into the same skills, modifiers, UI, and tick based gameplay flow.

Prayer

PrayerDefinition assets control the level requirement, drain rate, category, conflicts, overhead icon, sounds, effects, and gameplay modifiers for each prayer.

Basic setup

  1. Open the Prayer Database window.
  2. Create a prayer and assign its icon and level requirement.
  3. Choose a drain rate per tick.
  4. Add any modifier definitions the prayer should apply.
  5. Use an activation group when only one prayer in a group can stay active.
  6. Assign an overhead sprite when the prayer needs an icon above the unit.

Protection prayers

Melee, ranged, and magic protection prayers should share an activation group. This lets activating one protection prayer turn off the other protection prayers without hard coding those three assets into the runtime.

Run energy

RunEnergyController tracks current energy, maximum energy, whether running is enabled, and whether regeneration is active. It also sends events that the HUD can use without constantly polling values.

Energy use and recovery

  • Running drains energy through the movement flow.
  • Running turns off when there is not enough energy left.
  • Regeneration waits for the configured delay.
  • RunEnergyRegen can scale recovery using the Agility level.
  • RunEnergySettings keeps the balance values in one reusable asset.

UI

The HUD widgets display prayer points and run energy, while the run control can toggle running and react to depletion. Keep the UI subscribed to controller events so it always matches the real gameplay state.