No active sessions yet.

No games yet.

No conversations yet.

No characters yet.

Seams

The one thing a plugin can replace rather than add to.

Everything else a plugin declares adds. A seam replaces an engine calculation.

Only one plugin can own a seam. Two plugins both rewriting damage would have no defined result, so the engine doesn't allow it.

The seams

Seam Replaces
variance damage spread
armor what a target subtracts
damageFormula turning the parts of a blow into a number
damageTaken what a blow costs the one taking it, after armor
weaponAttack the whole swing
levelUpAward what a level grants
enemyXpValue what a kill is worth
simulateNpc which NPCs the world thinks about while nobody's watching
simulationPriority which of those go first when there isn't room for all

They stack

Replacing damageFormula leaves variance and armor in place; your formula can use them or not. weaponAttack exists for games where an attack isn't a roll against a defense at all, like damage decided by matching card suits.

Big worlds: simulateNpc

By default the engine considers every NPC every turn. Fine for a village, wasteful for a continent. Narrow it:

$.stat('hopsFromParty') <= 2

That's distance from the party on the map as it is right now. -1 means no route, which fails every <= test.

Don't write a rule that's true forever. An NPC who's never simulated never finishes anything, so add a floor:

$.stat('hopsFromParty') <= 2 || $.stat('turnsSinceSimulated') > 10

simulationPriority then ranks whoever is left when the turn can't fit everyone.

When to use one

Use a seam when the engine's calculation is wrong for your game, not when it needs tuning. Tougher characters? Edit the maxHp formula. Damage from playing cards? Replace weaponAttack.

If a dial or formula can say it, use that. A seam locks every other plugin out.