Crater_1 Posted April 11, 2023 Posted April 11, 2023 Hello fellow Aviators! Thank you for taking the time to assist me here. I'm trying to build a fun Multiplayer Mission that is different from the normal fly around and kill things. What I'm struggling with is triggers v. LUA. I have a game that you need to takeoff from airport "A" and land at airport "B" but stay under 1500ft MSL or SA-6 group "X" activates, targets, and fires upon violating pilot. I worry that I will make it fire upon ANY aircraft above 1500, would like to have it get unit/units in zone "LL Zone 1", get Alt of unit(those in Zone), if unit is above 1500msl, activate SA-6 sites (there's multiple). Would there be a way to get the SA to ONLY target the violating aircraft...in case 2 pilots are flying near each other within the zone and only one of them breaches the ceiling? I have a few more, but this is my main one right now. Thank you all!
PravusJSB Posted April 11, 2023 Posted April 11, 2023 (edited) Hello there! Yes this is possible, i'll lay out the steps and research on Hoggit wiki for the methods and how to use them but, have the S2A sites disabled on start (use AI off and green ROE), then set up a trigger/monitor for your player and watch for violation of your rules, either tie into existing event triggers, custom ones or make a specific loop to watch client aircraft, any S2A sites in range that can prosecute your penalty have the AI now turned on, use knowTarget methods or similar then use the tasking system to clear tasks and to specifically set the S2A site to target and fire upon the perp. using the attackUnit methods, then when the task is done, disable the site again until you need it again. Edited April 12, 2023 by PravusJSB Creator & Developer of XSAF ::An AI model that wants to kill you, and needs no help from humans. Discord: PravusJSB#9484 twitch.tv/pravusjsb https://www.patreon.com/XSAF https://discord.gg/pC9EBe8vWU https://bmc.link/johnsbeaslu Work with me on Fiverr: https://www.fiverr.com/pravusjsb
cfrag Posted April 12, 2023 Posted April 12, 2023 As a quick first attempt at this, you could make all aircraft invisible, and cancel invisibility selectively for those aircraft that infringe on the hard ceiling. This would require single-unit player groups, because invisibility AFAIK operates on group level.
PravusJSB Posted April 12, 2023 Posted April 12, 2023 It's a good idea too. I did find some issues getting certain frames set as clients to accept that dynamically though so testing across all use cases is a good idea. Creator & Developer of XSAF ::An AI model that wants to kill you, and needs no help from humans. Discord: PravusJSB#9484 twitch.tv/pravusjsb https://www.patreon.com/XSAF https://discord.gg/pC9EBe8vWU https://bmc.link/johnsbeaslu Work with me on Fiverr: https://www.fiverr.com/pravusjsb
Recommended Posts