torre-math-engine

Implement deterministic combat math formulas for TORRE engine simulation.

Updated Feb 25, 2026
One-click install
npx skills add https://github.com/lfggarcia/dnd-app --skill torre-math-engine
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: torre-math-engine
Source: https://github.com/lfggarcia/dnd-app/tree/main/.github/skills/torre-math-engine
Command: npx skills add https://github.com/lfggarcia/dnd-app --skill torre-math-engine

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

TORRE relies on exact, deterministic formulas for combat math and AI-driven simulation to ensure consistent balancing and reproducibility across seeds, floors, and configurations.

Core Features & Use Cases

  • Exact formulas for hit chance, damage, initiative, XP, scaling, and bounty logic.
  • Deterministic engine templates to verify balance and reproduce results from seed data.
  • Use Case: implement or validate a combat loop to reproduce identical outcomes given the same seed.

Quick Start

Implement the exact math formulas in your combat engine using a seed-based deterministic approach to reproduce consistent outcomes.

Frequently Asked Questions about torre-math-engine

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I implement deterministic combat math and simulation formulas in a game engine?

Deterministic combat math applies seed-based randomness, clamping, and exact formulas for hit chance, damage, and initiative to reproduce identical outcomes. You implement these modular functions within your combat loop to verify balancing across different seeds and party configurations.

What is seed-based randomness used for in combat balancing and formula verification?

Seed-based randomness ensures simulation reproducibility by generating identical combat results from the same input data. It allows developers to verify engine balancing, test scaling logic, and validate AI decision making across multiple floor configurations consistently.

How do I validate combat engine balancing for hit chance, damage, and XP scaling?

You validate combat engine balancing by applying deterministic formulas for hit chance, damage, initiative, and XP scaling within a simulation. Using seed data and modular functions, you reproduce exact outcomes to verify formula correctness across party configurations.

Can I reproduce identical combat simulation outcomes across different party configurations?

Yes, you can reproduce identical combat simulation outcomes by using deterministic inputs and seed-based randomness. Applying exact math formulas for initiative, damage, and bounty logic ensures consistent results regardless of party configuration or floor progression.

Does this deterministic math engine support AI decision making and initiative calculations?

Yes, the deterministic math engine provides modular functions for AI decision making and initiative calculations. It applies exact formulas with seed-based randomness and clamping to ensure combat outcomes remain reproducible across different simulation runs and engine states.

What are the limitations of using deterministic formulas for combat simulation?

Deterministic combat formulas require exact seed data and strict clamping to maintain reproducibility. Any deviation in input seeds or party configurations breaks outcome consistency, meaning simulations cannot produce varied results without explicitly changing the underlying seed values.