Appearance
Mirrors tracked repository source
docs/combat-engine-parity-vs-ot.md.
tibia-wave Combat Engine Parity vs OT Tibia
This document compares the current tibia-wave combat engine against the local OT references in this workspace:
otserver-forgottenserver-masteras the authoritative combat/server rules referenceotclient-mehah-mainas the client spell, cooldown, targeting, and combat-UI reference
Date of comparison: 2026-03-26.
Scope
This is a combat-engine comparison, not a full gameplay comparison.
Reviewed tibia-wave sources:
src/game/types.tssrc/game/engine/areas.tssrc/game/engine/rules.tssrc/game/engine/simulation.tsdocs/implemented-combat-spells.md
Reviewed OT server sources:
otserver-forgottenserver-master/src/spells.hotserver-forgottenserver-master/src/combat.hotserver-forgottenserver-master/src/combat.cppotserver-forgottenserver-master/src/condition.cppotserver-forgottenserver-master/data/scripts/spells/*
Reviewed OT client sources:
otclient-mehah-main/modules/gamelib/spells.luaotclient-mehah-main/modules/game_spelllist/spelllist.luaotclient-mehah-main/modules/game_cooldown/cooldown.luaotclient-mehah-main/src/client/localplayer.cppotclient-mehah-main/src/client/protocolgamesend.cpp
Executive Summary
tibia-wave is now much closer to OT Tibia on spell content than on total combat runtime behavior.
- Spell catalog parity for the current chosen scope is high.
tibia-wavecurrently implements 86 OT-derived combat spells, grouped as 49 attack, 21 healing, 4 party, and 12 support spells. - Spell effect parity is medium-high. Imported instant spells, cooldowns, spell groups, common area patterns, healing, buffs, dispels, invisibility, mana shield, challenge, and DOT-style effects are all represented.
- Full combat-engine parity is still medium at best.
tibia-waveremains an arena-based wave autobattler, not a full OT map combat runtime. - Overall estimate: about 50-60% parity with the full OT server + OTClient combat loop, but closer to 75-85% parity for the filtered instant-combat spell subset that
tibia-waveintentionally imported.
What Matches Well
1. Combat spell catalog structure
tibia-wave mirrors the OT spell grouping model reasonably well:
- OTClient exposes spell groups such as
Attack,Healing, andSupport. tibia-waveusesattack,healing,support, andspecial.- Each spell in
tibia-wavecarries level, mana, cooldown, group cooldown, vocation access, range, area metadata, and effect payloads.
For the subset currently in scope, this is the strongest area of parity.
2. Imported spell formulas and effect payloads
tibia-wave imports OT spell behavior into typed runtime data instead of manually hardcoding each effect.
What is already modeled:
- direct damage
- healing
- area attacks
- beams and waves
- damage-over-time effects
- dispels
- regeneration
- haste and paralyze-style speed effects
- invisibility
- mana shield
- attribute buffs
- challenge / taunt
- secondary spell-group exhaust
This is broadly aligned with what OT server spell scripts express through Combat, Condition, cooldown, groupCooldown, and area declarations.
3. Area pattern support
OT server area combat is built around matrix areas. tibia-wave also uses area matrices and supports the common beam/wave/circle/square patterns that matter for the imported spells.
That includes:
- beams
- front waves
- diagonal variants
- self-centered circles
- target-centered patterns
4. Cooldown model
The cooldown model matches the OT mental model well:
- spell-specific cooldowns
- primary spell-group cooldowns
- optional secondary-group cooldowns
This is consistent with OT server spell metadata and OTClient cooldown presentation.
5. Common combat conditions
OT server condition families that materially matter for the imported spell set are represented in tibia-wave:
- regeneration
- haste
- paralyze
- invisibility
- mana shield
- fire / poison / energy / curse / bleeding / dazzled DOTs
- attribute buffs
- pacify-like effects
This gives tibia-wave decent parity for the spell subset it actually runs.
6. Basic line-of-sight and obstacle awareness
tibia-wave does not have OT’s full tile/world engine, but it does model:
- direct line-of-sight checks for targetable spells
- obstacle-aware monster movement
- directional area orientation from caster-to-target geometry
That is enough for the imported spell set to feel OT-inspired instead of purely abstract.
Main Differences
1. World model is fundamentally different
This is the biggest difference.
OT combat is executed in a persistent tile world with:
- map floors
- projectile blockers
- teleports
- floor-change tiles
- protection / no-PvP / PvP zones
- creature occupancy rules
- attack/follow/fight mode state
tibia-wave instead runs combat in a fixed battlefield arena with:
- wave spawns
- generated obstacles
- server-side idle advancement
- simplified friend/enemy targeting
So even when the spell payload matches OT, the surrounding combat runtime does not.
2. Targeting is simplified to unit targets
OT server and OTClient both support a richer casting model:
- self-cast
- creature target
- ground position target
- direction-based casting
- target-or-direction hybrids
By contrast, tibia-wave currently only exposes:
selfallyenemy
Practical consequence:
- directional spells in
tibia-waveare oriented from caster to chosen target - they cannot be freely aimed into empty space
- ground-targeted spell placement is not implemented
This is one of the clearest parity gaps for beams, waves, and future rune support.
3. Area line-of-sight and tile legality are simplified
OT server filters area tiles through map legality and sight checks before resolving combat.
tibia-wave computes the area pattern and applies it to units occupying those tiles, but does not fully reproduce:
- per-tile area line-of-sight filtering
- map-floor and teleport restrictions
- projectile-blocking tile legality for each area tile
The result is that AoE spell shapes are present, but world interaction is less strict than OT.
4. Melee, distance, and defense formulas are custom
The base weapon combat layer in tibia-wave is OT-inspired, not OT-exact.
Notable differences:
tibia-waveuses its own weapon damage formula- distance hit chance is handled by a custom table
- armor and defense are simplified formulas
- attack and defense timing are reduced to the wave engine’s timing model
OT server instead resolves core weapon combat through its own weapon system and combat callbacks.
This means spell parity is better than auto-attack parity.
5. Damage randomness differs
OT server combat uses normal_random(...) for several damage rolls.
tibia-wave uses a deterministic uniform PRNG based on getRandomInt(...).
That changes:
- average feel of damage spread
- variance
- edge behavior on repeated casts and hits
6. Condition semantics are narrower than OT
tibia-wave implements the conditions needed for its imported combat set, but OT server supports a broader and more detailed condition system.
Examples OT has beyond tibia-wave’s current focus:
- field-driven tile damage
- more complete status families
- richer serialization/state handling
- more exact speed formulas and condition stacking rules
- broader special-skill and advanced attribute hooks
7. Mana Shield is simplified
OT server supports breakable mana shield state and related condition parameters.
tibia-wave models mana shield as a materialized breakable shield value. That is good enough for current spells, but it is not a full reproduction of all OT mana-shield behavior branches and edge rules.
8. DOT follow-up ticks are not fully source-faithful
There is still a known parity bug in tibia-wave:
- DOT conditions are created from the caster correctly
- later DOT ticks are applied without a live
sourceunit - because of that, follow-up ticks do not preserve all caster-side power scaling semantics
This is a real mismatch against OT server condition-driven damage behavior.
9. OT fight modes and protocol-driven combat state are absent
OTClient sends and exposes combat state such as:
- attack target
- follow target
- fight mode
- chase mode
- safe fight
- PvP mode
tibia-wave has no equivalent protocol/state layer for this. Its combat state is driven by:
- target strategy
- server-side simulation
- queued manual spell casts
- wave progression state
That is enough for the browser game, but it is not OT combat-state parity.
10. Client parity is partial, not full
OTClient includes:
- spell list UI
- spell filtering by vocation/group/premium
- cooldown bar UI
- server-driven spell availability updates
- attack/defense info presentation
tibia-wave only partially mirrors that experience. It has its own UI and state model and does not implement the same client protocol or interaction model.
What Is Currently Out of Scope or Missing
Combat content not brought over
The current tibia-wave combat import is not “all OT combat content”.
Still missing or intentionally excluded:
- conjuring combat runes
- field, wall, and bomb rune combat
- utility spells such as
exiva, light spells, rope, levitate, food, summon creature - many newer OTClient-only retail-era spell groups and high-level special systems outside the imported TFS subset
Combat engine features not implemented
- ground-position targeting
- free directional casting without a creature target
- full tile legality checks for area resolution
- magic fields as map hazards
- PvP and secure-mode combat restrictions
- protection-zone and no-PvP combat rules
- full attack/follow/fight-mode client model
- exact OT melee/ranged/defense runtime
Practical Reading of the Current State
If the question is:
“Does tibia-wave now feel like OT spell data running in combat?”
The answer is yes.
If the question is:
“Does tibia-wave now behave like a browser version of the full OT combat engine?”
The answer is no.
The current implementation is best described as:
OT-inspired combat runtime with OT-derived spell definitions, running inside a wave-based autobattler engine.
Parity Matrix
| Area | Parity | Notes |
|---|---|---|
| Imported instant combat spell catalog | High | Strong coverage for the chosen TFS subset |
| Spell metadata and cooldown groups | High | Level, mana, cooldown, group exhaust model matches well |
| Spell formulas and basic effect payloads | Medium-high | Good for direct damage, heals, buffs, dispels, common DOTs |
| Area pattern support | Medium-high | Beams, waves, circles, diagonals are present |
| Targeting semantics | Medium | Missing free direction and ground-position casting |
| Line-of-sight and obstacle interaction | Medium | Present, but simplified compared with OT tile checks |
| Base melee / ranged / defense combat | Medium-low | Uses custom formulas rather than OT core weapon runtime |
| Conditions system | Medium | Good subset coverage, but not full OT condition breadth |
| PvP / zone / secure mode rules | Low | Largely absent |
| OTClient interaction model | Low-medium | Cooldown/spell concepts match; protocol/UI behavior does not |
Bottom Line
tibia-wave is already strong enough to claim:
- OT-based spell definitions
- OT-like cooldown structure
- OT-like combat condition families
- OT-like beams, waves, and spell areas
It is not yet strong enough to claim:
- full OT combat-engine fidelity
- full OTClient combat interaction fidelity
- full OT world-combat rules
- full combat-rune and field-system support
If deeper OT parity is the goal, the highest-value next work items are:
- add ground-position and free-direction casting
- add rune / field / wall / bomb combat support
- tighten AoE tile legality and sight checks
- move melee/ranged/defense formulas closer to OT server behavior
- preserve caster attribution and scaling on DOT ticks