Jump to content

MOOSE - Mission Object Oriented Scripting Framework


Recommended Posts

Hey Guys,

 

i just installed Eclipse LDT and tried to get Intellisense for some Moose Test Missions. But it wont work.

Seems like the Description from here doesnt work anymore:

https://flightcontrol-master.github.io/MOOSE_DOCS/Moose_Setup_Guide.html

 

Looks like the Problem is somewhere in the provided download for the Moose Source, because there is nothing in it which does anything with the project you have to create. For that reason there is no IntelliSense....

 

forget it....

i didnt change the Moose Directory as a Source Directory


Edited by Delareon
Link to comment
Share on other sites

Hi funkyfranky,

 

is there a way to check if a client player has selected an aircraft from the "MULTIPLAYER - Select role" menu? Im not interested in checking if he had already entered a unit, but just selected it ...

 

THANKS!

 

The mission environment has no knowledge of spectator role and limited control on Artillery commander, Game master etc. The first time in the mission environment that a player is handled is after he made a unit appear via the BIRTH event and his name then appears in the event.

 

What you are looking for is the net API for which Moose provides no help for. Look through the API directory in your game install for a list of available commands.

 

Sucks I know.

___________________________________________________________________________

SIMPLE SCENERY SAVING * SIMPLE GROUP SAVING * SIMPLE STATIC SAVING *

Link to comment
Share on other sites

Thanks, but that goes far beyond my abilities and is far too deep for me ... but anyway, thanks for your answer!!

 

Another question came up a few minutes ago:

military_fighter1:SetDestination("Bassel Al-Assad") 

seems not a suitable place to land for a MiG-29A. Airport and aircraft are of same coalitions.

I get the following message in DCS.log:

 

RAT01042._SetRoute(RAT | ERROR: No valid destination airport could be found for RAT_MiG-29!) 

 

I can place a MiG-29A on the airfield by hand, and let it taxi and take-off, but I think MOOSE is not accepting this humble airfield for the MiG.

Currently I am using MOOSE 2.5.0 ( '*** MOOSE GITHUB Commit Hash ID: 2020-05-19T07:24:33.0000000Z-47ea77728c7f6a3bf1d185342e0953547a93a92a ***'

 

Any hints?


Edited by TOViper
"Latakia" is also not working ....

Visit https://www.viggen.training
...Viggen... what more can you ask for?

my computer:
AMD Ryzen 5600G | NVIDIA GTX 1080 Ti OC 11GB | 32 GB 3200 MHz DDR4 DUAL | SSD 980 256 GB SYS + SSD 2TB DCS | TM Warthog Stick + Throttle + TPR | Rift CV1

 

Link to comment
Share on other sites

Thanks, but that goes far beyond my abilities and is far too deep for me ... but anyway, thanks for your answer!!

 

Another question came up a few minutes ago:

military_fighter1:SetDestination("Bassel Al-Assad") 

seems not a suitable place to land for a MiG-29A. Airport and aircraft are of same coalitions.

I get the following message in DCS.log:

 

RAT01042._SetRoute(RAT | ERROR: No valid destination airport could be found for RAT_MiG-29!) 

 

I can place a MiG-29A on the airfield by hand, and let it taxi and take-off, but I think MOOSE is not accepting this humble airfield for the MiG.

Currently I am using MOOSE 2.5.0 ( '*** MOOSE GITHUB Commit Hash ID: 2020-05-19T07:24:33.0000000Z-47ea77728c7f6a3bf1d185342e0953547a93a92a ***'

 

Any hints?

It likely has a slightly different name internally. So we need to wait until someone with more knowledge had a look into the Syria map and lists the required name.

Shagrat

 

- Flying Sims since 1984 -:pilotfly:

Win 10 | i5 10600K@4.1GHz | 64GB | GeForce RTX 3090 - Asus VG34VQL1B  | TrackIR5 | Simshaker & Jetseat | VIRPIL CM 50 Stick & Throttle | VPC Rotor TCS Plus/Apache64 Grip | MFG Crosswind Rudder Pedals | WW Top Gun MIP | a hand made AHCP | 2x Elgato StreamDeck (Buttons galore)

Link to comment
Share on other sites

It likely has a slightly different name internally. So we need to wait until someone with more knowledge had a look into the Syria map and lists the required name.

Oh, that would be terribly confusing for everyone ;) The airbase name are always exactly the same as spelled in the mission editor. They are retrieved from the DCS API functions.

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

Any hints?

Could be a couple of things. For example, Bassel Al-Assat could be out of range from the departure airbase(s) you set.

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

Override OnAfter() event for RESCUEHELO

 

Hi all,

 

I need to have to set USERFLAG in a mission to have interaction between rescue helo and human pilote. I don't know how to do that.

 

My first idea is to override function On AfterSomething in the RESCUEHELO:FMS

My second idea is to add to FMS my function for the target event in the life of my RESCUEHELO.

 

Nothing seems doing well,

 

Example:

-- heloDecatur instantiates RESCUEHELO
-- my event triggered when rescue is done
function heloDecatur:onafterRescue(From, Event, To, RescueCoord)
-- do my own stuff
end

 

 

then

 

when the event is triggered :

-> RESCUEHELO:onafterRescue() is called
and
->  heloDecatur:onafterRescue() is called too

 

I imagine 2 solution :

  1. Use the right LUA syntax to write the script
  2. Use Moose FSM to add my function to call, FSM have to be able to call several function by event

 

if someone can help me ...:thumbup:

 

Thanks


Edited by jdeyrieux
Link to comment
Share on other sites

Release

 

MOOSE v2.5.1, which includes numerous updates, fixes and new classes including the new Syria map. If you already use the latest master branch version, there is no need to update.

 

DOWNLOAD https://github.com/FlightControl-Master/MOOSE/releases/tag/v2.5.1

 

Highlights

AI_FORMATION - Performance improvements.

COORDINATE - New functions to get sunrise and sunset times at any position of the map. - Misc.

RADIO - Updated beacon systems and types.

SET - New functions like :CountAlive() - Fixed bug in SET_STATIC

SPAWNSTATIC - Reworked class. - Added link to unit feature.

TIMER https://flightcontrol-master.github.io/MOOSE_DOCS/Documentation/Core.Timer.html - NEW class. Little sister of SCHEDULER class.

ATIS - Updates and options for more realistic output. - Included Syria Map. Needs new sound files!https://github.com/FlightControl-Master/MOOSE_SOUND/releases/tag/v1.2

AIRBOSS - Added Super Carrier parameters.

PROFILER https://flightcontrol-master.github.io/MOOSE_DOCS/Documentation/Utilities.PROFILER.html - NEW class. Let's you profile the CPU usage in your mission.

AIRBASE - Added Syria map airbase name enumerators. - Improved runway data function. - Misc.

MARKER https://flightcontrol-master.github.io/MOOSE_DOCS/Documentation/Wrapper.Marker.html - NEW class. Handling F10 markers.

 

Updates to Syria sound:

https://github.com/FlightControl-Master/MOOSE_SOUND/releases/tag/v1.2

___________________________________________________________________________

SIMPLE SCENERY SAVING * SIMPLE GROUP SAVING * SIMPLE STATIC SAVING *

Link to comment
Share on other sites

Hello

I found in MOOSE.Range doc that there are range control voice overs (>40) for hit assessment, available via Discord. I'm not a Discord user. Is there any other way to download those audio files?

 

BTW: Thanks for updates and all your work. I have good fun build things. MOOSE is awesome!

Link to comment
Share on other sites

Hello

 

I don't understand a bit how to put these sounds into the mission. AirBoss is ok because we have a lua. an appeal to him and what about the rest of the sounds.

 

 

easiest way is to add them via a trigger sound to country (pick one not used) and load them alll that way

Click here for tutorials for using Virpil Hardware and Software

 

Click here for Virpil Flight equipment dimensions and pictures.

.

Link to comment
Share on other sites

Is there anywhere on the interwebs one can find a working example of the «on the range» script?

Supercarrier | Flaming Cliffs 3 | M-2000C | AJS-37 Viggen| MIG-21Bis | L-39 Albatros | Yak-52 | Spitfire LF MK IX | Mig-15Bis | Mig-19P Farmer | P-51D Mustang | F/A-18 | F-14 | F-5E Tiger II | C-101 Aviojet | I-16 | UH-1H Huey | Mil MI-8tv2 | Sa 342M Gazelle | Combined Arms | NS-430 Navigation System | NEVADA | Persian Gulf | Normandy1944 | World war II assets pack | Black Shark 2 | F-5E Agressors ACM campaign |F-5E Agressors BFM Campaign | L-39 Albatros Kursant Campaign | DCS:Syria

Link to comment
Share on other sites

Is there anywhere on the interwebs one can find a working example of the «on the range» script?
https://r.tapatalk.com/shareLink/topic?url=https%3A%2F%2Fforums%2Eeagle%2Eru%2Fshowthread%2Ephp%3Ft%3D274885&share_tid=274885&share_fid=74365&share_type=t&link_source=app

 

there's a miz on tundras post at above link. Haven't tried it myself but I've had my own ranges working in the past. Join the moose discord. It's very helpful and you'll find some script samples there as well.

 

Sent from my POT-LX1 using Tapatalk

Link to comment
Share on other sites

Hello

 

 

 

I don't understand a bit how to put these sounds into the mission. AirBoss is ok because we have a lua. an appeal to him and what about the rest of the sounds.

On the github you'll find sample missions for atis, airboss etc and I've just posted a link to a range example below. Download the mission examples and you'll be able to see the scripts and sounds by opening them with something like winwar or another archive program, and you'll be able to see the triggers you need in the mission editor (ME) . You load your scripts and moose.lua using triggers in the ME and when you're done making your scripts, mission etc drag your sound files into the miz file. Hope that makes sense.

 

Sent from my POT-LX1 using Tapatalk

Link to comment
Share on other sites

To get sound files into a mission open the mission in ME. Make a trigger at, say, time More 5 with action to play the sound file to an obscure country not used in the mission. Save the mission. This loads the sound file into the mission making it available to play by a script action.

Link to comment
Share on other sites

  • 3 weeks later...

Hello

 

I want to make a border that works like a zone. Only you will not need to set up dozens of small zones.

The zone works, but only for one group, how to do it for more groups, or better for the whole coalition?

 

Red1 = SET_GROUP:New():FilterPrefixes("Red_"):FilterStart()-- set group 'Red_Pig'
Zone_Pig = ZONE:New("ZonePig1")

Escort_Pig = SCHEDULER:New( nil, 
  function()
   if Red1:IsPartlyOrCompletelyInZone(Zone_Pig) then
       MESSAGE:New("Yes !!!", 60):ToAll()    
        Escort_Pig:Stop() end
   end, {}, 2, 2 )

 

FilterPrefixes ("Red_") doesn't feel like running.

:helpsmilie:

Specialization A-10C

https://vbw304.pl/

Link to comment
Share on other sites

Hello

 

I want to make a border that works like a zone. Only you will not need to set up dozens of small zones.

The zone works, but only for one group, how to do it for more groups, or better for the whole coalition?

 

Red1 = SET_GROUP:New():FilterPrefixes("Red_"):FilterStart()-- set group 'Red_Pig'
Zone_Pig = ZONE:New("ZonePig1")

Escort_Pig = SCHEDULER:New( nil, 
  function()
   if Red1:IsPartlyOrCompletelyInZone(Zone_Pig) then
       MESSAGE:New("Yes !!!", 60):ToAll()    
        Escort_Pig:Stop() end
   end, {}, 2, 2 )

 

FilterPrefixes ("Red_") doesn't feel like running.

:helpsmilie:

 

I don't think IsPartlyOrCompletelInZone works on a GROUP SET. You'll have to iterate through the SET and check each group in the SET. There is a ForEachGroup or something like that in the SET_GROUP class you can use. You might need additional logic if for example you need to have it so that ALL groups are in zone for instance.

Link to comment
Share on other sites

So I have a question.

 

I have two groups I need to run a LOS check between all units, so how do I run this for all units in AlphaGroup against all units in RedTargetGroup?

 

if AlphaGroup:GetUnit(1):IsLOS(RedTargetGroup:GetUnit(1)) then
 Things()
end

Link to comment
Share on other sites

Is there an issue with Airboss on the Syria map? I can get everything else to run (RecoveryTanker, AWACS, RescueHelo) . I use the same script for Caucaus and PG, just change whichever CVN number I use. Cannot get it to run on Syria.

 

Script working in other maps:

 

--Basic Airboss change CVN-XX to carrier named and add TACAN ch)

 

local AirbossCVN = AIRBOSS:New( "CVN-XX" ) -- UNIT name of CVN

AirbossCVN:SetSoundfilesFolder("Airboss Soundfiles/")

AirbossCVN:SetMenuSingleCarrier()

AirbossCVN:SetUserSoundRadio()

AirbossCVN:SetTACAN(XX, X, CVN)

AirbossCVN:SetICLS(11, CVN)

AirbossCVN:SetMenuRecovery(30, 20, false)

AirbossCVN:SetAirbossNiceGuy( true ) -- Optional

AirbossCVN:SetAutoSave()

AirbossCVN:SetDespawnOnEngineShutdown()

AirbossCVN:AddRecoveryWindow("06:30", "08:00", 1, nil, true, 30) -- 1 == Case 1

AirbossCVN:AddRecoveryWindow("09:30", "18:30", 1, nil, true, 30 ) -- 1 == Case 1

AirbossCVN:AddRecoveryWindow("19:00", "23:00", 3, nil, true, 30 ) -- 3 == Case 3

 

AirbossCVN:Start()

 

 

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...