* Bugfix: Grund für duplizierende GM-attribute gefunden

* Bugfix: Mistelzweigmeldung crasht report
This commit is contained in:
Enno Rehling 2002-05-09 11:10:39 +00:00
parent d7ee16f0f2
commit df2a6a47f1
2 changed files with 4 additions and 4 deletions

View File

@ -1974,13 +1974,13 @@ use_mistletoe(struct unit * user, const struct item_type * itype, int amount, co
if (user->number>mtoes) {
ADDMSG(&user->faction->msgs, msg_message("use_singleperson",
"unit item region command", user, itype, user->region, cmd));
"unit item region command", user, itype->rtype, user->region, cmd));
return -1;
}
new_use_pooled(user, itype->rtype, GET_SLACK|GET_RESERVE|GET_POOLED_SLACK, user->number);
a_add(&user->attribs, make_fleechance((float)1.0));
ADDMSG(&user->faction->msgs, msg_message("use_item",
"unit item", user, itype));
"unit item", user, itype->rtype));
return 0;
}

View File

@ -1011,7 +1011,7 @@ update_gms(void)
add_key((attrib**)&permissions->data.v, atoi36(keys[k]));
}
for (i=I_GREATSWORD;i!=I_KEKS;++i) {
attrib * a = a_find(permissions, &at_gmcreate);
attrib * a = a_find((attrib*)permissions->data.v, &at_gmcreate);
while (a && a->data.v!=(void*)olditemtype[i]) a=a->nexttype;
if (!a) a_add((attrib**)&permissions->data.v, make_atgmcreate(olditemtype[i]));
}
@ -1963,7 +1963,7 @@ update_gmquests(void)
if (p!=NULL) p->flags |= PFL_NOMONSTERS;
}
for (p=0;p!=MAX_POTIONS;++p) {
attrib * a = a_find(permissions, &at_gmcreate);
attrib * a = a_find((attrib*)permissions->data.v, &at_gmcreate);
while (a && a->data.v!=(void*)oldpotiontype[p]->itype) a=a->nexttype;
if (!a) a_add((attrib**)&permissions->data.v, make_atgmcreate(oldpotiontype[p]->itype));
}