- Crashfixes

This commit is contained in:
Christian Schlittchen 2002-04-14 10:59:06 +00:00
parent d076e53c4d
commit 028b9d8d4b
2 changed files with 3 additions and 3 deletions

View File

@ -583,7 +583,7 @@ givemen(int n, unit * u, unit * u2, const char * cmd)
error = 73;
} else if (u2 && (has_skill(u, SK_MAGIC) || has_skill(u2, SK_MAGIC))) {
error = 158;
} else if (fval(u, UFL_WERE) != fval(u2, UFL_WERE)) {
} else if (u2 && fval(u, UFL_WERE) != fval(u2, UFL_WERE)) {
error = 312;
} else {
if (n > u->number) n = u->number;

View File

@ -2936,7 +2936,7 @@ cw_read(attrib * a, FILE * f)
curse_read(a, f);
br->self = c;
fscanf(f, "%d ", &br->id);
fscanf(f, "%u ", &br->id);
ur_add((void *)br->id, (void**)&wc->wall, resolve_borderid);
ur_add((void *)br, (void**)&wc->buddy, resolve_buddy);
return AT_READ_OK;
@ -4934,7 +4934,7 @@ sp_icastle(castorder *co)
spellparameter *pa = co->par;
icastle_data * data;
if((type=bt_find(pa->param[0]->data.s)) == NOBUILDING) {
if((type=findbuildingtype(pa->param[0]->data.s, mage->faction->locale)) == NULL) {
type = bt_find("castle");
}