GSHWK_Houndstone_Hawk Posted September 24, 2022 Posted September 24, 2022 Hi. As the title suggests, I'm having issues in getting the AI to finish patrolling and getting to next waypoint. My mission is mp3/jpeg-heavy and too big to post here but I've initially had a low priority waypoint 2 with a Command Attack Area MCU t/linked from it (set to High priority, same altitude as WP, to attack air targets and timing set to 4 minutes). After enemy engagement, they will continually patrol, ignoring the 4 minute time scale (so what good that time scale box is I do not know). So I decided to run an event trigger 'OnKilled' from the enemy AI planes, to a Trigger Counter MCU (number set to correspond to the number of AI enemy), then T/link this counter to a Trigger Deactivate, then in turn, t/link the deactivate to the Command Attack Area MCU. That didn't work. Next I tried replacing the Trigger Deactivate with a Force Complete MCU ('OnKilled' (e/l) from AI enemy -> Trigger Counter (t/l) -> Force Complete, then obj/link to friendly AI. This didn't work. Am I missing something quite obvious? Do i link waypoint 2 from the force complete in someway? Any help as per usual would be great. HH
AEthelraedUnraed Posted September 24, 2022 Posted September 24, 2022 (edited) After a command expires, an entity doesn't automatically revert to its previous command. If you want the aircraft to go to a next waypoint once the 4m AttackArea expires, you should use an OnAreaAttacked message with the waypoint as target. If you want to use other criteria to proceed with the mission, use a Force Complete (as you tried), but follow this up with a 1s timer that links to the next waypoint. To explain, Force Complete cancels whatever command the flight currently had, whether that's an AttackArea, a Waypoint or whatever else. Since a flight can only have one active command, it means it cancels *all* commands. Therefore, you need to give the proper command again after the ForceComplete. The 1s timer makes sure it actually happens afterwards and not 1ms before. Edited September 24, 2022 by AEthelraedUnraed 1 1 1
Monty_Thrud Posted September 24, 2022 Posted September 24, 2022 I use Sketchs command stop works 9/10 times... 2
Jaegermeister Posted September 25, 2022 Posted September 25, 2022 I would recommend this... Spoiler Trigger your attack area as you like. Waypoint, Checkzone, etc. When enemy plane is damaged or killed, use "onDamaged" or "onKilled" to trigger 1 minute timer, giving you enough time to see it go down if PK occurs. You can also use a complex trigger with "FiredRockets" "DroppedBombs", BingoBombs", etc. to trigger the egress if it's a ground attack. 1 minute timer triggers "Deactivate" to command attack area and a 1 second timer 1 second timer triggers Force Complete to Player AC, clearing the Attack Area command from it's AI memory, and another 1 second timer. The last 1 second timer triggers new Waypoint to leave the area. This also works for the Escort Command which is more persistent. Formation commands are not cleared by Force Complete as some have stated. This always works unless there is a temporary AI bug. The only down side is that you get a radio message saying "Return to formation and resume the mission" from the Force Complete command 1
GSHWK_Houndstone_Hawk Posted September 25, 2022 Author Posted September 25, 2022 9 hours ago, Jaegermeister said: I would recommend this... Reveal hidden contents Trigger your attack area as you like. Waypoint, Checkzone, etc. When enemy plane is damaged or killed, use "onDamaged" or "onKilled" to trigger 1 minute timer, giving you enough time to see it go down if PK occurs. You can also use a complex trigger with "FiredRockets" "DroppedBombs", BingoBombs", etc. to trigger the egress if it's a ground attack. 1 minute timer triggers "Deactivate" to command attack area and a 1 second timer 1 second timer triggers Force Complete to Player AC, clearing the Attack Area command from it's AI memory, and another 1 second timer. The last 1 second timer triggers new Waypoint to leave the area. This also works for the Escort Command which is more persistent. Formation commands are not cleared by Force Complete as some have stated. This always works unless there is a temporary AI bug. The only down side is that you get a radio message saying "Return to formation and resume the mission" from the Force Complete command This is wonderful sir and just what I was looking for. Thank you so much once again for your time & efforts. Very much appreciated indeed. ? 1
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