GREG - Random Air Battles

Home > User Files > GREG - Random Air Battles
DCS: World 2.5
F/A-18C Hornet
GREG - Random Air Battles

GREG - Random Air Battles

Author - Ltp0wer
Date - 01.12.2019 01:24
GREG Random Air Battles (WIP)

Supporting the F-14, F-15, F-16, F/A-18, Mig-29, Su-27, Su-33, J-11, Viggen, Mirage, F-5, and Mig-21.

Want to practice air to air combat but can't decide which plane to fly?
Greg will decide for you.

Are you sick of shuffling the planes around in your tired, old "practice3.miz" file to feel some freshness?
Greg will handle the planes and where they are, you just worry about flying.

1) Open this mission in the mission editor and delete the aircraft you don't own.
2) Start the mission and select the "RANDOM" Su-25t role on the RED side.

Within seconds, you will be flying a random aircraft in a random battle.
Greg will spawn all units, INCLUDING YOU, at random speeds and altitudes, after the mission has loaded.

You can easily flip between flying random aircraft to flying your favorite again and again against random targets to really hone your skills.

How does is it work:
    Greg will generate groups of planes for each side inside the two zones called "blue_spawn" and "red_spawn".
    These groups will be assigned waypoints heading toward their coalition's bullseye.
    Move the bullseyes around to change the respective side's target destination.
    Move the zones around or change the size of them to control where the planes spawn.
    To start, the zones are placed at different ends of the map for random, hot vs hot bvr engagements.
    For a greater challenge, put both zones and both bullseyes all on the same exact spot.
    Friendlies and enemies will spawn all amongst each other.
    You can find the AI with your RWR. If you're having trouble, play around with the zone sizes until you find a good balance.
    AWACs will randomly be available. Typically on 230mhz and on preset channel 2 in most aircraft.

*Sel ect Random Player Aircraft:
    Greg can't figure out what the player owns, so he scans the map for flyable aircraft that are set to "late activation" to add to the player's plane list.
    He can't scan aircraft set to "Client" so I needed to place AI aircraft for him in the mission.
    FOR THE RANDOM PLAYER AIRCRAFT TO WORK, you need to delete the aircraft you don't own or don't want to fly in the mission editor.

    To select the random player aircraft option after starting the mission, choose the Su-25T role labelled "RANDOM" on the red side.
    Once loaded, you'll be in a Su-25t and the first scripts will load, setting up Greg.
    Then the main Greg script will load. Your system will hang for a period of time 5 to 20 seconds, depending on how many units you're spawning and how powerful your PC is.
    Then you will be in one of the allowed player aircraft ready for battle!
    I want to make it so more enemies are added automatically if you defeated the first "wave", I think.
    and conversely, I want to respawn the player if they are killed, maybe even restart the whole mission.

For Nerds/Deeper customization:
    Greg consists of 3 prep/settings scripts and a main script. You can find them on the triggers page in the mission editor.
    The first script, "(--DON'T EDIT---)", is where all the aircraft and other things are defined. Editing this is a bit complicated and won't be covered.

    The second, "(--EDIT LISTS---)", contains various aircraft, mission, and spawn type lists for each side and player.
    One looks like this:
        blue_aircraft_types =
            --(etc, etc...)
    To disable an aircraft fr om the blue spawn pool, you would add an "--" in front of the aircraft you want to disable.
    In the above list for the blue team, only F-14Bs and F-15Cs will spawn.
    Below the aircraft_types lists on the same (--EDIT LISTS) script, you will also see the three mission_types lists. Again, use two dashes "--" in front of the mission type to deactivate it.
    For example, if you only want Fighter Sweep missions for the red team, your red_mission_types list would look like:
        red_mission_types =
            "Fighter Sweep",
    Greg can spawn ground units, but it's very rudimentary. Anything other than Fighter Sweep or CAP might not produce the best experience.
    At the bottom of the same (--EDIT LISTS) script, you will also see three start_types lists. Once more, use the dashes to disable a start type.
    For example, if you only want aircraft to spawn in the air or hot on the runway for the red team, your red_start_types list would look like:
        red_start_types =
            "turnpoint", --NOTE: this is in the air spawn
    Another note, to enable airbase spawning (everything but "turnpoint"), airbases need to be set in the mission editor for the coalitions needing bases to spawn at.
    Click on the name of an airbase in the mission editor and set the coalition to the side you want.
    The third DO SCRIPT, "(--SETTINGS)", contains all the settings for Greg. There are two sets of identical settings. 1 for the blue/blue side and 1 for the red.
    It looks like this:
    disable_player = false --If you want to setup the player yourself in the mission editor, change this to true. Greg won't spawn you into a new aircraft.
    player_side = "random" --Change to "blue" or "red" if you want to be on a specific team.
    guns_only = 0 --with 1, both sides are limited to built in guns only. Aircraft with gunpods on pylons/weapon slots won't have them.
    blue_acpergroup_min = 1 --Create at least 1 aircraft in each group/flight
    blue_acpergroup_max = 2 --Create No more than 2 aircraft in each group created. 4 is the maximum for this setting.
    blue_plane_groups_min = 1 --At least 1 blue air group will be created
    blue_plane_groups_max = 2 --No more than 2 blue air groups will be created
    blue_heli_groups_min = 0 --At least 0 blue helicopter groups will be created
    blue_heli_groups_max = 0 --No more than 0 blue helicopter groups will be created
    blue_ground_groups_min = 0 --At least 0 blue ground groups will be created
    blue_ground_groups_max = 0 --At least 0 blue ground groups will be created
    blue_awacs_enabled = -1 --0 is off, 1 is on, anything else is random. I like -1 for no particular reason
    So with all the blue settings above, Greg will generate 1 to 2 flights of 1 to 2 aircraft each of F-14Bs and F-15Cs on Fighter Sweep missions.
    They will spawn anywhere in the blue zone and head to a spot near the blue bullseye.
    AWACS has a 50% chance of spawning.
    GREG Stands for "GREG Random Engagement Generator", and is a project I've had a lot of fun working on the last few months.
    I got inspired to make this because I really enjoyed the F/A-18 BVR 8v8 instant action mission but quickly grew tired of the predictability after playing it a few dozen times.
    I used some sounds provided to the hoggit community by deadlyfishes. He's the guy behind the very popular "Through the Inferno" missions.
    I'd check out his website,, if you haven't heard of it. It's awesome.
    Thanks deadlyfishes!
    This mission is an offshoot of my original GREG mission, "GREG - Gulf Random Engagement Generator", which currently runs a way older version of Greg.
    I wanted to create this mission to focus on air to air combat and increase the testing base by moving to Caucasus.
    It's also a proof of concept showing one possibility of how Greg can be setup.
    I am a novice programmer so I'm sure it's full of bugs, but it's been a blast!
    Let me know what you think!
Change log:
    --Initial release
  • License: Freeware - Free version, Do Not Redistribute
  • Language: English
  • Size: 391.14 Kb
  • Downloaded: 160
  • Comments: 1