From 004d6c61d4704bc8cb80fb92fd578344612f9122 Mon Sep 17 00:00:00 2001 From: Enno Rehling Date: Sat, 4 Jul 2015 23:42:41 +0200 Subject: [PATCH 1/2] avoid monsters: only seed new factions in hexes that have no units nearby. --- scripts/populate.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/populate.lua b/scripts/populate.lua index dfd07b5dd..5df2ad92f 100644 --- a/scripts/populate.lua +++ b/scripts/populate.lua @@ -6,7 +6,7 @@ local function score(r, res) local x, y, rn local peas = r:get_resource(res) for _, rn in pairs(r.adj) do - if rn then + if rn and not rn.units() then peas = peas + rn:get_resource(res) end end @@ -16,7 +16,7 @@ end local function select(regions, limit) local sel = {} for r in regions do - if r.terrain~="ocean" and r.units()==nil then + if r.terrain~="ocean" and not r.units() then s = score(r) if s >= limit then table.insert(sel, r) From 960e0f8024a39b3f1b59b8194d6407ae587b42f3 Mon Sep 17 00:00:00 2001 From: Enno Rehling Date: Mon, 6 Jul 2015 16:13:22 +0200 Subject: [PATCH 2/2] do not show magic resistance effects to other than the unit's own faction. https://bugs.eressea.de/view.php?id=1692 --- res/core/messages.xml | 1 + src/spells/unitcurse.c | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/res/core/messages.xml b/res/core/messages.xml index 0afc458c2..1f8baae33 100644 --- a/res/core/messages.xml +++ b/res/core/messages.xml @@ -392,6 +392,7 @@ + "Die natürliche Widerstandskraft gegen Verzauberung ist gestärkt. ($int36($id))" diff --git a/src/spells/unitcurse.c b/src/spells/unitcurse.c index bd332ebf5..80ebe56bb 100644 --- a/src/spells/unitcurse.c +++ b/src/spells/unitcurse.c @@ -302,7 +302,7 @@ static struct curse_type ct_oldrace = { }; static struct curse_type ct_magicresistance = { - "magicresistance", CURSETYP_UNIT, CURSE_SPREADMODULO, M_MEN, cinfo_simple + "magicresistance", CURSETYP_UNIT, CURSE_SPREADMODULO, M_MEN, cinfo_unit }; /* ------------------------------------------------------------- */