Jump to content

[MOOSE] RAT - Random Air Traffic


Recommended Posts

Hi,

 

This version works great, thanks a lot.

 

I was just trying C-130 before using the example as explained in the second video.

 

Cheers,

Vincent

IAMD Ryzen 9 5900X 12x 3.7 to 4.8Ghz - 32Go DDR4 3600Mhz - GeForce RTX 3080 - Samsung Odyssey G7 QLED - AIMXY

Link to comment
Share on other sites

Hi,

 

Just to report this problem, but I supposed you know. The spawning point is not always a good one, see on the picture the C-130 at Creech AFB. Obviously, the aircraft disappear as soon as it start taxi.

 

The solution is to place an aircraft at the same spawn point, and the script will find another one.

 

Cheers,

Vincent

Screen_190102_181617.png.fd03a57af56c7266e3093c5f24eb93f8.png


Edited by vctpil

IAMD Ryzen 9 5900X 12x 3.7 to 4.8Ghz - 32Go DDR4 3600Mhz - GeForce RTX 3080 - Samsung Odyssey G7 QLED - AIMXY

Link to comment
Share on other sites

Just to report this problem, but I supposed you know. The spawning point is not always a good one, see on the picture the C-130 at Creech AFB. Obviously, the aircraft disappear as soon as it start taxi.

Yeah, I know. There is one other solution except the one you found. You can specify the "terminal type" so that it at least would not be spawned under open shelters:

c17=RAT:New("C-17 BIG Plane")
c17:SetTerminalType(AIRBASE.TerminalType.OpenBig) -- Only very big parking spots are used.
c17:Spawn(5)

This does not always work since for some parking spots the terminal type returned by the DCS API is incorrect. But it is definitely worth a shot :)

 

Note that with this setting, only departure airports are allowed, which actually have at least one "big" parking spot.

A warrior's mission is to foster the success of others.

i9-12900K | MSI RTX 3080Ti Suprim X | 128 GB Ram 3200 MHz DDR-4 | MSI MPG Edge Z690 | Samung EVO 980 Pro SSD | Virpil Stick, Throttle and Collective | MFG Crosswind | HP Reverb G2

RAT - On the Range - Rescue Helo - Recovery Tanker - Warehouse - Airboss

Link to comment
Share on other sites

Hi,

 

Is it possible to have several type of aircraft spawning on the same .lua file ? I have tried this one, the C130 appears, but not the F-15 ?

 

local C130=RAT:New("RAT_C130")

C130:SetDeparture("Creech AFB")

C130:SetDestination("Nellis AFB")

C130:Spawn(1)

 

local F15=RAT:New("RAT_F15")

F15:SetDeparture("Tonopah Test Range Airfield")

F15:SetDestination("Nellis AFB")

F15:Spawn(1)

 

Maybe I missed something in the code ?

 

Thanks,

Vincent

IAMD Ryzen 9 5900X 12x 3.7 to 4.8Ghz - 32Go DDR4 3600Mhz - GeForce RTX 3080 - Samsung Odyssey G7 QLED - AIMXY

Link to comment
Share on other sites

Yeah, that's a DCS thing. Any time you change a lua file, you need to do the LUA dance. FlightControl built a way into MOOSE so you can "dynamic" load while testing, but, and I may be wrong here, at the end, when you are done, you have to pull all the dynamic stuff out and load the actual MOOSE lua along with any luas you built. I just use the dance ;) it's easy and fast, if a bit annoying at times.

 

You'd think it would be easy to tell the ME, when you save the miz file, THEN you load the current version of that lua into it, not BEFORE. But, I don't know how it works, maybe that's the only way to do it

B. "Swany" Swanberg

Gigabyte Designare, Intel i9 9900KF (3.6, OC'd to 5.0)

32GB Patriot Viper Steel (black, non-RGB)

OS installed on a Samsung Evo 970 1TB SSD

DCS installed on a Samsun Evo 860 1TB SSD

EVGA 2080Ti 11GB

EVGA Supernova 720p 750w PS

3 Dell S2716DG monitors in Surround mode (7680x1440)

Oculus Rift S VR

Thrustmaster Warthog Throttle and Stick

Thrusmaster Rudder Pedals

assorted button boxes/Arduino boards

All drivers always kept up to date (30 days old, max)

Link to comment
Share on other sites

One problem I've been having is that sometimes the RAT aircraft spawns on a ramp position already occupied, like this:

 

AwwxoHe.jpg

 

YjCO980.jpg

 

Z3PbZIZ.jpg

 

@FunkyFranky, can you add a check condition on the script so as to avoid this? .. it seems to happen only with helicopters. Thanks a lot, and wonderful script ... I'm using it on almost all my missions.

 

For work: iMac mid-2010 of 27" - Core i7 870 - 6 GB DDR3 1333 MHz - ATI HD5670 - SSD 256 GB - HDD 2 TB - macOS High Sierra

For Gaming: 34" Monitor - Ryzen 3600X - 32 GB DDR4 2400 - nVidia GTX1070ti - SSD 1.25 TB - HDD 10 TB - Win10 Pro - TM HOTAS Cougar - Oculus Rift CV1

Mobile: iPad Pro 12.9" of 256 GB

Link to comment
Share on other sites

DCS API scripting especially for everything around airports is kind of piss poor so its probably a DCS bug that Funky can't fix.

 

 

Since it hasn't happened to me when using RAT with civil planes or military jets, only with helicopters ... I believe that the likely cause isn't the piss poor API :)

 

For work: iMac mid-2010 of 27" - Core i7 870 - 6 GB DDR3 1333 MHz - ATI HD5670 - SSD 256 GB - HDD 2 TB - macOS High Sierra

For Gaming: 34" Monitor - Ryzen 3600X - 32 GB DDR4 2400 - nVidia GTX1070ti - SSD 1.25 TB - HDD 10 TB - Win10 Pro - TM HOTAS Cougar - Oculus Rift CV1

Mobile: iPad Pro 12.9" of 256 GB

Link to comment
Share on other sites

Rudel, can you share your script when this happens? Maybe I can give a few tips how to avoid that.

 

What MirabelleBenou said is a good point! Additionally, you can try SetTerminalType(AIRBASE.TerminalType.HelicopterOnly) for the helos. But not all airports have special helo spots.

 

To explain, the script should check, if parking spot is already occupied and not use it. However, if two aircraft are spawned exactly at the same time, the first one is not in the game so that both "think" the spot is free and they land on top of each other. Therefore, one can also play around with the spawning delays and intervals to de-conflict the situation.

A warrior's mission is to foster the success of others.

i9-12900K | MSI RTX 3080Ti Suprim X | 128 GB Ram 3200 MHz DDR-4 | MSI MPG Edge Z690 | Samung EVO 980 Pro SSD | Virpil Stick, Throttle and Collective | MFG Crosswind | HP Reverb G2

RAT - On the Range - Rescue Helo - Recovery Tanker - Warehouse - Airboss

Link to comment
Share on other sites

Rudel, can you share your script when this happens? Maybe I can give a few tips how to avoid that.

 

Sure .. here I'm ataching my parameter script, and a Mission where it is used (tough the mission is for the C-101 and uses the VPC Airfield Scenery Mod, so I'm not sure if you will be able to run it).

 

Therefore, one can also play around with the spawning delays and intervals to de-conflict the situation.

 

Dont know how to specify these delays.

 

Also, please keep in mind that with civil aircrafts I have never seen this happen, and now, everytime thay happen, there is an helo involved :(

M01 RAT.lua

C101CC - M01 - Startup, Taxi, Take Off & Landing (by Rudel_chw).miz

 

For work: iMac mid-2010 of 27" - Core i7 870 - 6 GB DDR3 1333 MHz - ATI HD5670 - SSD 256 GB - HDD 2 TB - macOS High Sierra

For Gaming: 34" Monitor - Ryzen 3600X - 32 GB DDR4 2400 - nVidia GTX1070ti - SSD 1.25 TB - HDD 10 TB - Win10 Pro - TM HOTAS Cougar - Oculus Rift CV1

Mobile: iPad Pro 12.9" of 256 GB

Link to comment
Share on other sites

Hi,

 

The commute function seems not working as shown on the video.

 

local C130=RAT:New("RAT_C130")

C130:SetDeparture("Nellis AFB")

C130:SetDestination("Creech AFB")

C130:Commute()

C130:Spawn(3)

 

Three aircrafts are flying to Creech but does not come back to Nellis. I have tried C130:Commute(6), but it is not working.

 

Any idea ?

 

Thanks,

Vincent

IAMD Ryzen 9 5900X 12x 3.7 to 4.8Ghz - 32Go DDR4 3600Mhz - GeForce RTX 3080 - Samsung Odyssey G7 QLED - AIMXY

Link to comment
Share on other sites

Ihave tried to setup multiple aircraft as in the .lua file but only the first c130s will work. what am i doing wrong?

 

fa18:[b][color="Red"]c[/color][/b]ommute()

Commute needs to start with a capital "C". You got it right for the C-130 but lower case for the F-18 and the Huey. Lua is case sensitive. So this crashes the script.

A warrior's mission is to foster the success of others.

i9-12900K | MSI RTX 3080Ti Suprim X | 128 GB Ram 3200 MHz DDR-4 | MSI MPG Edge Z690 | Samung EVO 980 Pro SSD | Virpil Stick, Throttle and Collective | MFG Crosswind | HP Reverb G2

RAT - On the Range - Rescue Helo - Recovery Tanker - Warehouse - Airboss

Link to comment
Share on other sites

Hi,

 

I have corrected the syntax, but this one is still not working.

 

local C130=RAT:New("RAT_C130")

C130:SetDeparture("Nellis AFB")

C130:SetDestination("Creech AFB")

C130:commute()

C130:Spawn(3)

 

By the way, the C in the video is in capital.

 

Vincent

 

Edit : If the "c" is in small letter, the C-130 does not appears.


Edited by vctpil

IAMD Ryzen 9 5900X 12x 3.7 to 4.8Ghz - 32Go DDR4 3600Mhz - GeForce RTX 3080 - Samsung Odyssey G7 QLED - AIMXY

Link to comment
Share on other sites

Hi,

 

I have corrected the syntax, but this one is still not working.

 

local C130=RAT:New("RAT_C130")

C130:SetDeparture("Nellis AFB")

C130:SetDestination("Creech AFB")

C130:commute()

C130:Spawn(3)

 

By the way, the C in the video is in capital.

 

Vincent

 

Edit : If the "c" is in small letter, the C-130 does not appears.

 

Hi Vincent! Sorry, my reply was aimed at Seance12, who had "Commute" with a lower case "c".

Your script with the capital "C" is correct.

 

You actually have another issue. Believe it or not, a C-130 is too big for Creech AFB.

 

It has nothing to do with RAT, it is a DCS setting. You can try to place a C-130 to takeoff from ramp at Creech AFB and you will see that it snaps to another airbase.

A warrior's mission is to foster the success of others.

i9-12900K | MSI RTX 3080Ti Suprim X | 128 GB Ram 3200 MHz DDR-4 | MSI MPG Edge Z690 | Samung EVO 980 Pro SSD | Virpil Stick, Throttle and Collective | MFG Crosswind | HP Reverb G2

RAT - On the Range - Rescue Helo - Recovery Tanker - Warehouse - Airboss

Link to comment
Share on other sites

how do you find the skin names (for the C130 for example) to use in the randomize script?

 

RAT uses the folder name of each skin folder as the skin name ... thus, these Airbus A320 liveries:

 

DJp7996.jpg

 

are specified on the script as:

 

local a320skins={"airarabia", "Air Asia", "Air Canada", "Air France", "Al Maha", "Alitalia", "American Airlines", "BRD", "British Airways", "Egyptair", "Easy Jet", "Easy Jet Berlin", "Easy Jet w", "Edelweiss", "Emirates", "Etihad", "Gulf Air", "Iberia", "Iran Air", "Islamic Republic", "Jazeera", "Kish Air", "KLM", "KLM WiFi", "Kuwait Airways", "LAN", "Lufthansa", "Lufthansa New", "MEA", "Nesma", "Nile Air", "Qatar", "SAS", "Saudi Gulf", "Saudia", "SWISS", "Tunis Air", "Turkish Airlines", "UAE", "United"}

 

(didn't specify every livery, as this is a sample from a Persian Gulf Mission and I wanted only a few well known airlines, plus those from the Middle East)

 

Edit: Just realized that my Liveries folder shown above doesnt contain every available A320 livery ... there are also more liveries included within the aircraft's folder, like this:

 

MnhjD2c.jpg

 

:)


Edited by Rudel_chw
  • Thanks 1

 

For work: iMac mid-2010 of 27" - Core i7 870 - 6 GB DDR3 1333 MHz - ATI HD5670 - SSD 256 GB - HDD 2 TB - macOS High Sierra

For Gaming: 34" Monitor - Ryzen 3600X - 32 GB DDR4 2400 - nVidia GTX1070ti - SSD 1.25 TB - HDD 10 TB - Win10 Pro - TM HOTAS Cougar - Oculus Rift CV1

Mobile: iPad Pro 12.9" of 256 GB

Link to comment
Share on other sites

I cannot find the folder for any of the default aircraft in DCS.

 

 

try \Program Files\Eagle Dynamics\DCS World OpenBeta\Bazar\Liveries\C-130

 

For work: iMac mid-2010 of 27" - Core i7 870 - 6 GB DDR3 1333 MHz - ATI HD5670 - SSD 256 GB - HDD 2 TB - macOS High Sierra

For Gaming: 34" Monitor - Ryzen 3600X - 32 GB DDR4 2400 - nVidia GTX1070ti - SSD 1.25 TB - HDD 10 TB - Win10 Pro - TM HOTAS Cougar - Oculus Rift CV1

Mobile: iPad Pro 12.9" of 256 GB

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...