Space Engineers Feedback

6
Votes
Improve Turret Ingame API
The idea is simple and straightforward. Since the Raycast update, the PBs cannot acquire an IMyEntity reference anywhere anymore. But giving targets to turrets still require this (unless you want to go on full-manual control and input azimuth and elevation). Developers could easily implement several functions which accept a MyDetectedEntityInfo struct, check it for validity, and then internally resolve it into an IMyEntity reference and set a turret's target. It is very easy, it only requires to properly check the passed struct. — Check if the EntityID points to a valid entity — Check if the struct is not older than 2-3 seconds — Check if the entity is within the turret's firing range. They could also implement a property in IngameAPI which returns a fresh MyDetectedEntityInfo if a turret is firing at something.


Cheetah shared this idea 01/08/17 19:47
xphoenixxx 02/08/17 02:52
Essentially targeting priorities? Although decoys would need to return as "all" target types if we added targeting priorities otherwise they serve no purpose.
Cheetah 02/08/17 09:00
No, I'm not speaking about outright prioritizing. I'm speaking of re-allowing PBs to control turrets without resorting to azimuth and elevation. The functions may just check if there is a hostile decoy in the firing range, and if is, refuse to switch target.
Tharatan 17/08/17 21:37
So I'm trying to understand what the purpose of this would be - you want to allow PB's to control what target a turret shoots at, out of a list of targets in range?