Skip to content

Game Design Principles

Kit Oliynyk edited this page Nov 2, 2026 · 1 revision

TL;DR: Balance is a triangle of slight edges, never hard counters. Item power has one ruler, M, and every new stat source is priced on it. Spell prices come from one table. Luck helps but never guarantees. Material numbers describe physics, not damage. Use when: you change damage, saves, armor, instant kills, gear, rewards or spell prices, and need to know which rule your change must respect. Source of truth: dreamland_code/plug-ins/profession/profflags.conf, dreamland_code/plug-ins/fight/fight.cpp (damapply_class), dreamland_world/fight/spell_value.json, dreamland_world/fight/item_value.json, dreamland_world/fight/material.json, dreamland_fenia_public/utils/chance Verified: 2026-11-02 against dreamland_code 88da8302, dreamland_world 43880467, dreamland_fenia_public c28874b

The triangle

Every profession carries an archetype flag, set in its file under dreamland_world/professions/:

Flag Professions
melee warrior, ranger, samurai
agile ninja, thief
hybrid paladin, anti-paladin, vampire
caster cleric, druid, necromancer, warlock, witch

The balance rule is a cycle of slight edges:

  • Agile has a slight edge over casters.
  • Casters have a slight edge over melee.
  • Melee has a slight edge over agile.

The edges are slight. No archetype counters another archetype outright, and no matchup should be decided before the fight starts. The engine already tilts the numbers by archetype. Melee gets the most weapon damage and the lowest spell level, casters the reverse, with agile and hybrid between (comment in profflags.conf). damapply_class in fight.cpp adds the damage bonus by archetype.

Every balance change gets a triangle check before it ships. That covers saving throws, instant kills, armor class, damage, and the pricing of gear. Ask who gains and who loses, then check that no edge became a counter.

One ruler for item power

Item power is measured in one unit, M. Random loot, crafted gear, quest rewards, gear made by spells, enchants and the gear advisor all use it. The rules:

  • A new source of item stats gets a budget in M and reuses an existing generator, base table or budget function. It never gets a flat per-tier bonus, because a flat bonus shrinks in value as the item level grows.
  • The numbers live in JSON files under dreamland_world/fight/, not in scripts.
  • Fenia has no floating point numbers, so budgets are whole numbers in hundredths of M.

Definitions, files, tier windows and the full rule list are on Item-Power. Do not copy them here.

Spell prices

A spell on an item, a charge, a grant, a proc or a reward is priced from fight/spell_value.json. The table gives, per spell and per skill, three prices in M at level 50:

Price Meaning
worn The spell as a permanent affect on worn gear
charge One use, such as a pill, potion, scroll or wand charge
grant A skill an item grants

Never price a spell from its level, its name or by feel. The table also records spells that must stay off magic items, and it weighs player-versus-player use, so spell resistance and similar effects are priced for it.

Luck helps, never decides

Rolls where a character's luck matters (skill success, dodge, parry, traps) go through .tmp.chance(base, ch) from the public Fenia library. It adds race, religion and calendar bonuses, then clamps the final chance between 1 and 99 percent. There is always a chance, and nothing is certain. For a bad event, roll the avoidance, so luck helps the character stay safe. Code details: Code-Style.

A mechanic that needs a true 100 percent or 0 percent outcome must say so on purpose and bypass the helper.

Materials describe physics

fight/material.json lists every material with density, hardness and a burns number. The file header explains the scale: hardness is roughly Mohs from -1 (indestructible) to 10, and burns reads as how easily the material catches fire and how long it burns, about 100 to 150 degrees Celsius per point.

burns Meaning
-1 Puts fire out (water)
0 Does not burn
1 to 3 Lights like a candle or matchstick fire: straw, paper, silk, cotton, linen
4 to 5 Needs torch-level heat: leather, felt, wool
6 and up Burning hands and dragonfire (maintainer scale, only hard leather is at 6 today)

The number is not a damage multiplier. It tunes how hot the ignition source must be and how long the thing burns. A script that handles open fire reads it as obj.material.burns and takes at least 1 as fire power.

Wool and felt sit at 5 and 4 on purpose. Wool is hard to ignite and burns out, unlike cotton and linen at 2. Do not raise them to match.

Other standing rules

  • Tunables live in data files. Change the data, then reload it, rather than edit constants in scripts. See Data-Configs.
  • Mobs get their numbers from level and tier, not from hand-set dice. See OLC-Mobiles.
  • Every visual added to the game needs a text twin for screen readers. See Accessibility.
  • Text players read follows Writing-Player-Text.

See also

Clone this wiki locally