diff --git a/src/common/gamecode/economy.c b/src/common/gamecode/economy.c
index 7a11bd998..43bfefd9b 100644
--- a/src/common/gamecode/economy.c
+++ b/src/common/gamecode/economy.c
@@ -1110,7 +1110,8 @@ recruit_archetype(unit * u, order * ord)
if (a==NULL) a = a_add(&u->building->attribs, a_new(&at_recruit));
a->data.i += n*arch->size;
}
- ADDMSG(&u->faction->msgs, msg_message("recruit_archetype", "unit archetype", u, arch->name));
+ ADDMSG(&u->faction->msgs, msg_message("recruit_archetype",
+ "unit amount archetype", u, n, arch->name));
return n;
} else switch(n) {
case ENOMATERIALS:
diff --git a/src/common/gamecode/report.c b/src/common/gamecode/report.c
index fbf7ca10d..acad89a5c 100644
--- a/src/common/gamecode/report.c
+++ b/src/common/gamecode/report.c
@@ -757,7 +757,7 @@ static void
eval_trail(struct opstack ** stack, const void * userdata) /* (int, int) -> int */
{
const struct faction * f = (const struct faction *)userdata;
- const struct locale * lang = (const struct locale*)opop(stack).v;
+ const struct locale * lang = f?f->locale:default_locale;
const struct region * r = (const struct region*)opop(stack).v;
const char * trail = trailinto(r, lang);
const char * rn = f_regionid_s(r, f);
diff --git a/src/common/util/translation.c b/src/common/util/translation.c
index 72654ca7f..ebcf2ede8 100644
--- a/src/common/util/translation.c
+++ b/src/common/util/translation.c
@@ -454,20 +454,11 @@ eval_int(opstack ** stack, const void * userdata)
static void
eval_localize(opstack ** stack, const void * userdata) /* (string, locale) -> string */
{
- const struct locale *lang = (const struct locale *)opop_v(stack);
+ const struct faction * f = (const struct faction *)userdata;
+ const struct locale *lang = f?f->locale:default_locale;
const char *c = (const char *)opop_v(stack);
c = locale_string(lang, c);
opush_v(stack, strcpy(balloc(strlen(c)+1), c));
- unused(userdata);
-}
-
-static void
-eval_locale(opstack ** stack, const void * userdata) /* (string) -> locale */
-{
- const char *c = (const char *)opop_v(stack);
- struct locale * lang = find_locale(c);
- opush_v(stack, lang);
- unused(userdata);
}
void
@@ -481,7 +472,6 @@ translation_init(void)
add_function("if", &eval_if);
add_function("isnull", &eval_isnull);
add_function("localize", &eval_localize);
- add_function("locale", &eval_locale);
}
void
diff --git a/src/res/messages.xml b/src/res/messages.xml
index a2d26f207..721a57f1e 100644
--- a/src/res/messages.xml
+++ b/src/res/messages.xml
@@ -714,9 +714,8 @@
- $trail($region,$locale("de"))
- $trail($region,$locale("en"))
- $trail($region,$locale("en"))
+ $trail($region)
+ $trail($region)
@@ -814,9 +813,8 @@
- "Im $direction($dir) der Region liegt $trail($region,$locale("de"))"
- "To the $direction($dir) lies $trail($region,$locale("en"))"
- "To the $direction($dir) lies $trail($region,$locale("en"))"
+ "Im $direction($dir) der Region liegt $trail($region)"
+ "To the $direction($dir) lies $trail($region)"
@@ -2704,8 +2702,8 @@
- "$unit($unit) in $region($region) stellt fest, dass es hier $localize($amount,$locale("de")) $resource($herb,$amount) gibt."
- "$unit($unit) discovers that $localize($amount,$locale("en")) $resource($herb,$amount) grow in $region($region)."
+ "$unit($unit) in $region($region) stellt fest, dass es hier $localize($amount) $resource($herb,0) gibt."
+ "$unit($unit) discovers that $localize($amount) $resource($herb,0) grow in $region($region)."
@@ -7266,4 +7264,14 @@
"A message from $unit($unit): '$message'"
+
+
+
+
+
+
+ "$unit($unit) rekrutiert $int($amount) $localize($archetype)."
+ "$unit($unit) recruits $int($amount) $localize($archetype)."
+
+