From 8c5ffed1cb9a22fff0d65511e4f93e714ecafd53 Mon Sep 17 00:00:00 2001 From: "Tony J. White" Date: Mon, 19 Feb 2007 02:00:28 +0000 Subject: * (bug 3021) don't let building on top of existing structures override the unique test (kevlarman) --- src/game/g_buildable.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'src/game/g_buildable.c') diff --git a/src/game/g_buildable.c b/src/game/g_buildable.c index f479d353..a09ca189 100644 --- a/src/game/g_buildable.c +++ b/src/game/g_buildable.c @@ -2897,6 +2897,16 @@ itemBuildError_t G_CanBuild( gentity_t *ent, buildable_t buildable, int distance break; } + if( tempent->s.modelindex == BA_A_HOVEL && + buildable == BA_A_HOVEL && + tempent->active ) + { + reason = IBE_HOVEL; + } + else if( tempent->s.modelindex == buildable ) + { + level.markedBuildables[ level.numBuildablesForRemoval++ ] = tempent; + } } } @@ -2972,6 +2982,8 @@ itemBuildError_t G_CanBuild( gentity_t *ent, buildable_t buildable, int distance reason = IBE_REACTOR; break; } + if( tempent->s.modelindex == buildable ) + level.markedBuildables[ level.numBuildablesForRemoval++ ] = tempent; } } -- cgit