Script Functionality
This section covers the basic functionality of AGHTM and discusses what happens at each stage of the mission lifecycle. At a high level, the framework does the following:
On Mission Start
- Creates the NAV radio beacons as specified in the configuration file. By
default, beacons are created in VHF AM, VHF FM, UHF AM, UHF FM so they can be
used for Radio Navigation where applicable (ie FM Radio with Homing Mode,
ARC-9, ARC-15, ARC-UD with R828 Radio, etc). The default values will create
frequencies which only require one click of a radio knob to increment them to
the next waypoint. ie 34.1, 34.2, 34.3 etc where the digit that changes
represents the alphanumeric position of the location in your flight plan. ie
1 = Alpha, 2 = Bravo, etc so they are easy to set as you follow the route.
- Provides instructions for how to fly the mission with voiceovers
- Tells the user to start the aircraft and proceed to the first pickup
On Entering a Pickup Location Trigger Zone
- Checks to ensure you are in the correct pickup location trigger zone and
tracks pickups accordingly.
- Adds a radio menu button to allow the user to signal their approach. Each
stage uses the provided audio files to provide some immersion to the
experience.
On Leaving a Pickup Location Trigger Zone (any point prior to signaling Pickup)
- Removes the radio menu button that allows the user to signal their
approach.
On Signal Approach
- Removes the radio menu button that allows the user to signal their
approach.
- Plays an audio voiceover announcing the approach
- Adds a radio menu button to allow the user to signal their pickup once landed.
On Signal Pickup
- Removes the radio menu button that allows the user to signal their
pickup.
- Plays an audio voiceover announcing the pickup and requesting departure
clearance, followed by a confirmation and departure clearance
- Adds an arbitray amount between 120 and 220 lbs (70-100 KG) to the
helicopter's cargo weight, making the aircraft heavier as pickups are made,
and causing fuel to be burned more accurately.
- Increments the current step in the mission (ie what pickup location am I
currently supposed to be on)
On Final Landing at Destination
- Checks that you have made all other pickups
- Checks that you are in the Landing Zone specified
-
Waits 10 seconds to make sure the landing isnt cancelled and the user
actually landed and is settled and stable on the helipad. Landing will be
cancelled by Crash, Dead, Takeoff, and several other events that are
captured. So you can't just crash into the final helipad, win the mission and
call it a day because you "touched the ground" at the right location.
Landing Cancellation Codes:
The following event codes thrown by the player will cancel the landing (Additional codes will be added as needed):
- Event Code 3: Takeoff
- Event Code 5: Crash
- Event Code 6: Ejection
- Event Code 8: Dead
- Event Code 9: Pilot Dead
- Event Code 20: Player Enter Unit
- Event Code 21: Player Leave Unit
- Plays an audio voiceover welcome back message, ending with telling you to
shut down. Once you have shut down the aircraft, the mission automatically
ends in 30s, giving you time to grab some screenshots or whatever.