Removing No Navigation (Fly) Zones????

All discussions & material related to Command's Lua interface

Moderators: angster, RoryAndersonCDT, michaelm75au, MOD_Command

Post Reply
User avatar
BeirutDude
Posts: 2811
Joined: Sat Apr 27, 2013 9:44 am
Location: Jacksonville, FL, USA

Removing No Navigation (Fly) Zones????

Post by BeirutDude »

OK I hope this is simple, using a trigger of hostilities starting at a certain time Time = 14:30:00 I'd like to create an action removing a simple No Navigation Zone. I really suck at Lua, I admit I do and some examples (real practical examples in the Lua Docs) would really help the neophyte!

This is what I came up with, but it obviously is wrong! [:@]

ScenEdit_RemoveZone ('NATO','Type=1','{RP-1881,RP-1882,RP-1883,RP-1884}')

Image
Attachments
NoFlyZone.jpg
NoFlyZone.jpg (51.58 KiB) Viewed 246 times
"Some people spend an entire lifetime wondering if they made a difference. The Marines don't have that problem."
PRESIDENT RONALD REAGAN, 1985

I was Navy, but Assigned TAD to the 24th MAU Hq in Beirut. By far the finest period of my service!
KnightHawk75
Posts: 1850
Joined: Thu Nov 15, 2018 7:24 pm

RE: Removing No Navigation (Fly) Zones????

Post by KnightHawk75 »

ScenEdit_RemoveZone('NATO','0',{Description="NameOfMyNoNavZone"}) --would delete it
ScenEdit_SetZone('NATO','0',{Description="NameOfMyNoNavZone",Isactive=false}) -- would just disable it (if you need that at some point in future).
User avatar
BeirutDude
Posts: 2811
Joined: Sat Apr 27, 2013 9:44 am
Location: Jacksonville, FL, USA

RE: Removing No Navigation (Fly) Zones????

Post by BeirutDude »

Thank you!
"Some people spend an entire lifetime wondering if they made a difference. The Marines don't have that problem."
PRESIDENT RONALD REAGAN, 1985

I was Navy, but Assigned TAD to the 24th MAU Hq in Beirut. By far the finest period of my service!
Kushan04
Posts: 1215
Joined: Tue Jun 28, 2005 9:27 pm
Location: USA
Contact:

RE: Removing No Navigation (Fly) Zones????

Post by Kushan04 »

Can also use SetZone to turn off a zone instead of deleting it.

ScenEdit_SetZone('Side', '0', {description='NameOfMyNoNavZone', isactive='false'})
Post Reply

Return to “Lua Legion”