feat(spells): allow spells to ignore spell resistance

SpellSpec gains spell_resistance: bool = True (JSON 'spell_resistance'). When false, _spell_delivery_blocked skips the targeted SR check and _apply_area_effect skips the per-creature SR check (threaded through the effect chain). Verified each imported spell against the local KB and set false on the 28 whose SRD block says 'Spell Resistance: no' (Acid Arrow, Flurry of Snowballs, Web, Darkness, Sanctuary, the Protection from X spells, etc.). Added no-SR targeted/area tests and a high-SR control in test_spell_resistance.py, and the README.

Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
This commit is contained in:
2026-09-13 12:44:35 +02:00
parent c96b36d3f9
commit 9768f5ae1d
32 changed files with 142 additions and 9 deletions
+1
View File
@@ -6,6 +6,7 @@
"save": "none",
"base_dc": 10,
"cast_time": "standard",
"spell_resistance": false,
"effects": [],
"description": "A cantrip that conjures duplicate ammunition: attacks with the affected ammunition do not expend it. No combat-mechanical effect in the engine (ammunition is not tracked)."
}
+1
View File
@@ -7,6 +7,7 @@
"base_dc": 10,
"requires_ranged_touch": true,
"cast_time": "standard",
"spell_resistance": false,
"effects": [
{
"type": "damage",
+1
View File
@@ -7,6 +7,7 @@
"base_dc": 10,
"requires_ranged_touch": true,
"cast_time": "standard",
"spell_resistance": false,
"effects": [
{
"type": "damage",
+1
View File
@@ -6,6 +6,7 @@
"save": "none",
"base_dc": 10,
"cast_time": "standard",
"spell_resistance": false,
"effects": [],
"description": "Wards a area (20-ft radius, 20 ft high) against intrusion for 2 hours/level, alerting you mentally. No combat-mechanical effect in the engine."
}
+1
View File
@@ -6,6 +6,7 @@
"save": "none",
"base_dc": 10,
"cast_time": "standard",
"spell_resistance": false,
"effects": [],
"description": "Creates a permanent visible inscribed mark of your choosing on an object or surface, optionally invisible and keyed to you. Utility cantrip, no combat effect."
}
+1
View File
@@ -6,6 +6,7 @@
"save": "none",
"base_dc": 10,
"cast_time": "standard",
"spell_resistance": false,
"effects": [],
"description": "Conjures 4 gallons of clean water per level in an open space or container. Utility spell, no combat effect."
}
+1
View File
@@ -6,6 +6,7 @@
"save": "none",
"base_dc": 10,
"cast_time": "standard",
"spell_resistance": false,
"effects": [],
"description": "A cantrip that creates up to four flickering torch-like lights you move as desired (concentration, 1 min/level). Utility spell, no combat effect."
}
+1
View File
@@ -6,6 +6,7 @@
"save": "none",
"base_dc": 10,
"cast_time": "standard",
"spell_resistance": false,
"effects": [
{
"type": "area",
@@ -6,6 +6,7 @@
"save": "none",
"base_dc": 10,
"cast_time": "standard",
"spell_resistance": false,
"effects": [],
"description": "A cantrip that reveals whether a creature of the outsider (evil) subtype has been in the area within 10 minutes/HD, and hints at its nature. Utility spell, no combat effect."
}
+1
View File
@@ -6,6 +6,7 @@
"save": "none",
"base_dc": 10,
"cast_time": "standard",
"spell_resistance": false,
"effects": [],
"description": "A cantrip that detects magical auras in a 60-ft cone (2 rounds to identify strength and school). Utility spell, no combat effect."
}
+1
View File
@@ -6,6 +6,7 @@
"save": "none",
"base_dc": 10,
"cast_time": "standard",
"spell_resistance": false,
"effects": [],
"description": "A cantrip that determines whether a creature, object, or area is poisoned, venomous, or afflicted by acid. Utility spell, no combat effect."
}
+1
View File
@@ -6,6 +6,7 @@
"save": "none",
"base_dc": 10,
"cast_time": "standard",
"spell_resistance": false,
"effects": [],
"description": "For 1 hour/level you gain DR 5/- against alcohol effects and cannot become drunk. The engine has no DR buff target, so no mechanical effect is applied."
}
+1
View File
@@ -6,6 +6,7 @@
"save": "ref",
"base_dc": 10,
"cast_time": "standard",
"spell_resistance": false,
"effects": [
{
"type": "area",
+1
View File
@@ -6,6 +6,7 @@
"save": "none",
"base_dc": 10,
"cast_time": "immediate",
"spell_resistance": false,
"effects": [],
"description": "A cantrip cast as an immediate action when you fail a Climb check and would fall: you immediately retry the Climb check at a -2 penalty (increasing by 2 per successive use in the same situation); on success you don't fall. Climbing is not modeled by the engine, so the spell has no mechanical effects here."
}
+1
View File
@@ -6,6 +6,7 @@
"save": "none",
"base_dc": 10,
"cast_time": "standard",
"spell_resistance": false,
"effects": [],
"description": "A cantrip: a touched object glows like a torch, shedding normal light in a 20-foot radius (plus dim light for 20 more feet) for 10 min/level. No combat effect; illumination is not modeled by the engine."
}
+1
View File
@@ -6,6 +6,7 @@
"save": "none",
"base_dc": 10,
"cast_time": "standard",
"spell_resistance": false,
"effects": [],
"description": "A cantrip: a spectral hand lifts and moves one unattended nonmagical object weighing up to 5 lb. from up to 25 ft. away, as far as 15 feet per move action while you concentrate. No combat effect; object manipulation is not modeled by the engine."
}
@@ -6,6 +6,7 @@
"save": "none",
"base_dc": 10,
"cast_time": "long",
"spell_resistance": false,
"effects": [],
"description": "After 1 hour of casting (plus masterwork-priced reagents), a non-masterwork weapon, armor, shield, tool, or skill kit becomes its masterwork equivalent. Item crafting is outside the engine's combat model, so the spell has no mechanical effects here."
}
+1
View File
@@ -6,6 +6,7 @@
"save": "none",
"base_dc": 10,
"cast_time": "standard",
"spell_resistance": false,
"effects": [],
"description": "A cantrip: you whisper messages and receive replies with targeted creatures within range for 10 min/level; bystanders hear nothing without a DC 25 Perception check. Communication is not modeled by the engine, so the spell has no mechanical effects here."
}
+1
View File
@@ -6,6 +6,7 @@
"save": "none",
"base_dc": 10,
"cast_time": "standard",
"spell_resistance": false,
"effects": [
{
"type": "area",
+1
View File
@@ -6,6 +6,7 @@
"save": "none",
"base_dc": 10,
"cast_time": "standard",
"spell_resistance": false,
"effects": [],
"description": "A cantrip: minor magical tricks for 1 hour - lift 1 lb. of material, color/clean/soil items in a 1-ft cube, chill/warm/flavor 1 lb. of nonliving material, or create crude trinkets. It can deal no damage and duplicates no other spell. No combat effect; the trivial manipulations are not modeled by the engine."
}
+1
View File
@@ -6,6 +6,7 @@
"save": "will",
"base_dc": 10,
"cast_time": "standard",
"spell_resistance": false,
"effects": [],
"description": "A barrier wards the subject from evil for 1 min/level: +2 deflection bonus to AC and +2 resistance bonus on saves against attacks and effects created by evil creatures, renewed saves and suppression of mental control, and lawful summoned evil creatures cannot touch it. Will negates (harmless). The engine has no alignment system, so alignment-restricted bonuses cannot be modeled and the spell has no mechanical effects here."
}
@@ -6,6 +6,7 @@
"save": "will",
"base_dc": 10,
"cast_time": "standard",
"spell_resistance": false,
"effects": [],
"description": "Functions like protection from evil (+2 deflection to AC and +2 resistance on saves vs evil creatures, protection from mental control), except the 1 min/level duration is divided in 1-minute intervals among the touched creatures. Will negates (harmless). Alignment-restricted bonuses and duration-sharing are not modeled, so the spell has no mechanical effects here."
}
+1
View File
@@ -6,6 +6,7 @@
"save": "will",
"base_dc": 10,
"cast_time": "standard",
"spell_resistance": false,
"effects": [],
"description": "A barrier wards the subject from lawful creatures for 1 min/level: +2 deflection bonus to AC and +2 resistance bonus on saves against attacks and effects created by lawful creatures, plus renewed saves against mental control by lawful creatures. Will negates (harmless). The engine has no alignment system, so alignment-restricted bonuses cannot be modeled and the spell has no mechanical effects here."
}
@@ -6,6 +6,7 @@
"save": "will",
"base_dc": 10,
"cast_time": "standard",
"spell_resistance": false,
"effects": [],
"description": "Functions like protection from law (+2 deflection to AC and +2 resistance on saves vs lawful creatures, protection from mental control), except the 1 min/level duration is divided in 1-minute intervals among the touched creatures. Will negates (harmless). Alignment-restricted bonuses and duration-sharing are not modeled, so the spell has no mechanical effects here."
}
+1
View File
@@ -6,6 +6,7 @@
"save": "will",
"base_dc": 10,
"cast_time": "standard",
"spell_resistance": false,
"effects": [],
"description": "You ward a creature against attacks for 1 round/level: any opponent attempting to directly attack the warded creature must succeed on a Will save or be unable to follow through with that attack and cannot directly attack the subject for the duration. The subject cannot attack without ending the spell. Will negates. No combat effect encoded: the engine has no attack-refusal-by-save mechanic, so the protection cannot be represented."
}
+1
View File
@@ -6,6 +6,7 @@
"save": "none",
"base_dc": 10,
"cast_time": "one_round",
"spell_resistance": false,
"effects": [],
"description": "A cantrip (casting time 1 round): you summon one handheld musical instrument of your choice into your hands or at your feet; it plays only for you and disappears when the spell ends (1 min./level). No combat effect: summoned objects are not modeled by the engine."
}
+1
View File
@@ -6,6 +6,7 @@
"save": "none",
"base_dc": 10,
"cast_time": "standard",
"spell_resistance": false,
"effects": [],
"description": "An invisible, mindless, shapeless force performs simple tasks at your command for 1 hour/level: fetching, opening unstuck doors, holding chairs, cleaning or mending (effective Strength 2, speed 15 ft., no attacks, DC 10 skill limit). No combat effect: object manipulation by invisible servants is not modeled by the engine."
}
+1
View File
@@ -6,6 +6,7 @@
"save": "ref",
"base_dc": 10,
"cast_time": "standard",
"spell_resistance": false,
"effects": [
{
"type": "area",