Allow units to request non-colliding simple path
Posted: Tue May 09, 2017 10:03 am
I have flying units that when requesting a path (using move_to or other forms of unit commands) cannot path over walls or water, yet they can actually move over them due to no collision box (like all flying robots in the game).
I request that a flag be available during the set_command either at a unit level, or at a unit_group level to request a simple path that a non-colliding unit can follow. There would be some very small overhead in checking the flag, and then more overhead after that to confirm that all members of the unit_group have a nil or 0.0 collision box, before returning/giving the simple path command to the unit_group. Should fail if one or more members of the unit_group would not be able to do the path (due to having a collision box).
The pathing would be point-to-point, ultra simple and very fast compared to worrying about pathable terrain or obstructions.
- specifically I think this is fine being at a unit_group level only, but I suppose if the logic is quick enough then applying the same flags to a single unit entity set_command request then that would be awesome too
- I think this would be awesome to add anyway, so that modders (like bobingabout) can make crazy evil flying biters/spitters that can properly path over player's walls or over oceans and attack deep in the player's bases. This sort of API/engine change would be handy for many mods.
I request that a flag be available during the set_command either at a unit level, or at a unit_group level to request a simple path that a non-colliding unit can follow. There would be some very small overhead in checking the flag, and then more overhead after that to confirm that all members of the unit_group have a nil or 0.0 collision box, before returning/giving the simple path command to the unit_group. Should fail if one or more members of the unit_group would not be able to do the path (due to having a collision box).
The pathing would be point-to-point, ultra simple and very fast compared to worrying about pathable terrain or obstructions.
- specifically I think this is fine being at a unit_group level only, but I suppose if the logic is quick enough then applying the same flags to a single unit entity set_command request then that would be awesome too
- I think this would be awesome to add anyway, so that modders (like bobingabout) can make crazy evil flying biters/spitters that can properly path over player's walls or over oceans and attack deep in the player's bases. This sort of API/engine change would be handy for many mods.