prefer unit_addorder over addlist where possible.

This commit is contained in:
Enno Rehling 2018-10-14 16:26:36 +02:00
parent f247224844
commit 5aa3b1161f
2 changed files with 2 additions and 2 deletions

View File

@ -2911,7 +2911,7 @@ void maketemp_cmd(unit *u, order **olist)
order *deford = default_order(u2->faction->locale);
if (deford) {
set_order(&u2->thisorder, NULL);
addlist(&u2->orders, deford);
unit_addorder(u2, deford);
}
}
}

View File

@ -2348,7 +2348,7 @@ void patzer_peasantmob(const castorder * co)
create_unit(r, f, n, get_race(RC_PEASANT), 0, LOC(f->locale, "angry_mob"),
NULL);
fset(u, UFL_ISNEW);
addlist(&u->orders, create_order(K_GUARD, lang, NULL));
unit_addorder(u, create_order(K_GUARD, lang, NULL));
set_order(&u->thisorder, default_order(lang));
a = a_new(&at_unitdissolve);
a->data.ca[0] = 1; /* An rpeasants(r). */