forked from github/server
commit
7c5427d4cc
|
@ -4,7 +4,6 @@
|
||||||
<xi:include href="config://core/de/strings.xml"/>
|
<xi:include href="config://core/de/strings.xml"/>
|
||||||
<xi:include href="config://core/en/strings.xml"/>
|
<xi:include href="config://core/en/strings.xml"/>
|
||||||
<xi:include href="config://game/strings.xml"/>
|
<xi:include href="config://game/strings.xml"/>
|
||||||
<xi:include href="config://game/messages.xml"/>
|
|
||||||
<xi:include href="config://default/names-undead.xml"/>
|
<xi:include href="config://default/names-undead.xml"/>
|
||||||
<xi:include href="config://default/names-skeletons.xml"/>
|
<xi:include href="config://default/names-skeletons.xml"/>
|
||||||
<xi:include href="config://default/names-zombies.xml"/>
|
<xi:include href="config://default/names-zombies.xml"/>
|
||||||
|
|
|
@ -2033,6 +2033,13 @@
|
||||||
<text locale="de">$if($isnull($mage),"Ein unentdeckter Magier",$unit($mage)) erschuf einen heiligen Hain von $int($amount) Schößlingen.</text>
|
<text locale="de">$if($isnull($mage),"Ein unentdeckter Magier",$unit($mage)) erschuf einen heiligen Hain von $int($amount) Schößlingen.</text>
|
||||||
<text locale="en">$if($isnull($mage),"An unknown magician",$unit($mage)) created a holy forest of $int($amount) young trees.</text>
|
<text locale="en">$if($isnull($mage),"An unknown magician",$unit($mage)) created a holy forest of $int($amount) young trees.</text>
|
||||||
</message>
|
</message>
|
||||||
|
<message name="raindance_effect" section="magic">
|
||||||
|
<type>
|
||||||
|
<arg name="mage" type="unit"/>
|
||||||
|
</type>
|
||||||
|
<text locale="de">"$if($isnull($mage),"Ein unentdeckter Magier",$unit($mage)) führt einen sonderbaren Tanz auf. Kurz darauf beginnt es zu regnen."</text>
|
||||||
|
<text locale="en">"$if($isnull($mage),"an unseen magician",$unit($mage)) dances a strange dance. Shortly after, rain begins to fall on the fields."</text>
|
||||||
|
</message>
|
||||||
<message name="harvest_effect" section="magic">
|
<message name="harvest_effect" section="magic">
|
||||||
<type>
|
<type>
|
||||||
<arg name="mage" type="unit"/>
|
<arg name="mage" type="unit"/>
|
||||||
|
|
|
@ -1,10 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<messages>
|
|
||||||
<message name="raindance_effect" section="magic">
|
|
||||||
<type>
|
|
||||||
<arg name="mage" type="unit"/>
|
|
||||||
</type>
|
|
||||||
<text locale="de">"$if($isnull($mage),"Ein unentdeckter Magier",$unit($mage)) führt einen sonderbaren Tanz auf. Kurz darauf beginnt es zu regnen."</text>
|
|
||||||
<text locale="en">"$if($isnull($mage),"an unseen magician",$unit($mage)) dances a strange dance. Shortly after, rain begins to fall on the fields."</text>
|
|
||||||
</message>
|
|
||||||
</messages>
|
|
|
@ -142,8 +142,9 @@ function process(rules, orders)
|
||||||
return -1
|
return -1
|
||||||
end
|
end
|
||||||
|
|
||||||
callbacks(rules, 'init')
|
turn_begin()
|
||||||
init_summary()
|
init_summary()
|
||||||
|
callbacks(rules, 'init')
|
||||||
|
|
||||||
-- run the turn:
|
-- run the turn:
|
||||||
if eressea.read_orders(orders) ~= 0 then
|
if eressea.read_orders(orders) ~= 0 then
|
||||||
|
@ -157,12 +158,13 @@ function process(rules, orders)
|
||||||
return -1
|
return -1
|
||||||
end
|
end
|
||||||
|
|
||||||
process_orders()
|
|
||||||
callbacks(rules, 'update')
|
callbacks(rules, 'update')
|
||||||
|
turn_process()
|
||||||
|
|
||||||
write_files(config.locales)
|
write_files(config.locales)
|
||||||
dbupdate()
|
dbupdate()
|
||||||
|
|
||||||
|
turn_end()
|
||||||
file = '' .. get_turn() .. '.dat'
|
file = '' .. get_turn() .. '.dat'
|
||||||
if eressea.write_game(file)~=0 then
|
if eressea.write_game(file)~=0 then
|
||||||
eressea.log.error("could not write game")
|
eressea.log.error("could not write game")
|
||||||
|
|
|
@ -869,6 +869,7 @@ const char * game_mailcmd(void)
|
||||||
}
|
}
|
||||||
*r = '\0';
|
*r = '\0';
|
||||||
log_warning("game.mailcmd configuration is not set, using %s from game.name", result);
|
log_warning("game.mailcmd configuration is not set, using %s from game.name", result);
|
||||||
|
config_set("game.mailcmd", result);
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
return param;
|
return param;
|
||||||
|
|
|
@ -278,6 +278,7 @@ static void test_game_mailcmd(CuTest *tc) {
|
||||||
CuAssertStrEquals(tc, "Eressea", game_name());
|
CuAssertStrEquals(tc, "Eressea", game_name());
|
||||||
CuAssertStrEquals(tc, "ERESSEA", game_mailcmd());
|
CuAssertStrEquals(tc, "ERESSEA", game_mailcmd());
|
||||||
config_set("game.name", "Hodor");
|
config_set("game.name", "Hodor");
|
||||||
|
config_set("game.mailcmd", NULL);
|
||||||
CuAssertStrEquals(tc, "Hodor", game_name());
|
CuAssertStrEquals(tc, "Hodor", game_name());
|
||||||
CuAssertStrEquals(tc, "HODOR", game_mailcmd());
|
CuAssertStrEquals(tc, "HODOR", game_mailcmd());
|
||||||
config_set("game.mailcmd", "ERESSEA");
|
config_set("game.mailcmd", "ERESSEA");
|
||||||
|
|
|
@ -241,10 +241,7 @@ static faction *factionorders(void)
|
||||||
}
|
}
|
||||||
/* Die Partei hat sich zumindest gemeldet, so dass sie noch
|
/* Die Partei hat sich zumindest gemeldet, so dass sie noch
|
||||||
* nicht als untätig gilt */
|
* nicht als untätig gilt */
|
||||||
|
f->lastorders = turn;
|
||||||
/* TODO: +1 ist ein Workaround, weil cturn erst in process_orders
|
|
||||||
* incrementiert wird. */
|
|
||||||
f->lastorders = turn + 1;
|
|
||||||
|
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
|
|
@ -3014,7 +3014,7 @@ int cast_spell(struct castorder *co)
|
||||||
|
|
||||||
fun = get_spellcast(sp->sname);
|
fun = get_spellcast(sp->sname);
|
||||||
if (!fun) {
|
if (!fun) {
|
||||||
log_warning("no spell function for %s, try callback", sp->sname);
|
log_debug("no spell function for %s, try callback", sp->sname);
|
||||||
return callbacks.cast_spell(co, fname);
|
return callbacks.cast_spell(co, fname);
|
||||||
}
|
}
|
||||||
return fun(co);
|
return fun(co);
|
||||||
|
|
|
@ -92,7 +92,7 @@ int update_nmrs(void)
|
||||||
++newplayers;
|
++newplayers;
|
||||||
}
|
}
|
||||||
else if (!fval(f, FFL_NOIDLEOUT|FFL_CURSED)) {
|
else if (!fval(f, FFL_NOIDLEOUT|FFL_CURSED)) {
|
||||||
int nmr = turn - f->lastorders + 1;
|
int nmr = turn - f->lastorders;
|
||||||
if (timeout>0) {
|
if (timeout>0) {
|
||||||
if (nmr < 0 || nmr > timeout) {
|
if (nmr < 0 || nmr > timeout) {
|
||||||
log_error("faction %s has %d NMR", itoa36(f->no), nmr);
|
log_error("faction %s has %d NMR", itoa36(f->no), nmr);
|
||||||
|
|
Loading…
Reference in New Issue