I'd like to make a building that can be built over normal buildings and will block the movement of flying units, like normal buildings do for ground units. Is there A way?
You need to change the Movement - Collide field in the data editor to have only Flying checked. You may also need to change the Movement - Plane Array field, though I'm not sure.
Only having the flying Collide didn't work and nether did changing the Plane Array ( I think the Plane Array actually only changes what weapons can hit the unit ).
I'd like to make a building that can be built over normal buildings and will block the movement of flying units, like normal buildings do for ground units. Is there A way?
The basic problem you're going to face is that collision for flying units is hardcoded to be soft (as opposed to hard collision for ground units.) I am not sure if anyone has or will be able to figure out a way to make flying units use hard collision.
However workarounds are possible. A very simple one is a behavior that periodically searches the area around the building for flying units and applies a positive force to them. That'll essentially push them away from the building, although it still won't give them hard collision and I don't believe they will pathfind around the obstacle which is kind of a deal killer.
I was afraid it would be like that. Unfortunately I need them to pathfind for what I wanted to do.
I tried everything I could think of anyway because I realy wanted this to work, but nothing did. Thanks for the help, it seems that I will just have to give up on this.
If anyone does manage to do this please let me know.
Rollback Post to RevisionRollBack
To post a comment, please login or register a new account.
I'd like to make a building that can be built over normal buildings and will block the movement of flying units, like normal buildings do for ground units. Is there A way?
You need to change the Movement - Collide field in the data editor to have only Flying checked. You may also need to change the Movement - Plane Array field, though I'm not sure.
@Eltonbrand: Go
Only having the flying Collide didn't work and nether did changing the Plane Array ( I think the Plane Array actually only changes what weapons can hit the unit ).
The basic problem you're going to face is that collision for flying units is hardcoded to be soft (as opposed to hard collision for ground units.) I am not sure if anyone has or will be able to figure out a way to make flying units use hard collision.
However workarounds are possible. A very simple one is a behavior that periodically searches the area around the building for flying units and applies a positive force to them. That'll essentially push them away from the building, although it still won't give them hard collision and I don't believe they will pathfind around the obstacle which is kind of a deal killer.
@RileyStarcraft: Go
I was afraid it would be like that. Unfortunately I need them to pathfind for what I wanted to do.
I tried everything I could think of anyway because I realy wanted this to work, but nothing did. Thanks for the help, it seems that I will just have to give up on this.
If anyone does manage to do this please let me know.