View Full Version : Detecting auto pilot
Colonel_Klink
Feb 16 2003, 08:28
Ok guys, anyone out there know how to detect when an aircraft (player as pilot) is in auto pilot landing mode?
Try is it working with action condition. I mean "player action [ACTIONNAME]" as condition .
Colonel_Klink
Feb 17 2003, 08:39
</span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Quote </td></tr><tr><td id="QUOTE">Try is it working with action condition. I mean "player action [ACTIONNAME]" as condition .[/QUOTE]<span id='postcolor'>
Yeah its the built in auto pilot land action. I have a custom action for the gear on my planes that overirides the usual gear actions, which means the auto pilot actions dont operate the gear. So if I can detect when the auto pilot is on/off i can script in the gear animations.
jacobaby
Feb 17 2003, 11:32
Ive had a kwik look at this and nothing springs to mind except a workaround.
This could be a script which waits until the plane's altitude is (<min height) and speed is (<max speed) and animationphase of gear is up.
And then a visible or audible warning to manually lower the gear? And maybe a forced lowering if the height is really low?
Or is it possible to remove the Autolanding option and add it again as your own addaction with extra parameters?
I just tested this and if you can remove the standard "autoland" action then your script can do whatever you need to pop the gear down, just using the action ["land"] and the extra lines.
Im afraid I dont know how to rmove the default action in the list or to modify its effects.
TJ
I may be looking into this too.Have you tried :
? _plane "landing autopilot" == true
or anything like that?
Colonel_Klink
Feb 18 2003, 07:52
</span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Quote (jacobaby @<hidden> Feb. 17 2003,13:32)</td></tr><tr><td id="QUOTE">Ive had a kwik look at this and nothing springs to mind except a workaround.
This could be a script which waits until the plane's altitude is (<min height) and speed is (<max speed) and animationphase of gear is up.
And then a visible or audible warning to manually lower the gear? And maybe a forced lowering if the height is really low?
Or is it possible to remove the Autolanding option and add it again as your own addaction with extra parameters?
I just tested this and if you can remove the standard "autoland" action then your script can do whatever you need to pop the gear down, just using the action ["land"] and the extra lines.
Im afraid I dont know how to rmove the default action in the list or to modify its effects.
TJ[/QUOTE]<span id='postcolor'>
At the mopment I am using a gearup/geardown script based on the altitude and speed, however the gears go up and down automatically whenever the plane takes off and lands regardless of the autopilot, player or AI pilots. I guess this is a workaround, but it overides the Player manually lowering raising the gear. I have tried killing the autopilot action, but have been unsuccessful. Detecting when the autopilot is engaged would be the perfect solution still, though.
I guess we'll keep experiemnting.
jacobaby
Feb 18 2003, 10:12
I wonder if there is an array of variables attached to the objects/vehicles that we could tap into.........
Failing that, (and bearing in mind I know nothing much about cpp's etc) do you have the gear as "retractable" for the plane?
I guess that is what makes it have the "gear up" and "gear down" option in the command menu.
If your "gear" affected by that was invisible, so no effect was seen, you could then use Animataion phase to lower or raise the gear as needed, and it would work with autolanding too.
But I guess that fully depends on whether you can seperate the "gearRetracting= 1" to affect only an invisible item???
Hmm, so much to learn, so little time.........
TJ
Colonel_Klink
Feb 28 2003, 04:50
Hmm the problem still exists. I guess the hardcoding of the auto pilot makes this harder to detect.
Powered by vBulletin® Version 4.2.0 Copyright © 2013 vBulletin Solutions, Inc. All rights reserved.