i'm currently in the process of porting warfare to another island. There are quite a few hangar buildings already placed and i thought it would be nice if i cound incorporate them into the gameplay instead of placing yet another and leaving the others without function.
i haved tried to place gamelogics on top of those buildings and set their init field to not use "this" but "(position this) nearestObject ID" where ID was the ID of the hangar building the gamelogic was placed on.
unfortunately this doesn't seem to work as i get strange script errors when ***starting the mission and the hangars don't work as i intended either.
I've also tried a few other variants but none of them seem to work. The farthest i was able to get was to have the marker change color when captured but as soon as that happened the script error was back again and i couldn't purchase anything.
Any help on this will be greatly appreciated.
Well, here's a bull-headed idea, but it might just work. If the geometry of the hangar that's already on the map is the same as that of the Warfare hangar, try to position a Warfare hangar exactly where the hangar on the map is on every axis. This way, you'll have two hangars in the same spot, but it looks like one. Another thing you can try is to sink the Warfare hangar into the ground, although I'm not sure how high the buy zone goes.
that's an idea i've played around with, too. i'd prefer something a little 'cleaner' but if all else fails i will try and make that work.
however - in my experience - i will most likely see a lot of clipping issues - so called z-fighting - when two objects occupy the same point in space. now if i could somehow make one of them invisible that would be great.
as for sinking objects into the ground - i do not know how hard - if even possible - it would be to destroy them in that case and i want too keep that strategic option open to players.