Depth Setting in Event

All discussions & material related to Command's Lua interface

Moderators: RoryAndersonCDT, michaelm75au, angster, MOD_Command

Post Reply
Parel803
Posts: 962
Joined: Thu Oct 10, 2019 3:39 pm
Location: Netherlands

Depth Setting in Event

Post by Parel803 »

Good Evening,

Busy with some extra tryings on Riser/Sinker. Had help in the pas from KH
First I want a Submarine to come to Periscope depth.

The Event to go to periscope works but she goes to 0 ft (every time in the 1 minute regular time I made for testing). It looks like the 0 in manual for F2 (depth setting) stays on 0. Tried also with -166 in F2 manual and sub keeps going back to that depth.
The second action works with altitude minus and the moveTo/manAltitude. Tried these also in the first action nut it behaviour stays the same.

Can someone see what I'm doing wrong here.
regards GJ
Attachments
RiserSinkerDepth.rar
Depth preSet
(13.76 KiB) Downloaded 8 times
User avatar
michaelm75au
Posts: 12463
Joined: Sat May 05, 2001 8:00 am
Location: Melbourne, Australia

Re: Depth Setting in Event

Post by michaelm75au »

You have the sub set to 'manual' override, so the depth change won't stick.
To preserve the 'manual' depth, use this
ScenEdit_SetUnit({guid=ss1.guid, moveTo=false, manualaltitude='periscope'})
Michael
Parel803
Posts: 962
Joined: Thu Oct 10, 2019 3:39 pm
Location: Netherlands

Re: Depth Setting in Event

Post by Parel803 »

Micheal,

Thanks for your time and help.

regards GJ
Post Reply

Return to “Lua Legion”