Jump to content

ME Trigger Help Needed


Chopper A-10
 Share

Recommended Posts

Guys, this is what I need help with.

 

The mission I'm working on has a bridge over a river.

 

When the bridge is eliminated I want to trigger a announce it with a audio message that it's been destroyed.

 

Since I didn't create the bride, it's not a UNIT or GROUP I can't use a trigger to confirm that it's been destroyed . . . I've put soldiers and vehicles on the bridge, they have been eliminated but that can happen without the bridge falling down.

 

I've hit the bridge with two JDAMs (it burns a little while) and it took a few seconds before the bridge collapsed.

 

Any thoughts on how I can make this work??

 

Thanks

i7-7700K 4.20Ghz | GeForce GTX 1080Ti DUKE | ASUS Maximus IX Hero Z270 | Samsung 960 | Corsair CPU Cooler | G.SKILL 32GB | Oculus VR Rift | Saitek PRO Pedals & TM HOTAS Warthog Throttle & Joystick |

Link to comment
Share on other sites

There might be a few ways, I haven't necessarily tested these:

 

 

1 - Immortal unit on bridge, then set a trigger to detect if it moves in altitude (bridge falls)

 

 

2 - Trigger to detect bombs in zone, when enough fall in the zone, consider bridge destroyed, or use the scenery remove trigger to manually destroy the bridge.

 

 

3 - Scripting, with scripts I think you can determine if the bridge is dead.

Awaiting: DCS F-15C

Win 10 i5-9600KF 4.6 GHz 64 GB RAM RTX2080Ti 11GB -- Win 7 64 i5-6600K 3.6 GHz 32 GB RAM GTX970 4GB -- A-10C, F-5E, Su-27, F-15C, F-14B, F-16C missions in User Files

 

Link to comment
Share on other sites

You can use MIST like this:

-- Create a zone around an object (bridge/building)
-- Below when bridge in zone 'Bridge11' is dead, flag 1 is set to 1
mist.flagFunc.mapobjs_dead_zones{ zones = {'Bridge11'}, flag = 1, req_num = 1 }

 

Or without MIST:

 

https://forums.eagle.ru/showthread.php?p=4284948#post4284948

-- Originally Posted by Majinbot View Post

-- Without using MIST, you can use the last function of the editor. You right-click on a building/Bridge/.., the word "assign as" appears, if you click on the word, you create a trigger zone connected

-- to the building, then you have to copy the object id value, es. 123456. ADD SCRIPT:

 

Handler = {}
function Handler:onEvent(event)
if event.id == world.event.S_EVENT_DEAD and event.IniUnitName == 123456 then
trigger.action.setUserFlag('1', true) 
end
end
world.addEventHandler(Handler)

Link to comment
Share on other sites

Hi,

 

I used toutenglisse`s MIST-SceneryObject-destroyed.miz for A10C destroy bridge - mist.miz

Changed his Explosion with a A10C Ground attack

:thumbup: "Bridge destroyed" is working

 

 

The same without MIST - Majinbot`s Function Handler

"Bridge destroyed" isn´t working

:doh: I guess, as a noob I miss here some basic knowledge with the Triggers

A10C destroy bridge - mist.miz

A10C destroy bridge - without mist.miz

Link to comment
Share on other sites

Hi,

 

I used toutenglisse`s MIST-SceneryObject-destroyed.miz for A10C destroy bridge - mist.miz

Changed his Explosion with a A10C Ground attack

:thumbup: "Bridge destroyed" is working

 

 

The same without MIST - Majinbot`s Function Handler

"Bridge destroyed" isn´t working

:doh: I guess, as a noob I miss here some basic knowledge with the Triggers

 

my mistake, when i tried the script i had loaded moose and i didn't realize that without moose it doesn't work ...

PC: i7-10700K - Asus TUF RTX 3080ti - 32GB RAM PC3200 - 3x970 evo  - VPC MongoosT-50CM3 - VKB GF pro - MFG Crosswind - Msi MPG321UR-QD + Acer XB271HU - TrackIR5 - Rift S

Link to comment
Share on other sites

Hi,

 

No problem

Thx for quick response

 

Now that my little girl has let me use my pc, try this it should work without moose

 

Handler = {}
function Handler:onEvent(event)
if event.id == world.event.S_EVENT_DEAD and event.initiator:getName() == 72455195 then
trigger.action.setUserFlag('1', true) 
end
end
world.addEventHandler(Handler)

PC: i7-10700K - Asus TUF RTX 3080ti - 32GB RAM PC3200 - 3x970 evo  - VPC MongoosT-50CM3 - VKB GF pro - MFG Crosswind - Msi MPG321UR-QD + Acer XB271HU - TrackIR5 - Rift S

Link to comment
Share on other sites

Now that my little girl has let me use my pc, try this it should work without moose

 

Handler = {}
function Handler:onEvent(event)
   if event.id == world.event.S_EVENT_DEAD and event.initiator:getName() == 72455195 then
   trigger.action.setUserFlag('1', true) 
   end
end
world.addEventHandler(Handler)

 

Hi,

 

:thumbup: Thx, working

 

Edit : Test-Miz

A10C destroy 3 map objects with message - without mist.miz


Edited by Blech
MIZ
Link to comment
Share on other sites

Really useful thread .. thanks for all the tips.

:thumbup:

 

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

Majinbot and Blech . . . you guys rock!

 

This is EXACTLY what I was looking for . . . will use this one in many missions to come,

thanks again!

i7-7700K 4.20Ghz | GeForce GTX 1080Ti DUKE | ASUS Maximus IX Hero Z270 | Samsung 960 | Corsair CPU Cooler | G.SKILL 32GB | Oculus VR Rift | Saitek PRO Pedals & TM HOTAS Warthog Throttle & Joystick |

Link to comment
Share on other sites

 Share

  • Recently Browsing   0 members

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