From 331546eec4b65938b8865fcdba1439802047f332 Mon Sep 17 00:00:00 2001 From: Enno Rehling Date: Mon, 26 Aug 2019 19:09:40 +0200 Subject: [PATCH] at_npcfaction is deprecated stuff. --- src/attributes/attributes.c | 2 +- src/kernel/ally.c | 17 ----------------- 2 files changed, 1 insertion(+), 18 deletions(-) diff --git a/src/attributes/attributes.c b/src/attributes/attributes.c index 2c82603fb..f580a4f29 100644 --- a/src/attributes/attributes.c +++ b/src/attributes/attributes.c @@ -196,7 +196,6 @@ void register_attributes(void) at_register(&at_group); at_register(&at_building_generic_type); - at_register(&at_npcfaction); /* connection-typen */ register_bordertype(&bt_noway); @@ -205,6 +204,7 @@ void register_attributes(void) register_bordertype(&bt_illusionwall); register_bordertype(&bt_road); + at_deprecate("npcfaction", a_readint); at_deprecate("siege", a_readint); at_deprecate("maxmagicians", a_readint); /* factions with differnt magician limits, probably unused */ at_deprecate("hurting", a_readint); /* an old arena attribute */ diff --git a/src/kernel/ally.c b/src/kernel/ally.c index 5ecf728bc..fe65c15dd 100644 --- a/src/kernel/ally.c +++ b/src/kernel/ally.c @@ -220,17 +220,6 @@ static void init_npcfaction(variant *var) var->i = 1; } -attrib_type at_npcfaction = { - "npcfaction", - init_npcfaction, - NULL, - NULL, - a_writeint, - a_readint, - NULL, - ATF_UNIQUE -}; - /** Limits the available help modes * The bitfield returned by this function specifies the available help modes * in this game (so you can, for example, disable HELP GIVE globally). @@ -284,12 +273,6 @@ int alliance_status(const faction *f, const faction *f2, int status) { if (status > 0) { int mask = AllianceRestricted(); if (mask) { - if (a_find(f->attribs, &at_npcfaction)) { - return status; - } - if (a_find(f2->attribs, &at_npcfaction)) { - return status; - } if (f->alliance != f2->alliance) { status &= ~mask; }