Project MoonBaseAlpha for 2016

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,708
Reaction score
2,683
Points
203
Location
Dallas, TX
We are experience limits in Orbiter. For instance we just attachments for the module and buggy. But because we are using the cockpit view. You have to set the mesh flags. to extpass but then you see thru the ship.

As far as TD points.
static const DWORD ntdvtx_geardown = 16; static TOUCHDOWNVTX tdvtx_geardown[ntdvtx_geardown] = { { _V(0, -3.12312, 2), 26150800, 18409627, 1.6, 0.1 }, { _V(-2, -3.12312, -2), 26150800, 18409627, 3.0, 0.2 }, { _V(2, -3.12312, -2), 26150800, 18409627, 3.0, 0.2 }, {_V(-7.7, 0 ,-0.4), 3e7, 3e6, 3}, {_V(7.7, 0 ,-0.4), 3e7, 3e6, 3}, {_V(-1.5, 3 ,13.5), 3e7, 3e6, 3}, {_V(1.5, 3 ,13.5), 3e7, 3e6, 3}, {_V(-1.3, 2.8 ,17), 3e7, 3e6, 3}, {_V(1.3, 2.8 ,17), 3e7, 3e6, 3}, {_V(-1.8, 0 ,18.3), 3e7, 3e6, 3}, {_V(1.8, 0 ,18.3), 3e7, 3e6, 3}, {_V(-1.9, 2.2 ,-13.8), 3e7, 3e6, 3}, {_V(1.9, 2.2 ,-13.8), 3e7, 3e6, 3}, {_V(-3.3, 0 ,-14.9), 3e7, 3e6, 3}, {_V(3.3, 0 ,-14.9), 3e7, 3e6, 3} };
 

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,708
Reaction score
2,683
Points
203
Location
Dallas, TX
Working on the HUD thrust/fuel level

I got the main thrusters to show.

but retros

I have this:
double retrolevel = GetThrusterLevel(th_retro[0]);//get retro level but it shows 0 even though are firing.
 

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,708
Reaction score
2,683
Points
203
Location
Dallas, TX
Confused;(
Looking at the source code. But I can't get it to draw a yellow box for retro.
as I understand if main thrusts are fired then level is 1 if retro then it is -1

th = GetThrusterGroupLevel(THGROUP_MAIN); if (!th) th = GetThrusterGroupLevel(THGROUP_RETRO); //main if (th != engmain) { engmain = th; if (th >= 0.0) { //draw thrust level SelectObject(hDC, g_Param.hBrush[1]);//green box Rectangle(hDC, 130, 144, (int)(130 + engmain * (200)), 187);//thrust } //retro else { SelectObject(hDC, g_Param.hBrush[2]);//yellow box Rectangle(hDC, 130, 144, (int)(130 + engmain * (200)), 187);//retrothrust } } sprintf(oapiDebugString(), "main %5f th %5f ", engmain, th);
SOURCE
// Update main engine status vofs += 4; double th = g_focusobj->GetThrusterGroupLevel(THGROUP_MAIN); if (!th) th = -g_focusobj->GetThrusterGroupLevel(THGROUP_RETRO); if (th != engmain) { engmain = th; if (th >= 0.0) { grp->Vtx[vofs].x = grp->Vtx[vofs+2].x = dx+46.0f*scale; grp->Vtx[vofs+1].x = grp->Vtx[vofs+3].x = dx+(float)((46.0+engmain*94.0)*scale); for (i = 0; i < 4; i++) grp->Vtx[vofs+i].tu = 4.0f/texw; } else { grp->Vtx[vofs].x = grp->Vtx[vofs+2].x = dx+(140.0f+(float)engmain*94.0f)*scale; grp->Vtx[vofs+1].x = grp->Vtx[vofs+3].x = dx+140.0f*scale; for (i = 0; i < 4; i++) grp->Vtx[vofs+i].tu = 6.0f/texw; } }
If main are fired the th and engmain are 1. but retro get 0


Not sure about this.
// Update main engine readout vofs += 4*5; th = (engmain >= 0.0 ? engmain*g_focusobj->GetThrusterGroupMaxth(THGROUP_MAIN) : -engmain*g_focusobj->GetThrusterGroupMaxth(THGROUP_RETRO));


Also switching view in vc doesn't update the texture??
 

Attachments

  • eaglevcreadout.jpg
    eaglevcreadout.jpg
    52 KB · Views: 5

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,708
Reaction score
2,683
Points
203
Location
Dallas, TX
Here is the source code
// Update main engine status vofs += 4; double th = g_focusobj->GetThrusterGroupLevel(THGROUP_MAIN); if (!th) th = -g_focusobj->GetThrusterGroupLevel(THGROUP_RETRO); if (th != engmain) { engmain = th; if (th >= 0.0) { grp->Vtx[vofs].x = grp->Vtx[vofs+2].x = dx+46.0f*scale; grp->Vtx[vofs+1].x = grp->Vtx[vofs+3].x = dx+(float)((46.0+engmain*94.0)*scale); for (i = 0; i < 4; i++) grp->Vtx[vofs+i].tu = 4.0f/texw; } else { grp->Vtx[vofs].x = grp->Vtx[vofs+2].x = dx+(140.0f+(float)engmain*94.0f)*scale; grp->Vtx[vofs+1].x = grp->Vtx[vofs+3].x = dx+140.0f*scale; for (i = 0; i < 4; i++) grp->Vtx[vofs+i].tu = 6.0f/texw; } }
then mine code
th = GetThrusterGroupLevel(THGROUP_MAIN); //get thrust main level if (!th) th = -GetThrusterGroupLevel(THGROUP_RETRO); //get retro thrustes - 1 to 0

but all I ever get is Th as 0 when retro are fired. Should it be -1. and then we have the negative sign so that would be 1?

so when main thrusters are fired GetThrusterGroupLevel(THGROUP_MAIN)=1.
so when retro thrusters are fired GetThrusterGroupLevel(THGROUP_RETRO)=-1.

But that negative GetThrusterGroupLevel(THGROUP_RETRO) makes it 1, right

But all I get for retro is 0
 

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,708
Reaction score
2,683
Points
203
Location
Dallas, TX
Got the vc fixed.
But get a weird crash result. The eagle will go underground. Not sure if a Touchdown issues or what?
static const DWORD ntdvtx_geardown = 8; static TOUCHDOWNVTX tdvtx_geardown[ntdvtx_geardown] = { { _V(0, -3.12312, 10), 26150800, 18409627, 1.6, 0.1 }, { _V(-6, -3.12312, -10), 26150800, 18409627, 3.0, 0.2 }, { _V(6, -3.12312, -10), 26150800, 18409627, 3.0, 0.2 }, {_V(-6.6, -0.5 ,-12), 3e7, 3e6, 3}, {_V(6.6, -.5 ,-12), 3e7, 3e6, 3}, {_V(0, 0 ,-16), 3e7, 3e6, 3}, {_V(0, 3.2 ,0), 3e7, 3e6, 3}, {_V(0, 0 ,16.7), 3e7, 3e6, 3}, };
SetTouchdownPoints(tdvtx_geardown, ntdvtx_geardown);

I have this to adjust if the gear is up. But it does it when the gear is down??
SetTouchdownPoints(_V(0, -3.12312 + GEAR_proc * 1.5, 8.7), _V(-2, -3.12312 + GEAR_proc * 1.5, -9.6), _V(2, -3.12312 + GEAR_proc * 1.5, -9.6));
 

Buck Rogers

Major Spacecadet
Joined
Feb 26, 2013
Messages
359
Reaction score
279
Points
63
Having thought over it, I noticed your damping is maybe the problem, it's much "softer" than the ones I used in the dummy test.
Also it is still a tri-setup and not a quad, hopefully this eve. I can take another look at it.
TDP_1_1_STIFFNESS = 700000 TDP_1_1_DAMPING = 120000
 

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,708
Reaction score
2,683
Points
203
Location
Dallas, TX
Weird. The VB version is good but the DLL version the nose is sticking down.
VB TDP_1_0_POS = 0 -3.4 10 TDP_1_0_STIFFNESS = 221733 TDP_1_0_DAMPING = 156068 TDP_1_0_MU = 0.1 TDP_1_0_MULNG = 0.2 TDP_1_1_POS = -6 -3.2 -10 TDP_1_1_STIFFNESS = 221733 TDP_1_1_DAMPING = 156068 TDP_1_1_MU = 3 TDP_1_1_MULNG = 0.2 TDP_1_2_POS = 6 -3.2 -10 TDP_1_2_STIFFNESS = 221733 TDP_1_2_DAMPING = 156068 TDP_1_2_MU = 3 TDP_1_2_MULNG = 0.2 TDP_1_3_POS = 0 0 -16 TDP_1_3_STIFFNESS = 221733 TDP_1_3_DAMPING = 156068 TDP_1_3_MU = 3 TDP_1_3_MULNG = 0.2 TDP_1_4_POS = -8 3.2 -12 TDP_1_4_STIFFNESS = 221733 TDP_1_4_DAMPING = 156068 TDP_1_4_MU = 3 TDP_1_4_MULNG = 0.2 TDP_1_5_POS = 8 3.2 -12 TDP_1_5_STIFFNESS = 221733 TDP_1_5_DAMPING = 156068 TDP_1_5_MU = 3 TDP_1_5_MULNG = 0.2 TDP_1_6_POS = 0 3.2 0 TDP_1_6_STIFFNESS = 221733 TDP_1_6_DAMPING = 156068 TDP_1_6_MU = 3 TDP_1_6_MULNG = 0.2 TDP_1_7_POS = -8 3.2 12 TDP_1_7_STIFFNESS = 221733 TDP_1_7_DAMPING = 156068 TDP_1_7_MU = 3 TDP_1_7_MULNG = 0.2 TDP_1_8_POS = 8 3.2 12 TDP_1_8_STIFFNESS = 221733 TDP_1_8_DAMPING = 156068 TDP_1_8_MU = 3 TDP_1_8_MULNG = 0.2 TDP_1_9_POS = 0 0 16 TDP_1_9_STIFFNESS = 221733 TDP_1_9_DAMPING = 156068 TDP_1_9_MU = 3 TDP_1_9_MULNG = 0.2

dll static const int ntdvtx = 10; static TOUCHDOWNVTX tdvtx[ntdvtx] = { { _V(0, -3.4, 10), 221733, 156068, .1, 0.2 }, { _V(-6 , -3.2, -10), 221733, 156068, 3.0, 0.2 }, { _V(6 ,-3.2, -10), 221733, 156068, 3.0, 0.2 }, {_V(0 ,0 , 16), 221733, 156068, 3.0, 0.2 }, {_V(-8, 3.2, -12), 221733, 156068, 3.0, 0.2 }, {_V(8, 3.2, -12), 221733, 156068, 3.0, 0.2 }, {_V(0, 3.2, 0), 221733, 156068, 3.0, 0.2 }, {_V(-8, 3.2, 12), 221733, 156068, 3.0, 0.2 }, {_V(8, 3.2, 12), 221733, 156068, 3.0, 0.2 }, {_V(0, 0, 16), 221733, 156068, 3.0, 0.2 }, };
 

Attachments

  • eaglelanded1.jpg
    eaglelanded1.jpg
    81.5 KB · Views: 8
  • eaglelanded2.jpg
    eaglelanded2.jpg
    73.2 KB · Views: 8

Buck Rogers

Major Spacecadet
Joined
Feb 26, 2013
Messages
359
Reaction score
279
Points
63
These are the DG TD points for ref.

static const DWORD ntdvtx_geardown = 13;
static TOUCHDOWNVTX tdvtx_geardown[ntdvtx_geardown] = {
{_V( 0 ,-2.57,10 ), 1e6, 1e5, 1.6, 0.1},
{_V(-3.5 ,-2.57,-1 ), 1e6, 1e5, 3.0, 0.2},
{_V( 3.5 ,-2.57,-1 ), 1e6, 1e5, 3.0, 0.2},
{_V(-8.5 ,-0.3 ,-7.05), 1e7, 1e5, 3.0},
{_V( 8.5 ,-0.3 ,-7.05), 1e7, 1e5, 3.0},
{_V(-8.5 ,-0.4 ,-3 ), 1e7, 1e5, 3.0},
{_V( 8.5 ,-0.4 ,-3 ), 1e7, 1e5, 3.0},
{_V(-8.85, 2.3 ,-5.05), 1e7, 1e5, 3.0},
{_V( 8.85, 2.3 ,-5.05), 1e7, 1e5, 3.0},
{_V(-8.85, 2.3 ,-7.05), 1e7, 1e5, 3.0},
{_V( 8.85, 2.3 ,-7.05), 1e7, 1e5, 3.0},
{_V( 0 , 2 , 6.2 ), 1e7, 1e5, 3.0},
{_V( 0 ,-0.6 ,10.65), 1e7, 1e5, 3.0}
};

static const DWORD ntdvtx_gearup = 13;
static TOUCHDOWNVTX tdvtx_gearup[ntdvtx_gearup] = {
{_V( 0 ,-1.5 ,9), 1e7, 1e5, 3.0, 3.0},
{_V(-6 ,-0.8 ,-5), 1e7, 1e5, 3.0, 3.0},
{_V( 3 ,-1.2 ,-5), 1e7, 1e5, 3.0, 3.0},
{_V(-8.5 ,-0.3 ,-7.05), 1e7, 1e5, 3.0},
{_V( 8.5 ,-0.3 ,-7.05), 1e7, 1e5, 3.0},
{_V(-8.5 ,-0.4 ,-3 ), 1e7, 1e5, 3.0},
{_V( 8.5 ,-0.4 ,-3 ), 1e7, 1e5, 3.0},
{_V(-8.85, 2.3 ,-5.05), 1e7, 1e5, 3.0},
{_V( 8.85, 2.3 ,-5.05), 1e7, 1e5, 3.0},
{_V(-8.85, 2.3 ,-7.05), 1e7, 1e5, 3.0},
{_V( 8.85, 2.3 ,-7.05), 1e7, 1e5, 3.0},
{_V( 0 , 2 , 6.2 ), 1e7, 1e5, 3.0},
{_V( 0 ,-0.6 ,10.65), 1e7, 1e5, 3.0}
};


I would suggest using these values

1e7, 1e5, 3.0, 3.0},

for all points as they represent metal on ground (note only the first 3 need the second 3.0)
-I think VB ignores the mu values?
Interesting touch- the gear-up setting is slightly off center for crash effect.
 
Last edited:

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,708
Reaction score
2,683
Points
203
Location
Dallas, TX
I used the Shuttle A code and adjusted the Y. level but slight rotation on the Pad.
{_V(-3 ,-3.12312, 12.5), 3.5e6, 3.5e5, 3}, {_V(-3 ,-3.12312,-13.5), 3e6, 3e5, 3}, {_V(3 ,-3.12312,-13.5), 3e6, 3e5, 3}, {_V(3 ,-3.12312, 12.5), 3.5e6, 3.5e5, 3}, {_V(-7.7, 0 ,-0.4), 3e7, 3e6, 3}, {_V(7.7, 0 ,-0.4), 3e7, 3e6, 3}, {_V(-1.5, 3 ,13.5), 3e7, 3e6, 3}, {_V(1.5, 3 ,13.5), 3e7, 3e6, 3}, {_V(-1.3, 2.8 ,17), 3e7, 3e6, 3}, {_V(1.3, 2.8 ,17), 3e7, 3e6, 3}, {_V(-1.8, 0 ,18.3), 3e7, 3e6, 3}, {_V(1.8, 0 ,18.3), 3e7, 3e6, 3}, {_V(-1.9, 2.2 ,-13.8), 3e7, 3e6, 3}, {_V(1.9, 2.2 ,-13.8), 3e7, 3e6, 3}, {_V(-3.3, 0 ,-14.9), 3e7, 3e6, 3}, {_V(3.3, 0 ,-14.9), 3e7, 3e6, 3}
 

francisdrake

Addon Developer
Addon Developer
Joined
Mar 23, 2008
Messages
1,078
Reaction score
896
Points
128
Website
francisdrakex.deviantart.com
These are the touchdown points I used for the Peregrine lander.
The lander is quite lightweight (200 kg).

If your vessel is heavier, the spring stiffness (here: 1e7) should be higher, otherwise the belly sinks down to the ground.
The first 4 points are for touchdown, the last 2 are just for the top shape.

Code:
static TOUCHDOWNVTX tdvtx_hover[ntdvtx_hover] = {
    { _V( 0, -1.19, 2.2),  1e7, 1e5, 2, 1},
    { _V( -2.2, -1.19, 0),  1e7, 1e5, 2, 1},
    { _V(  2.2, -1.19, 0),  1e7, 1e5, 2, 1},
    { _V(  0, -1.19, -2.2), 1e7, 1e5, 2},
    
    { _V( 1.5, 0.8, 0),   1e6, 2e5, 0.6},
    { _V(-1.5,  0.8, 0),   1e6, 2e5, 0.6}
};
 

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,708
Reaction score
2,683
Points
203
Location
Dallas, TX
weird.
static const int ntdvtx = 16; static TOUCHDOWNVTX tdvtx[ntdvtx] = { {_V(-3 ,-3.12312, 12.5), 1e7, 1e5, 3.0, 3.0 }, {_V(-3 ,-3.12312,-13.5), 1e7, 1e5, 3.0, 3.0 }, {_V(3 ,-3.12312,-13.5), 1e7, 1e5, 3.0, 3.0 }, {_V(3 ,-3.12312, 12.5), 1e7, 1e5, 3.0, 3.0 }, {_V(-7.7, 0 ,-0.4), 1e7, 1e5, 3.0, 3.0 }, {_V(7.7, 0 ,-0.4), 1e7, 1e5, 3.0, 3.0 }, {_V(-1.5, 3 ,13.5), 1e7, 1e5, 3.0, 3.0 }, {_V(1.5, 3 ,13.5), 1e7, 1e5, 3.0, 3.0 }, {_V(-1.3, 2.8 ,17), 1e7, 1e5, 3.0, 3.0 }, {_V(1.3, 2.8 ,17), 1e7, 1e5, 3.0, 3.0 }, {_V(-1.8, 0 ,18.3), 1e7, 1e5, 3.0, 3.0 }, {_V(1.8, 0 ,18.3), 1e7, 1e5, 3.0, 3.0 }, {_V(-1.9, 2.2 ,-13.8), 1e7, 1e5, 3.0, 3.0 }, {_V(1.9, 2.2 ,-13.8), 1e7, 1e5, 3.0, 3.0 }, {_V(-3.3, 0 ,-14.9), 31e7, 1e5, 3.0, 3.0 }, {_V(3.3, 0 ,-14.9), 1e7, 1e5, 3.0, 3.0 } };

this is good but a slight rotation in the x heading.
I applied some hover and tried to land and i get this?
 

Attachments

  • eaglelanded3.jpg
    eaglelanded3.jpg
    80.2 KB · Views: 9

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,708
Reaction score
2,683
Points
203
Location
Dallas, TX
Fixed that. hovered up and rose up and then lowered. But the heading is changing while landed.
I used the parking brake and said landed but the heading lowly changing
 

francisdrake

Addon Developer
Addon Developer
Joined
Mar 23, 2008
Messages
1,078
Reaction score
896
Points
128
Website
francisdrakex.deviantart.com
To avoid the upside-down landing, the plane of the first 3 touchdown points shall define an upward vector.
I think it is like this:
Front (centerline), left, right.

Against the heading change when landed, you could try to increase the friction (but 3 is already high).

What is the mass of your vessel?
If it is too light, it tends not to settle down but keeps dancing with mini-hops, visible as jitter on the SurfaceMFD and the HUD.
 

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,708
Reaction score
2,683
Points
203
Location
Dallas, TX
Thanks
SetEmptyMass(173000.0);
and with fuel:
MAX_FUEL = 36000.0
 

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,708
Reaction score
2,683
Points
203
Location
Dallas, TX
Here is something I am trying to fix. In the VC mode we have a mesh that the slope ladder,.... is displayed. Got that to work.
BUt when you pull up the UACS menu you get this.

I tried stretching the HUD mesh to make it wider. But the HUD display just stretched. Then I cut the edges and map them hoping to get the UACS menu on the sides. but all it did was map the center stuff to the sides.

That's way I think UACS might be good to be in a MFD. But I would need a lot of help to do that.
 

Attachments

  • eaglevchud1b.jpg
    eaglevchud1b.jpg
    44.2 KB · Views: 6
Top