From 61ebd1d6b79e1b89d42fe00d28d9730c7d6ebe8b Mon Sep 17 00:00:00 2001 From: Enno Rehling Date: Thu, 14 Aug 2014 20:08:29 +0200 Subject: [PATCH] fix accidental assignment instead of comparison. --- src/kernel/move.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/kernel/move.c b/src/kernel/move.c index 39504d901..9fc20afbe 100644 --- a/src/kernel/move.c +++ b/src/kernel/move.c @@ -892,15 +892,15 @@ static unit *bewegung_blockiert_von(unit * reisender, region * r) if (guard) { prob += base_prob; /* 30% base chance */ prob = +guard_count*guard_number_prob; - if (r->terrain = newterrain(T_GLACIER)) + if (r->terrain == newterrain(T_GLACIER)) prob = +region_type_prob*2; - if (r->terrain = newterrain(T_SWAMP)) + if (r->terrain == newterrain(T_SWAMP)) prob = +region_type_prob*2; - if (r->terrain = newterrain(T_MOUNTAIN)) + if (r->terrain == newterrain(T_MOUNTAIN)) prob = +region_type_prob; - if (r->terrain = newterrain(T_VOLCANO)) + if (r->terrain == newterrain(T_VOLCANO)) prob = +region_type_prob; - if (r->terrain = newterrain(T_VOLCANO_SMOKING)) + if (r->terrain == newterrain(T_VOLCANO_SMOKING)) prob = +region_type_prob; if (prob > 0 && chance(prob)) {