Jump to content

Mission Editor - Hot Tips


MadTommy

Recommended Posts

@ACHURRO

Ok let’s assume this is a Single player mission (no problem about “group inside zone”), and that the problem could be the continous try of the system to access your sound file.

Try to associate the sound to a flag, that you can master with “time since flag” condition for any activation. Maybe try this:

nn= time in seconds that lasts your enviroronmental sound +1

FRONT CONDITION->FLAG IS FALSE(1),UNIT INSIDEZONE(your unit, your zone)->SET FLAG(1),PLAY SOUND

CONTINOUS->TIME SINCE FLAG(1,nn)->CLEAR FLAG(1)

Does it work?

ChromiumDis.png

Author of DSMC, mod to enable scenario persistency and save updated miz file

Stable version & site: https://dsmcfordcs.wordpress.com/

Openbeta: https://github.com/Chromium18/DSMC

 

The thing is, helicopters are different from planes. An airplane by it's nature wants to fly, and if not interfered with too strongly by unusual events or by a deliberately incompetent pilot, it will fly. A helicopter does not want to fly. It is maintained in the air by a variety of forces in opposition to each other, and if there is any disturbance in this delicate balance the helicopter stops flying; immediately and disastrously.

Link to comment
Share on other sites

@ACHURRO

 

Ok let’s assume this is a Single player mission ..... Does it work?

 

I'll try... and report!

 

Thanks for your time!

 

:thumbup:

 

[OK Chromium, it works perfectly!!, thanks again]


Edited by Achurro

[sIGPIC][/sIGPIC]

Link to comment
Share on other sites

I've got a quite general question regarding trigger conditions. Is it possible to somehow build an 'ANY' operator? Maybe as an integrated feature in future addons. I mean, if I want to pop up a SAM system if ANY RED/BLUE coalition aircraft reaches (one of the 60...) then now I have to build 60 triggers and even edit them via notepad to change the 'AND' operator to 'OR'.

Or is there a more simple method and I'm just simply bumb?:huh:

  • Like 1

[sIGPIC]http://www.forum.lockon.ru/signaturepics/sigpic5279_1.gif[/sIGPIC]

I could shot down a Kitchen :smartass:

Link to comment
Share on other sites

Afaik there is no easy way to do this. I really wish there was. If anyone has a simple solution to this problem i'd love to hear it.

 

This was how i have been doing this is..

 

Set a trigger for each 'unit' i want to affect a condition.. each trigger sets a Flag. This flag carries out my wanted condition. i.e activate a SAM site.

 

i.e

  • Once > Unit in zone > Set flag 1
  • Once > Flag 1 true > activate SAM unit.

i5-3570K @ 4.5 Ghz, Asus P8Z77-V, 8 GB DDR3, 1.5GB GTX 480 (EVGA, superclocked), SSD, 2 x 1680x1050, x-fi extreme music.



TM Warthog, Saitek combat pro pedals, TrackIR 4

Link to comment
Share on other sites

  • 2 weeks later...

Yeah, good solution, an other is to set the AND operators to OR in notepad to all units included in the trigger. BTW, the ANY operator must exist in the ME, because GAI flights consider any aircrafts entering their given range and scramble on them.

[sIGPIC]http://www.forum.lockon.ru/signaturepics/sigpic5279_1.gif[/sIGPIC]

I could shot down a Kitchen :smartass:

Link to comment
Share on other sites

I´d like to get back into mission making.

Please, where possible answer with psuedo code, or preferbly in this format:

 

FRONT CONDITION->FLAG IS FALSE(1),UNIT INSIDEZONE(your unit, your zone)->SET FLAG(1),PLAY SOUND
CONTINOUS->TIME SINCE FLAG(1,nn)->CLEAR FLAG(1)

 

1. How do one start a misison, with ALL units decativated?

 

2. Whats the use of the FRONT CONDITION?

 

3. Are the triggers executed sequentiially, as in a computer program?

 

4. How can i program this situation?

- Airbase Sukhumi is neutral

- Bluefor tank group drives/arrives at an airbase (lets say, sukhumi).

- A timer starts, which after 5 minutes Bluefor has SHORAD available

- After this 5 minutes passed SHORAD units are activated.

- When the Bluefor shorad units are active, another tank group drives to the Sukhumi.

- When those bluefor units arrived, US F-16's are available for CAP from Sukhumi.

 

5. How does Red capture the airbase from Blue?

 

6. How can the lost airbase be recaptured?


Edited by pappavis

met vriendelijke groet,

Михель

 

"умный, спортсмен, комсомолетс"

 

[sIGPIC]159th_pappavis.jpg[/sIGPIC]

 

[TABLE]SPECS: i9-9900K 32gigs RAM, Geforce 2070RTX, Creative XFi Fata1ity, TIR5, Valve Index & HP Reverb, HOTAS Warthog, Logitech G933 Headset, 10Tb storage.[/TABLE]

Link to comment
Share on other sites

1. How do one start a misison, with ALL units decativated?

For each unit or group of units, set the "Time hold" option to 23 hours. You can then activate units or groups of units with triggers, see here.

 

2. Whats the use of the FRONT CONDITION?

I can't recall if this is a DCS:BS trigger or a FC2.0 trigger. FC2.0 has a SWITCHED CONDITION trigger, which is only executed if the condition switches state. Like a unit entering a zone, or exiting a zone, or passing an altitude.

 

3. Are the triggers listed sequentiially?

As far as I can tell they are, but so far I have not noticed that the order in which they are listed influences their executing. It may be they do.

 

4. How can i program this situation?

- Airbase Sukhumi is neutral

- Bluefor tank group drives/arrives at an airbase (lets say, sukhumi).

- A timer starts, which after 5 minutes Bluefor has SHORAD available

- After this 5 minutes passed SHORAD units are activated.

- When the Bluefor shorad units are active, another tank group drives to the Sukhumi.

- When those bluefor units arrived, US F-16's are available for CAP from Sukhumi.

To keep Sukhumi neutral there shouldn't be any unit within a certain radius (I believe 1 km). If your blue tank group gets within that radius Sukhumi will become a blue airbase. Here you can use a SWITCHED CONDITION trigger using the HAS AIRDROME condition to do a SET FLAG. Then you can have an ONCE trigger using TIME SINCE FLAG with 300 seconds with ACTIVATE GROUP to start your shorad units and the second tank group. You can then use a ONCE trigger with UNIT INSIDE ZONE to check on the second group arriving at the airbase to activate the F-16's.

 

5. How does Red capture the airbase from Blue?

Red must destroy all blue units that are within the radius mentioned above and get within that radius itself. You may want to test this, cause it might go neutral when each coalition is within that radius with alive units.

 

6. How can the lost airbase be recaptured?

The same as above but with blue units destroying the red ones.

 

I hope this is enough information for you. If you can't get it to work I might be able to make you an example mission.

There are only 10 types of people in the world: Those who understand binary, and those who don't.

Link to comment
Share on other sites

4. How can i program this situation?

- Airbase Sukhumi is neutral

- Bluefor tank group drives/arrives at an airbase (lets say, sukhumi).

- A timer starts, which after 5 minutes Bluefor has SHORAD available

- After this 5 minutes passed SHORAD units are activated.

- When the Bluefor shorad units are active, another tank group drives to the Sukhumi.

- When those bluefor units arrived, US F-16's are available for CAP from Sukhumi.

 

5. How does Red capture the airbase from Blue?

 

6. How can the lost airbase be recaptured?

 

I'm gonna chime in here. Base ownership is based on two variables.

1. Any units within 1.5 km of the base.

2. If aircraft take-off/land at the base.

 

All units must spawn outside of the 1.5 km ring around the base. You can have SHORAD's stationed on the perimeter and have waypoints to drive on to base. Otherwise at the start of the mission blue will own the base, so they must be outside of the area.

 

However aircraft trump ground units. If you have F-16s set to takeoff or land at Sukhumi using a trigger that checks for airbase ownership by blue it will become useless, as blue already owns the base. So you would need to replace that with a trigger that checks if blue ground units entered the area around the base.

 

NOTE: If both sides have aircraft set to take-off/land from the same base it defaults to blue.

 

5. Red has to kill all active blue units at the base and physically capture the base.

 

6. By simply having units from either coalition move onto a neutral airbase.

 

If you want to make a mission where airbase ownership goes back and forth between red and blue... well first off good luck, but 2ndly check out my "Capturing Maykop" mission for FC2. I built the a good portion of it within Black Shark so it is certainly a possible feat to accomplish.

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

Current Projects:  Grayflag ServerScripting Wiki

Useful Links: Mission Scripting Tools MIST-(GitHub) MIST-(Thread)

 SLMOD, Wiki wishlist, Mission Editing Wiki!, Mission Building Forum

Link to comment
Share on other sites

NOTE: If both sides have aircraft set to take-off/land from the same base it defaults to blue.
And ground units do not override this?

There are only 10 types of people in the world: Those who understand binary, and those who don't.

Link to comment
Share on other sites

And ground units do not override this?

 

Only for the red team to capture if nothing is at the base and blue has aircraft set to take-off/land there.

 

Under this condition, basically if its a red base and it becomes cleared it switches to blue rather than to neutral.

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

Current Projects:  Grayflag ServerScripting Wiki

Useful Links: Mission Scripting Tools MIST-(GitHub) MIST-(Thread)

 SLMOD, Wiki wishlist, Mission Editing Wiki!, Mission Building Forum

Link to comment
Share on other sites

2 Q's.

 

1) Is there a way to have a group abort mission (or better yet, divert to a dump target) using a trigger. Example: OCA Sweep is killed off therefore rather than pressing in and dying, strikers attack a backup target or just RTB?

 

2) How do you set the amount of time that a group will orbit between "Begin Loop" and "End Loop" before pressing on?

 

Thanks in advance.

Link to comment
Share on other sites

2 Q's.

 

1) Is there a way to have a group abort mission (or better yet, divert to a dump target) using a trigger. Example: OCA Sweep is killed off therefore rather than pressing in and dying, strikers attack a backup target or just RTB?

 

2) How do you set the amount of time that a group will orbit between "Begin Loop" and "End Loop" before pressing on?

 

Thanks in advance.

 

1, I've tried to do this via several means and the only way I've found is to build in a whole bunch of triggers that do the following.

 

Group A-1 drive from waypoint 1 to waypoint 2 which has a trigger assigned that does this:

 

Trigger:
Type = Once
Name = Test 1

Rules:
Unit inside Zone = Group A-1-1, Zone = Trigger A
Group B is Alive

Actions:
Activate group A-2
Deactivate group A-1

 

If the condition is True, group A-1 is deactivated and replaced by group A-2 (which you would set to start very close to where the trigger is activated. with practice, you can make the switch over between the two groups almost seem less. The second group then drives on the the next waypoint and trigger combination where you repeat the process above, but this time with a 3rd group and so on.

 

Trigger:
Type = Once
Name = Test 2

Rules:
Unit inside Zone = Group A-2-1, Zone = Trigger B
Group B is Alive

Actions:
Activate group A-3
Deactivate group A-2

 

You could carry on this process as many times as you like and you make the 3rd waypoint to be either a return to base, or to hold up on a defensive position somewhere near the trigger zone as this will only ever be used if Group B is dead.

 

The image below may help understand this.

 

th_ME-4.jpg

 

Whilst I have used tanks to illustrate the point, the same method works with Air units.

 

2, This one I'm afraid is a question of fuel burn as the unit will start looping as soon as it reaches a 'Begin Loop' waypoint and will only 'End Loop' if it's attacked, heads off to intercept a target or reaches Bingo fuel and has to land...


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

 

2, This one I'm afraid is a question of fuel burn as the unit will start looping as soon as it reaches a 'Begin Loop' waypoint and will only 'End Loop' if it's attacked, heads off to intercept a target or reaches Bingo fuel and has to land...

 

Its best to set waypoints manually for the approximate time you want them to patrol for. This creates a few benefits.

 

1. You can control where they attack and protect. By placing a target area for each waypoint they will be limited to that area of operation and wont fly 200km to kill a target.

 

2. You control how long they patrol the airspace.

 

3. You can control when you want them to fly to a tanker and get fuel. Unfortunately they still fly full burners to intercept the tanker no matter how far away it is.

 

There are downsides.

1. Makes the mission larger

2. You need 40+ waypoints to patrol for around 1.5 hours. It depends on your placement method of WP and the size of the area you want them to patrol.

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

Current Projects:  Grayflag ServerScripting Wiki

Useful Links: Mission Scripting Tools MIST-(GitHub) MIST-(Thread)

 SLMOD, Wiki wishlist, Mission Editing Wiki!, Mission Building Forum

Link to comment
Share on other sites

  • 2 weeks later...

Need some help. If you have a tanker in the air, will the aircraft go to get fuel when they need it? What do I have to do to make a unit refuel? I there a way to create a flight, for example, an AWACS, and then have another flight escort them, I'm preetty sure there is but i dont know how. I want them to be one flight, all i can do so far is try to make another identical route for the escorts.

Go ahead, Make it idiot proof, someone will just find better idiots...;)

Link to comment
Share on other sites

Hi EtherealN, and thanks for your interest !!

 

The first one is yes, I used mts for meters, sorry about my english I'm spanish..:cry:

 

Yo necessitar una solucion.

¿Como es mi Español? :D I am taking spanish.


Edited by snowman123

Go ahead, Make it idiot proof, someone will just find better idiots...;)

Link to comment
Share on other sites

How do i know if >=1 MP clients are connected?

 

Reason is, i only want AI flights / units to become active when there are MP clients connected. This would extend the lifetime, playabiolity & difficulty of a mission.

met vriendelijke groet,

Михель

 

"умный, спортсмен, комсомолетс"

 

[sIGPIC]159th_pappavis.jpg[/sIGPIC]

 

[TABLE]SPECS: i9-9900K 32gigs RAM, Geforce 2070RTX, Creative XFi Fata1ity, TIR5, Valve Index & HP Reverb, HOTAS Warthog, Logitech G933 Headset, 10Tb storage.[/TABLE]

Link to comment
Share on other sites

Paps,

- you cant tell if they are connected.

- you CAN tell if there are players within a triggerzone.

 

1. Make a Triggerzone, near "spawn". Make it big.

2. Make a trigger, checking for "Pilot #1 active and within Zone", "Pilot #2 active and within Zone" etc (or make a good "Switched Condition" for this instead using "once").

3. Action: Activate group.

 

Or:

Another sample of advanced "AND->OR" hacking;

If you have a MP map with 8 players and need to check if *any* 2 are in a Zone at the same time.

How to check for 2 players in a Zone; http://forums.eagle.ru/showpost.php?p=809924&postcount=23


Edited by Panzertard

The mind is like a parachute. It only works when it's open | The important thing is not to stop questioning

Link to comment
Share on other sites

Need some help. If you have a tanker in the air, will the aircraft go to get fuel when they need it? What do I have to do to make a unit refuel? I there a way to create a flight, for example, an AWACS, and then have another flight escort them, I'm preetty sure there is but i dont know how. I want them to be one flight, all i can do so far is try to make another identical route for the escorts

Go ahead, Make it idiot proof, someone will just find better idiots...;)

Link to comment
Share on other sites

  • 1 month later...

Guys

 

Do any of you have a quick way of determining if a bridge has been destroyed? I have had a few attempts based on having a vehicle nearby that will presumably get destroyed if the bridge is hit, thus triggering a flag. Seems a bit fiddly to me.

[sIGPIC][/sIGPIC]

i7 9700k | 32gb DDR4 | Geforce 2080ti | TrackIR 5 | Rift S | HOTAS WARTHOG | CH PRO Pedals

Link to comment
Share on other sites

  • 5 weeks later...
Here is a simple way to do the "or" modifier with triggers. Don't know why I didn't see this earlier...

 

For example you want to check whether Unit 1 or Unit 2 are death:

 

 

CONTINUOUS / FLAG IS FALSE (1) / SET FLAG (1)

FRONT CONDITION / UNIT ALIVE (Unit 1), UNIT ALIVE (Unit 2), TIME SINCE FLAG (1,1) / CLEAR FLAG (1)

ONCE / TIME SINCE FLAG (1,2) / MESSAGE ("Unit 1 or Unit 2 is death)

 

 

In the bold part you list the opposite of your "or" rules you want to check. So we want to check if one unit is death, then we list all the units as alive. Or we want to check if one unit is inside a zone, then we list all units as outside the zone.

 

Cool. What about *any* unit from coalition. It could be a very, very long list of units.... Weird we dont have a 'coalition' selector as well as 'unit' selectors. But good fun the scripting is too.


Edited by RipKirby
Link to comment
Share on other sites

  • Recently Browsing   0 members

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