binding HELP to Lua

This commit is contained in:
Enno Rehling 2012-06-17 15:55:23 -07:00
parent d02857ebb9
commit 573d4c3e97
5 changed files with 9 additions and 6 deletions

View File

@ -37,6 +37,7 @@ function test_process()
assert_equal("function", _G.type(eressea.process.renumber))
assert_equal("function", _G.type(eressea.process.restack))
assert_equal("function", _G.type(eressea.process.set_spells))
assert_equal("function", _G.type(eressea.process.set_help))
end
function test_settings()

View File

@ -194,6 +194,11 @@ void process_setspells(void) {
process_cmd(K_COMBATSPELL, combatspell_cmd, 0);
}
void process_sethelp(void) {
process_cmd(K_ALLY, ally_cmd, 0);
}
void process_maintenance(void) {
region * r;
for (r=regions; r; r=r->next) {

View File

@ -29,6 +29,7 @@ void process_promote(void);
void process_renumber(void);
void process_restack(void);
void process_setspells(void);
void process_sethelp(void);
#ifdef __cplusplus
}

View File

@ -26,5 +26,6 @@ module eressea {
void process_renumber @ renumber(void); /* RENUMBER */
void process_restack @ restack(void); /* SORT */
void process_setspells @ set_spells(void); /* COMBATSPELL */
void process_sethelp @ set_help(void); /* HELP */
}
}

View File

@ -3654,6 +3654,7 @@ void update_long_order(unit * u)
boolean trade = false;
boolean hunger = LongHunger(u);
freset(u, UFL_MOVED);
freset(u, UFL_LONGACTION);
if (hunger) {
/* Hungernde Einheiten führen NUR den default-Befehl aus */
@ -4428,11 +4429,6 @@ static void maintain_buildings_1(region * r)
maintain_buildings(r, false);
}
static void reset_moved(unit * u)
{
freset(u, UFL_MOVED);
}
/** warn about passwords that are not US ASCII.
* even though passwords are technically UTF8 strings, the server receives
* them as part of the Subject of an email when reports are requested.
@ -4476,7 +4472,6 @@ void init_processor(void)
add_proc_order(p, K_GROUP, &group_cmd, 0, NULL);
p += 10;
add_proc_unit(p, &reset_moved, "Instant-Befehle");
add_proc_order(p, K_QUIT, &quit_cmd, 0, NULL);
add_proc_order(p, K_URSPRUNG, &origin_cmd, 0, NULL);
add_proc_order(p, K_ALLY, &ally_cmd, 0, NULL);