Request for LUA interaction with XR2 mkII

flyer

Member
Joined
Jan 20, 2010
Messages
56
Reaction score
0
Points
6
Hi there,

I have a question which is directed at dbeachy1 and all of the other people involved in the development of the XR2 mkII.

Would it be possible to include some LUA interaction with the next version of the XR2? I have noticed in the documentation that it is possible to create (and I quote...) "type-specific vessel methods". I looked at this but quickly realised it must be done from inside the original DLL. So I thought I would post my request for the XR2 mkII.

Some potential examples of the "interaction" I mean:


- Functions that allow manipulation of the XR2' in-built autopilots.
I know that it has been said that "heading hold" and "altitude hold" autopilots would not be coded into the XR2, but if some interaction with the XR2's attitude hold autopilot could be included with LUA, then a LUA autopilots could be coded that simply send commands to the ship which then sets appropriate attitude to make heading or altitude changes?

- The same for the speed autopilot.
I know there already is a good speed autopilot included with the XR2, but being able to interface with it via LUA could open up the possibility of automatic speed control.

- Some interaction with the scram engines.
The fuel flow can already be obtained via the existing LUA command set, but could the total scram thrust be made available? Also, would it be possible to make available the throttle...sorry thrust lever, position and have the ability to change it via LUA. This could lead the way to scram speed autopilots (or an interesting combination of main/scram speed autopilots).

- Other general actions like gear position/raising or lowering, opening hover/retro doors, opening nose cone, APU system information (starting and stopping) etc. etc. etc.


Don't get me wrong, I understand this is probably quite an undertaking, but I thought I would throw it out there and see if the developer would be interested and also to gauge the response from the other people on the forum.

Anyway, keep up the good work, the pictures that are coming out look great!


Flyer
 
Damage might be good too, as in the ability of a Lua script to cause or repair said damage. Seems to me this could be easier to do if tied to the XR Connect module rather than the individual vessel modules. Then again, I could be completely wrong. Wouldn't be the first time!
 
Good thinking T - could provide the basis for some interesting mission / challenge scenarios...
 
XR vessels already implement the public XRVesselCtrl C++ API (take a look at XRVesselCtrlDemo on my Web site), so LUA interaction could (and should) just use that API. [The APIs include the ability to set/clear XR damage as well as manage the autopilots, among a bunch of other things.]

In other words, any add-on developer could write a LUA scripting add-on using the existing XRVesselCtrl APIs and it would immediately support all XR vessels, including the XR2 Mk II when it eventually ships. No additional XR coding work is necessary. :)
 
Awesome...I shall investigate and see if it is within my limited abilities!

Thanks for the info!

-----------

Just as I suspected...it is beyond my limited abilities - oh well, it's late and I can try another time...
 
Last edited:
Back
Top