Orbiter-Forum  

Go Back   Orbiter-Forum > Orbiter Space Flight Simulator > Orbiter SDK
Register Blogs Orbinauts List Social Groups FAQ Projects Mark Forums Read

Orbiter SDK Orbiter software developers post your questions and answers about the SDK, the API interface, LUA, meshing, etc.

Reply
 
Thread Tools
Old 11-26-2016, 06:44 PM   #1
JMW
Aspiring Addon Developer
 
JMW's Avatar
Default Thruster index

I want to identify by handle, which thrusters are operating in a given situation.

What is the thruster index constructed from ?
Are they numbered in the order they're created initially ?

The info in the scenario is for example
PHP Code:
THLEVEL 0:1.000000 1:1.000000 7:0.250666 8:0.311333 9:0.050286 12:0.050286 13:0.311333 14:0.250666 
Can I display an active thruster handle using sprintf(oapiDebugString(),"........ somehow ?

Last edited by JMW; 11-26-2016 at 06:49 PM. Reason: Removed incorrect info
JMW is offline   Reply With Quote
Old 11-26-2016, 07:37 PM   #2
Hlynkacg
Aspiring rocket scientist
 
Hlynkacg's Avatar


Default

Quote:
Are they numbered in the order they're created initially ?
Yes they are. Likewise for propellant handles.

I'm not sure what you mean by display in this context though. The answer will depend on precisely what you're trying to display and whether you're doing it from within the vessel's code or via an external module or MFD.
Hlynkacg is offline   Reply With Quote
Thanked by:
Old 11-26-2016, 08:34 PM   #3
JMW
Aspiring Addon Developer
 
JMW's Avatar
Default

From within the code, so I can see which thrusters are firing
JMW is offline   Reply With Quote
Old 11-26-2016, 08:54 PM   #4
jedidia
shoemaker without legs
 
jedidia's Avatar
Default

Then you can just use GetThrusterLevel, it takes the handle. I'm not quite sure what you'd want to use the index for.
jedidia is offline   Reply With Quote
Old 11-26-2016, 09:01 PM   #5
JMW
Aspiring Addon Developer
 
JMW's Avatar
Default

I suppose that was just too simple
Thanks Hlynkacg
JMW is offline   Reply With Quote
Reply

  Orbiter-Forum > Orbiter Space Flight Simulator > Orbiter SDK


Thread Tools

Posting Rules
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
Forum Jump


All times are GMT. The time now is 12:27 AM.

Quick Links Need Help?


About Us | Rules & Guidelines | TOS Policy | Privacy Policy

Orbiter-Forum is hosted at Orbithangar.com
Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright 2007 - 2012, Orbiter-Forum.com. All rights reserved.