Jump to content

destroying human weapons and planes with the :destroy() function


davidp57

Recommended Posts

Hi all !

 

I'm writing a script called Sanctuary; with this, a mission maker can define a zone (center+radius, or mist polygon) in which the players from a coalition are protected from the human players from other coalitions (some sort of safe zone).

 

In this script, whenever a human lingers too long in the zone, I try and remove him from the game by using :destroy() on his unit.

Also, when a human player fires a missile at another human in the zone, I try and :destroy() the weapon, too.

 

This works very well for AI planes and their weapons, but not at all with humans in MP.

 

Did any of you ever try to do this ?

Could maybe our friend @BIGNEWY ping our beloved devs, and ask about this behavior ?

It's one of the multiple instances where the API does not work in the same way in SP and MP.

 

Thank you for reading, I hope someone will help me !

veafSanctuary.lua veaf-demo-mission_20210410-AI.miz veaf-demo-mission_20210410-MP.miz

  • Like 1

Zip - VEAF :pilotfly:

 

If you want to learn, talk and fly with french-speaking friends, the Virtual European Air Force is here for you ! Meet us on our Discord and our forum

If you're a mission creator, you may want to check the VEAF Mission Creation Tools (and its GitHub repository) a set of open-source scripts and tools that make creating a dynamic mission a breeze !

Link to comment
Share on other sites

  • ED Team

I will ask the team, if I find anything out I will let you know

 

thanks

  • Like 1

smallCATPILOT.PNG.04bbece1b27ff1b2c193b174ec410fc0.PNG

Forum rules - DCS Crashing? Try this first - Cleanup and Repair - Discord BIGNEWY#8703 - Youtube - Patch Status

Windows 11, NVIDIA MSI RTX 3090, Intel® i9-10900K 3.70GHz, 5.30GHz Turbo, Corsair Hydro Series H150i Pro, 64GB DDR @3200, ASUS ROG Strix Z490-F Gaming, HP Reverb G2

Link to comment
Share on other sites

Thanks, you're always helpful and that means a lot to the community !

  • Like 1

Zip - VEAF :pilotfly:

 

If you want to learn, talk and fly with french-speaking friends, the Virtual European Air Force is here for you ! Meet us on our Discord and our forum

If you're a mission creator, you may want to check the VEAF Mission Creation Tools (and its GitHub repository) a set of open-source scripts and tools that make creating a dynamic mission a breeze !

Link to comment
Share on other sites

I found a way : using `trigger.action.explosion` it is possible to destroy weapons and planes, human or not !

https://youtu.be/4ZY7SC3MOHI

  • Like 1

Zip - VEAF :pilotfly:

 

If you want to learn, talk and fly with french-speaking friends, the Virtual European Air Force is here for you ! Meet us on our Discord and our forum

If you're a mission creator, you may want to check the VEAF Mission Creation Tools (and its GitHub repository) a set of open-source scripts and tools that make creating a dynamic mission a breeze !

Link to comment
Share on other sites

  • Recently Browsing   0 members

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