Jump to content

"Spawning FARP"


Recommended Posts

Hi. Is it possible to spawn a FARP or make it appear via trigger.

 

I want to create the "building" of a FARP by having a convoy arrive with all the materials supposedly.

 

If possible how would I do this without the use of scripting it? Ideally I want to create a FOB by having a convoy move up the road while a10's etc clear the area and fly escort/support for it then once the FOB is "built" the second phase of the mission can continue. any help would be greatly appreciated.

Link to comment
Share on other sites

Without looking at it right this second, the FARP is just a static object that I'm quite sure you can set to "late activation" once it's placed. At that point you'd just need to activate it when a certain condition had been met (set flag when your convoy of vehicles are in a certain zone.) Then you could just pick a time (10 minutes to set up or whatever) and add a trigger that runs off a "time since flag" and then "unit activate." You could activate all the necessary vehicles, or do them at different intervals using the same principle.

 

Otherwise you could just put the FARP empty in place, and the crews could be "building" the various static structures needed to support flight operations. I'll double check if you can even late activate a structure like that in the ME- but I'm quite certain that you can.

"ENO"

Type in anger and you will make the greatest post you will ever regret.

 

"Sweetest's" Military Aviation Art

Link to comment
Share on other sites

Statics can't be late activated. The only way to do it is to spawn it dynamically with coalition.addStaticObject() but I don't know if it was working in 1.2.4.

The right man in the wrong place makes all the difference in the world.

Current Projects: Scripting Wiki, Something...

Useful Links: Mission Scripting Tools MIST-(GitHub) MIST-(Thread), SLMOD, IADScript, Mission Editing Wiki!, Mission Building Forum

Link to comment
Share on other sites

  • 3 weeks later...

Fuzzy_bear,

I have a mission (iShot The Shilka) where the FARP support gets activated late - but, like mentioned above - the FARP Static Object cannot be late activated (unless you can use a script, hymmm, I may try this) - in my mission the FARP exists from Mission Start, but the support vehicles don't appear until a convoy reaches the zone for each FARP.

 

Also, I am activating helicopter Clients along with the FARP support, so as the convoy goes further down the road, Clients can switch to helicopters that are closer to the objective.

 

WC

Visit the Hollo Pointe DCS World server -- an open server with a variety of COOP & H2H missions including Combined Arms. All released missions are available for free download, modification and public hosting, from my Wrecking Crew Projects site.

Link to comment
Share on other sites

I have used in CTTS script a function to spawn statics. I don´t know if it works with FARPS but the principle is the same (I use it to spawn fuel barrels):

 

 
local static = {

["type"] = "FARP Fuel Depot",
["unitId"] = logcargoCounter,
["y"] = yCenter + yofs,
["x"] = xCenter + xofs,
["name"] = name,
["category"] = "Fortifications",
["heading"] = angle,

}

coalition.addStaticObject(country.id.USA, static)

 

Just set the fields in local static with desired info about the object.

 

Cheers

Windows 10 64bit, i7 5930K OC 4.2 GHz, AMD 295x2, 16 Gb DDR4

Link to comment
Share on other sites

I have used in CTTS script a function to spawn statics. I don´t know if it works with FARPS but the principle is the same (I use it to spawn fuel barrels):

 

 
local static = {

["type"] = "FARP Fuel Depot",
["unitId"] = logcargoCounter,
["y"] = yCenter + yofs,
["x"] = xCenter + xofs,
["name"] = name,
["category"] = "Fortifications",
["heading"] = angle,

}

coalition.addStaticObject(country.id.USA, static)

Just set the fields in local static with desired info about the object.

 

Cheers

 

Just curious...where will this object spawn?

Midnite Signature.jpg

552334314_MidniteSignature.jpg.7c1678ea5639bd6d044b092eb97c300e.jpg

Link to comment
Share on other sites

This is a real interesting concept, I see you were able to find the model name for the FARP Fuel Depot, any idea what the FARP model would be named?

 

The idea would be to spawn a FARP after a certain amount of FARP objects were delivered to a site.

Midnite Signature.jpg

552334314_MidniteSignature.jpg.7c1678ea5639bd6d044b092eb97c300e.jpg

Link to comment
Share on other sites

I have tried a different couple of options with no luck thus far but I think I'm on the right track here..

 

logisticItemModel = "FARP"

local static = {
       ["type"] = objtype,           --NOT sure here--
       ["unitId"] = logcargoCounter,
       ["y"] = yCenter + yofs,
       ["x"] = xCenter + xofs,
       ["name"] = FARP Paris,
       ["category"] = "Heliports",
       ["heading"] = angle,
   }


coalition.addStaticObject(country.id.USA, static)

According to the Wiki:

 

Airbase.Category = { AIRDROME, HELIPAD, SHIP }I did manage to spawn all FARP objects without a problem.

 

EDIT:

Made a mission with only a FARP in it and came up with this:

 

[10] = 
               {
                   ["id"] = 2,
                   ["static"] = 
                   {
                       ["group"] = 
                       {
                           [1] = 
                           {
                               ["heading"] = 0,
                               ["route"] = 
                               {
                                   ["points"] = 
                                   {
                                       [1] = 
                                       {
                                           ["alt"] = 0,
                                           ["type"] = "",
                                           ["name"] = "",
                                           ["y"] = 627201.42857143,
                                           ["speed"] = 0,
                                           ["x"] = -265531.42857143,
                                           ["formation_template"] = "",
                                           ["action"] = "",
                                       }, -- end of [1]
                                   }, -- end of ["points"]
                               }, -- end of ["route"]
                               ["groupId"] = 1,
                               ["units"] = 
                               {
                                   [1] = 
                                   {
                                       ["type"] = "FARP",
                                       ["unitId"] = 1,
                                       ["y"] = 627201.42857143,
                                       ["x"] = -265531.42857143,
                                       ["name"] = "FARP Static Object(mid)",
                                       ["category"] = "Heliports",
                                       ["heliport_modulation"] = 0,
                                       ["heliport_frequency"] = 127.5,
                                       ["heliport_callsign_id"] = 1,
                                       ["heading"] = 0,
                                   }, -- end of [1]
                               }, -- end of ["units"]
                               ["y"] = 627201.42857143,
                               ["x"] = -265531.42857143,
                               ["name"] = "FARP Static Object(mid)",
                               ["dead"] = false,
                           }, -- end of [1]
                       }, -- end of ["group"]
                   }, -- end of ["static"]
                   ["name"] = "USA",
               }, -- end of [10]

 

What confuses me a bit, is it a unit or a static object?

 

Well....the search continues.....


Edited by Midnight

Midnite Signature.jpg

552334314_MidniteSignature.jpg.7c1678ea5639bd6d044b092eb97c300e.jpg

Link to comment
Share on other sites

Copied and Pasted from miz file. When in doubt, add an object to a miz file and for the most part you will get the same data format used by the scripting engine. I say most part because for some reason adding static objects dynamically is a little different from how its formatted in the editor.

     
                                  ["type"] = "FARP",
                                       ["unitId"] = 1,
                                       ["y"] = 651914.28571429,
                                       ["x"] = -292371.42857143,
                                       ["name"] = "New Static Object",
                                       ["category"] = "Heliports",
                                       ["heliport_modulation"] = 0,
                                       ["heliport_frequency"] = 127.5,
                                       ["heliport_callsign_id"] = 1,
                                       ["heading"] = 0,

 

the Airbase class in the scripting engine is simply used to get data on a given object. Basically so you don't tell a B-52 to try and land on the back of a Destroyer.

The right man in the wrong place makes all the difference in the world.

Current Projects: Scripting Wiki, Something...

Useful Links: Mission Scripting Tools MIST-(GitHub) MIST-(Thread), SLMOD, IADScript, Mission Editing Wiki!, Mission Building Forum

Link to comment
Share on other sites

Just curious...where will this object spawn?

 

For my concern, I am building a higly-automated training mission, where players use F10 menu to create all sort of threats, static targets, moving targets, and so on..... and call some support (AWACS and Tanker). All this stuff spawning location is related to the location of the player that did the call. I am also interested into generating FARP... let's imagine that Ka-50 engaged some troops, and need rearming. F10 menu will generate a FARP into the closest zone available for FARP spawing. (I am providing a dictionary of zones for many purposes to be sure that generated ground units won't spawn into dumb areas, coming along with a small text to describe the approximate location)


Edited by galevsky06
Link to comment
Share on other sites

Edited the CTTS script to

 

Line 279

 

logisticItemModel = "FARP"  -- Think my problem lies here, model used to spawn a logistic item

 

and line 628

 

local static = {
       ["type"] = "FARP",
       ["unitId"] = logcargoCounter,
       ["y"] = yCenter + yofs,
       ["x"] = xCenter + xofs,
       ["name"] = "FARP Paris",   --thats the name I gave it--
       ["category"] = "Heliports",
       ["heliport_modulation"] = 0,
       ["heliport_frequency"] = 127.5,
       ["heading"] = angle, --can I leave it like this or should I have a value--
   }

 

It does tell me that a Unit was delivered but does not show the model, quite frankly I would like it better if the model does not spawn, as long as the sim sees it as a FARP and have a frequency.(wich it does not at this time)

Midnite Signature.jpg

552334314_MidniteSignature.jpg.7c1678ea5639bd6d044b092eb97c300e.jpg

Link to comment
Share on other sites

For my concern, I am building a higly-automated training mission, where players use F10 menu to create all sort of threats, static targets, moving targets, and so on..... and call some support (AWACS and Tanker). All this stuff spawning location is related to the location of the player that did the call. I am also interested into generating FARP... let's imagine that Ka-50 engaged some troops, and need rearming. F10 menu will generate a FARP into the closest zone available for FARP spawing. (I am providing a dictionary of zones for many purposes to be sure that generated ground units won't spawn into dumb areas, coming along with a small text to describe the approximate location)

 

Sounds interesting, I am looking forward to your release, I think there is a demand for dynamic training missions now. SNAFU made some interesting script for a training mission where you can see the result of your bomb drops by indicating the distance from target.

 

I really hope he gets time to expand further on that.

  • Like 1

Midnite Signature.jpg

552334314_MidniteSignature.jpg.7c1678ea5639bd6d044b092eb97c300e.jpg

Link to comment
Share on other sites

Sounds interesting, I am looking forward to your release, I think there is a demand for dynamic training missions now. SNAFU made some interesting script for a training mission where you can see the result of your bomb drops by indicating the distance from target.

 

I really hope he gets time to expand further on that.

 

Definitely. I have no work on engagement reporting in my own, but for training purpose..... it sounds just essential. :thumbup:

 

Do you have link to SNAFU script ?

Link to comment
Share on other sites

I am looking for a way to guess which target the unit is engaging. In a dynamic way, not harcoded units to be engaged into the right order.

 

We could simply get the closest ground unit when the ordnance reaches the ground... but if targets are closed, we may consider the wrong one...

 

Or we could use the heading when releasing the ordnance.... with a few +/-degrees , then considering the altitude above ground and the ordnance, we can have a short list or possible targets. May be not sufficient to distinguish each others.

Link to comment
Share on other sites

  • 3 months later...

Has anyone manage to spawn the "FARP Ammo Storage and FARP Command Post" using TTCF script used in the mission TOOTALL_CFT_V1?

There seems to be a problem with the objects name. Looks like the same prob as Midnights.

All help is much appreciated.

 

Edited the CTTS script to

 

Line 279

 

logisticItemModel = "FARP"  -- Think my problem lies here, model used to spawn a logistic item

and line 628

 

local static = {
       ["type"] = "FARP",
       ["unitId"] = logcargoCounter,
       ["y"] = yCenter + yofs,
       ["x"] = xCenter + xofs,
       ["name"] = "FARP Paris",   --thats the name I gave it--
       ["category"] = "Heliports",
       ["heliport_modulation"] = 0,
       ["heliport_frequency"] = 127.5,
       ["heading"] = angle, --can I leave it like this or should I have a value--
   }

It does tell me that a Unit was delivered but does not show the model, quite frankly I would like it better if the model does not spawn, as long as the sim sees it as a FARP and have a frequency.(wich it does not at this time)

Link to comment
Share on other sites

As per Grimes suggestion;

 

FARP Ammo Storage = "FARP Ammo Dump Coating"

FARP Command Post = "FARP CP Blindage"


Edited by Highwayman-Ed

Intel i9-9900KF @5.2GHz

MSI Z390 Gaming Pro Carbon

32GB G.Skill Trident Z DDR3200 RAM

MSI RTX 2080 Ti Gaming X Trio

40" Panasonic TH-40DX600U @ 4K

Pimax Vision 8K Plus / Oculus Rift CV1 / HTC Vive

Gametrix JetSeat with SimShaker

Windows 10 64 Bit Home Edition

 

[sIGPIC][/sIGPIC]

Link to comment
Share on other sites

-nvm-

 

I thought the thread title was 'Spawning Carp'

ASUS ROG Maximus VIII Hero, i7-6700K, Noctua NH-D14 Cooler, Crucial 32GB DDR4 2133, Samsung 950 Pro NVMe 256GB, Samsung EVO 250GB & 500GB SSD, 2TB Caviar Black, Zotac GTX 1080 AMP! Extreme 8GB, Corsair HX1000i, Phillips BDM4065UC 40" 4k monitor, VX2258 TouchScreen, TIR 5 w/ProClip, TM Warthog, VKB Gladiator Pro, Saitek X56, et. al., MFG Crosswind Pedals #1199, VolairSim Pit, Rift CV1 :thumbup:

Link to comment
Share on other sites

  • 1 year later...
 Share

  • Recently Browsing   0 members

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