Frequent_Flyer Posted November 23, 2016 Posted November 23, 2016 I have checked off for "AI to return to base decisions when 50% damaged ", this does nothing. Additionally, I have tried adding an event "on Damage " linking it to the command land. This does not work either Any help would be appreciated, thank si nadvance.
JimTM Posted November 23, 2016 Posted November 23, 2016 (edited) Place an airfield object on a runway at the point that you want the plane to stop after landing, orient the airfield object in the landing direction, and set the country to the country of the plane. You can place multiple airfield objects around the map if you like and the plane returns to the nearest friendly one. Edited November 23, 2016 by JimTM
Frequent_Flyer Posted November 24, 2016 Author Posted November 24, 2016 Prangster describes this is his tutorial However, his method does not work as i mentioned.
Frequent_Flyer Posted November 24, 2016 Author Posted November 24, 2016 Place an airfield object on a runway at the point that you want the plane to stop after landing, orient the airfield object in the landing direction, and set the country to the country of the plane. You can place multiple airfield objects around the map if you like and the plane returns to the nearest friendly one. Where are the " airfield objects " located within the ME ?
JimTM Posted November 24, 2016 Posted November 24, 2016 Where are the " airfield objects " located within the ME ? Look in the "Airfields" category in the Objects library (where you choose the Planes object). Use a fakefield or fakefield_rnwspawn airfield object.
Felix58 Posted November 24, 2016 Posted November 24, 2016 (edited) One of the problems when testing this is when is the plane damaged 50%? Use fakefield to designate an airfield - enter direction of runway. Place a command Land where the plane touches down. Use a waypoint for the approach marker. For testing I set the plane damage report to 25%, AI return to base decision on. I used begin mission - Trigger activate - to spawn the plane. From begin mission another timer 15 sec, then to command Damage - Major. So 15 sec after spawning the plane will be damaged and will then land. Needs a little more testing to confirm the onDamage. Set Damage threshold to 1 so you only have to lightly damage it. Then bail out, I think even on Low the AI will prefer to attack the enemy. https://www.dropbox.com/sh/bg5fx1peif91tcr/AAC43Gtn864KBiFMQENpgyLsa?dl=0 Edited November 24, 2016 by Fel1x
Frequent_Flyer Posted November 24, 2016 Author Posted November 24, 2016 Thanks Gentlemen, JimTM and Fel1x I will work on this as suggested.
JimTM Posted November 24, 2016 Posted November 24, 2016 (edited) One of the problems when testing this is when is the plane damaged 50%? The OnPlaneCriticalDamage event detects 50% damage or more. Use fakefield to designate an airfield - enter direction of runway. Place a command Land where the plane touches down. Use a waypoint for the approach marker. You don't need the waypoint and the land command, just the airfield object placed on the runway and pointed in the landing direction. The AI RTB function takes care of flying to the field and landing automatically (after doing a wide circuit of the field, which also occurs with the land command). However, maybe I am missing something extra that your mission provides. ... Edited November 24, 2016 by JimTM
Frequent_Flyer Posted November 27, 2016 Author Posted November 27, 2016 One of the problems when testing this is when is the plane damaged 50%? The OnPlaneCriticalDamage event detects 50% damage or more. Use fakefield to designate an airfield - enter direction of runway. Place a command Land where the plane touches down. Use a waypoint for the approach marker. You don't need the waypoint and the land command, just the airfield object placed on the runway and pointed in the landing direction. The AI RTB function takes care of flying to the field and landing automatically (after doing a wide circuit of the field, which also occurs with the land command). However, maybe I am missing something extra that your mission provides. ... Neither method works. The AI are poorly programmed. Nearly every mission in SP ends up a low altitude with the aircraft chasing each others tail in a circle. The damaged aircraft will just lose altitude and crash into tress etc. They do not attempt to disengage and return to base.
JimTM Posted November 27, 2016 Posted November 27, 2016 Neither method works. The AI are poorly programmed. Nearly every mission in SP ends up a low altitude with the aircraft chasing each others tail in a circle. The damaged aircraft will just lose altitude and crash into tress etc. They do not attempt to disengage and return to base. Can you post your mission that uses just the AI RTB (i.e, no land command or waypoint) please.
Felix58 Posted November 27, 2016 Posted November 27, 2016 IMHO it is in the coding of the AI. Up to date, the main complaint has been about AI not attacking. So I imagine the devs have adjusted AI behaviour to be more likely to engage, which is more preferable than not! Hence my comment, you will have to bailout so the AI can go to the next level of behaviour, which as we program is return to base if damage is greater than X, as far as testing the OnDamage/OnPilotWounded function. Hence why I used cmdDamage to test RTB - I put the player plane on the same side so the AI would not try to attack. It would be nice if there was a priority for this function - so we can set High for RTB if pilot wounded (ie over-ride other behaviour if this happens). I tend to think that AI programming is one of the more difficult aspects for the devs, and for a small team it is always going to be problematic. I have experienced the scenario you described re low alt. Only way out of this is to ensure you start high and maintain an energy advantage and break off if you are loosing energy and live to fight another day. 1
Frequent_Flyer Posted November 29, 2016 Author Posted November 29, 2016 Can you post your mission that uses just the AI RTB (i.e, no land command or waypoint) please. Jim, you must use a last way point and the" command land' otherwise the undamaged AI aircraft will not return to base and land after their bomb run. They simple circle the command attack waypoint for eternity. I use the RTB and list the aircraft in the mission as well with the " fakefield ". 1
JimTM Posted November 30, 2016 Posted November 30, 2016 Jim, you must use a last way point and the" command land' otherwise the undamaged AI aircraft will not return to base and land after their bomb run. They simple circle the command attack waypoint for eternity. I use the RTB and list the aircraft in the mission as well with the " fakefield ". Ah, I understand now. Thanks.
JimTM Posted November 30, 2016 Posted November 30, 2016 (edited) I created a mission that demos the RTB after damage. You can edit it to demo a normal RTB. In the attached test mission, you are in an FW190 near an AI He111 on it's way to a waypoint. 20 seconds after the mission starts, minor damage is applied to the He111 every 2 seconds until it is critically damaged (50% or more damage). The plane then RTBs to the nearest airfield object (at Yantar) and lands automatically. If you remove the object link from the damage command to the He111, the bomber flies to the waypoint and then to the next waypoint off the end of the runway. The He111 then receives the command to land. Note that the waypoints are also object linked to the your plane so that you see the next one along as a yellow teardrop symbol. JimTMTestAIRTBDecision3.zip Edited November 30, 2016 by JimTM
TP_Jacko Posted November 30, 2016 Posted November 30, 2016 I created a mission that demos the RTB after damage. You can edit it to demo a normal RTB. In the attached test mission, you are in an FW190 near an AI He111 on it's way to a waypoint. 20 seconds after the mission starts, minor damage is applied to the He111 every 2 seconds until it is critically damaged (50% or more damage). The plane then RTBs to the nearest airfield object (at Yantar) and lands automatically. If you remove the object link from the damage command to the He111, the bomber flies to the waypoint and then to the next waypoint off the end of the runway. The He111 then receives the command to land. Note that the waypoints are also object linked to the your plane so that you see the next one along as a yellow teardrop symbol. JimTMTestAIRTBDecision3.zip Interesting I see how the damage command is activated with the flip flop action between the timers. I expected to see a timer to give a slight delay to fire the runway line up WP. Maybe its not needed for waypoints now.
Frequent_Flyer Posted December 4, 2016 Author Posted December 4, 2016 I created a mission that demos the RTB after damage. You can edit it to demo a normal RTB. In the attached test mission, you are in an FW190 near an AI He111 on it's way to a waypoint. 20 seconds after the mission starts, minor damage is applied to the He111 every 2 seconds until it is critically damaged (50% or more damage). The plane then RTBs to the nearest airfield object (at Yantar) and lands automatically. If you remove the object link from the damage command to the He111, the bomber flies to the waypoint and then to the next waypoint off the end of the runway. The He111 then receives the command to land. Note that the waypoints are also object linked to the your plane so that you see the next one along as a yellow teardrop symbol. JimTMTestAIRTBDecision3.zip JimTM, Thank you, this was helpful.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now