Well, we have very little coding directives right now. :lol:
Well, lets analyze:
- No need for a generic interface, since the MLP in this case is very space shuttle specific.
- We need a connection orientation
- The T0-umbilical is largely independent of the HDPs
- Should we change this interface ever, MLP and orbiter will need to be recompiled anyway.
- Even for fill&drain, the orbiter would need to do calculations.
Still, I would recommend also storing the name of the MLP vessel in the orbiter, so we can restore the pointer when loading/saving a scenario. Also, I am not sure if using a OBJHANDLE between the callbacks would be smarter, since maybe pointers to a VESSEL might change one day. It could be smarter to get a pointer to the MLP on the first call in a pre or post step and release it again after the callback has processed, assuming that it at least stays constant during the callback.
And much better: A T0Reference class that bundles everything needed to get a T0 interface class during runtime or store the state that no T0 umbilical is available right now. And ignore outside it, that a MLP did ever exist - we only want the T0 interface, so no need to get the full MLP there. Just limit everything to what we really need to know.
And much much better: A IT0Reference interface, that has two implementations: An OrbiterRuntimeT0Reference class and a DummyT0Reference class
The DummyT0Reference class could then be used for testing functions of the STS orbiter without need to run Orbiter.