From b5f8be8a95fa81b027019aa8b4414f29a2a92763 Mon Sep 17 00:00:00 2001 From: Steffen Mecke Date: Tue, 10 Feb 2015 18:16:39 +0100 Subject: [PATCH] fix heroes must not recruit --- res/core/messages.xml | 10 ++++++++++ src/economy.c | 4 ++++ 2 files changed, 14 insertions(+) diff --git a/res/core/messages.xml b/res/core/messages.xml index 16396b77c..f2ddb693b 100644 --- a/res/core/messages.xml +++ b/res/core/messages.xml @@ -8375,4 +8375,14 @@ orders for $int($turns) turns and may be leaving the game soon." + + + + + + + "$unit($unit) in $region($region): '$order($command)' - Helden können nicht rekrutieren." + "$unit($unit) in $region($region): '$order($command)' - Heroes cannot recruit." + + diff --git a/src/economy.c b/src/economy.c index 5eedbfa9c..fd548b1ae 100644 --- a/src/economy.c +++ b/src/economy.c @@ -564,6 +564,10 @@ static void recruit(unit * u, struct order *ord, request ** recruitorders) return; } + if (fval(u, UFL_HERO)) { + ADDMSG(&u->faction->msgs, msg_feedback(u, ord, "error_herorecruit", "")); + return; + } if (has_skill(u, SK_MAGIC)) { /* error158;de;{unit} in {region}: '{command}' - Magier arbeiten * grundsätzlich nur alleine! */