--- deliantra/server/common/arch.C 2007/06/07 18:55:24 1.65 +++ deliantra/server/common/arch.C 2007/06/09 21:16:12 1.67 @@ -71,7 +71,7 @@ shstr_cmp name_cmp (name); for_all_archetypes (at) - if (at->archname == name_cmp) + if (at->name == name_cmp) return at; return 0; @@ -88,7 +88,7 @@ shstr_cmp name_cmp (name); for_all_archetypes (at) - if (at->archname == name_cmp && at->type == type) + if (at->name == name_cmp && at->type == type) return at; return 0; @@ -445,6 +445,14 @@ { archetype *at = *p; + // some flags get inherited formt he head (probably a lot more) + // doing it here doesn't feel too cozy, but it allows code + // to ignore head checks for these flags, which saves time + at->flag [FLAG_ALIVE] = new_head->flag [FLAG_ALIVE]; + at->flag [FLAG_NO_PICK] = new_head->flag [FLAG_NO_PICK]; + at->flag [FLAG_MONSTER] = new_head->flag [FLAG_MONSTER]; + at->flag [FLAG_IS_FLOOR] = new_head->flag [FLAG_IS_FLOOR]; + if (at->x < new_head->min_x) new_head->min_x = at->x; if (at->y < new_head->min_y) new_head->min_y = at->y; if (at->x > new_head->max_x) new_head->max_x = at->x; @@ -522,7 +530,7 @@ abort (); char buf[MAX_BUF]; - sprintf (buf, "bug, please report (%s)", ARCH_SINGULARITY, name); + sprintf (buf, "bug, please report (%s)", name); object *op = get_archetype ("bug"); op->name = op->name_pl = buf;