Skip to content

Commit

Permalink
Bei Bergwächtern fehlte ein noattack Flag.
Browse files Browse the repository at this point in the history
  • Loading branch information
ennorehling committed Mar 3, 2024
1 parent 76aae0f commit 0853b65
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 2 deletions.
2 changes: 1 addition & 1 deletion res/e3a/races.xml
Original file line number Diff line number Diff line change
Expand Up @@ -651,7 +651,7 @@
<skill name="stamina" modifier="-10"/>
<attack type="4" damage="1d2"/>
</race>
<race name="mountainguard" unarmedguard="yes" magres="50" weight="10000" capacity="2000" speed="0.0" hp="1000" ac="12" damage="2d40" unarmedattack="0" unarmeddefense="0" attackmodifier="6" defensemodifier="8" cannotmove="yes" nolearn="yes" teach="no" noweapons="yes">
<race name="mountainguard" unarmedguard="yes" magres="50" weight="10000" capacity="2000" speed="0.0" hp="1000" ac="12" damage="2d40" unarmedattack="0" unarmeddefense="0" attackmodifier="6" defensemodifier="8" cannotmove="yes" nolearn="yes" teach="no" noweapons="yes" noattack="yes">
<ai splitsize="1"/>
<attack type="4" damage="2d40"/>
</race>
Expand Down
2 changes: 1 addition & 1 deletion res/eressea/races.xml
Original file line number Diff line number Diff line change
Expand Up @@ -648,7 +648,7 @@
<skill name="stamina" modifier="-10"/>
<attack type="4" damage="1d2"/>
</race>
<race name="mountainguard" unarmedguard="yes" magres="50" maxaura="1.0" regaura="0.5" weight="10000" capacity="2000" speed="0.0" hp="1000" ac="12" damage="2d40" unarmedattack="0" unarmeddefense="0" attackmodifier="6" defensemodifier="8" cannotmove="yes" nolearn="yes" teach="no" noweapons="yes">
<race name="mountainguard" unarmedguard="yes" magres="50" maxaura="1.0" regaura="0.5" weight="10000" capacity="2000" speed="0.0" hp="1000" ac="12" damage="2d40" unarmedattack="0" unarmeddefense="0" attackmodifier="6" defensemodifier="8" cannotmove="yes" nolearn="yes" teach="no" noweapons="yes" noattack="yes">
<ai splitsize="1"/>
<attack type="4" damage="2d40"/>
</race>
Expand Down
10 changes: 10 additions & 0 deletions scripts/tests/shared/spells.lua
Original file line number Diff line number Diff line change
Expand Up @@ -183,3 +183,13 @@ function test_confusion_and_panic()
end
process_orders()
end

function test_mountainguards_cant_attack()
local r = region.create(0, 0, 'plain')
local u = unit.create(faction.create('human'), r, 1)
local f = faction.create('human')
local ug = unit.create(f, r, 1, "mountainguard")
ug:add_order("ATTACKIERE " .. itoa36(u.id))
process_orders()
assert_equal('race_no_attack', f.messages[1])
end

0 comments on commit 0853b65

Please sign in to comment.