Jump to content
Sign in to follow this  
Fortran

Landing AutoPilot Engaged ?

Recommended Posts

Does anybody know if there is a method to tell if the landing autopilot has been engaged ? I know the system itself is hardcoded so it not possible to create any additional actual AutoPilot functionality (as far as I know) but I do want to illuminate the AP panel switches when the landing autopilot has been turned on. Is this possible?.

Share this post


Link to post
Share on other sites

Hi Kju, many thanks mate, had already had a look at this but just can't seem to find a way to remove the default landing auto pilot action from the planes action menu. Following in Rock's suggestion for removing the flaps command I have tried (in config.cpp);

land = 0;

landing = 0;

autopilot = 0;

landingautopilot = 0;

and a whole host of others but nothing seems to remove it. If I can remove the landing AP from the action menu then I will most certainly use that method. Thanks for your help.

Share this post


Link to post
Share on other sites

Now worries. :)

There is config option for the unit class from what I found.

You can only disable the autopilot user action altogether for every and make your own

scripted system for your unit and the others.

Share this post


Link to post
Share on other sites

Ah wow thats bad news. You mean I would have to replace the landing AP with a scripted "Action" version for every "plane" class if I removed it in the way you described ? Im surprised there is no way to remove it in the individual config for the actual aircraft, if its possible to remove flaps from the actionMenu there should (hopefully) be a way to remove autopilot ? If there is really no way without replacing all the plane classes with a scripted action I might try creating a scripted "monitor" for AP instead by checking if the plane is in motion or at altitude and there is no player key input perhaps. Anyway many thanks Kju, really appreciate your help.

Edited by Fortran

Share this post


Link to post
Share on other sites

Well it sounds more complicated than it is.

For an experienced scripter it is probably 1-2 hour work. :)

Share this post


Link to post
Share on other sites

I don't mind using the config approach, im just wondering if there is any negative side-effects to having one running for each and every plane class in terms of multiplayer for the sake of one new vehicle, especially when its only to light up 2 textures on a cockpit panel. Might see if I can get the script running I described in the other post first, if that doesn't suffice then I will go with the config changes for all plane classes. Do you mind sharing the line that is required to remove "Landing Auto Pilot" from the plane class in the config if I do decide to go with that method ? I can quite happily sit and write out all the configs and the new addaction for the scripted AP but how to remove one of the standard action menu items ? Thanks Kju, been a huge help with this mate.

Share this post


Link to post
Share on other sites

Well you would replicate basically what the engine does I think.

getIn a plane type vehicle => addAction "autolanding"

if activated, do call action land, add action entry "cancel autolanding"

on "canel autolanding", cal action cancel land, add action entry "autolanding"

if vehicle destroyed or unit no longer in the vehicle, remove the action again

Share this post


Link to post
Share on other sites

You can remove the standard item (globally) with:

class CfgActions {

/*extern*/ class None;

class Land: None {
	show = 0;
};

};

Share this post


Link to post
Share on other sites

Thanks very much guys, will give this a go and report back. Thanks for the help.

Share this post


Link to post
Share on other sites

Haven't gotten it to work. Fortran, did you succeed?

Sorry for bump

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×