Dedging Islands...

All discussions & material related to Command's Lua interface

Moderators: RoryAndersonCDT, michaelm75au, angster, MOD_Command

Post Reply
jkgarner
Posts: 175
Joined: Thu Apr 30, 2020 12:42 pm

Dedging Islands...

Post by jkgarner »

The Chinese have dredged up islands in the South China Sea.

Some of the Emirs in the Emirates have done similarly in the Persian Gulf for other reasons.

These small islands do not appear in Command.

I would like to create a scenario where the Chinese have placed a ground unit (SAM and Radars) on a newly dredged island. To this end, I need to either be able to put a ground unit where Command thinks is water, or (better yet) designate as land a small area on the map that is water. Then presumably I can place my ground units on that newly formed island.

Are there any thought on how to do this? (in Lua?)

KnightHawk75
Posts: 1850
Joined: Thu Nov 15, 2018 7:24 pm

RE: Dedging Islands...

Post by KnightHawk75 »

Short version:
One thing you can do, and i've only used it sparingly (and this will not really work for land units when it comes to navigation problems) is create say unit(s) you want on land first, then move their latitude and longitude after the fact via lua. Technically it will allow you to do that sometimes for certain instances like to create a single unit airbase in the middle of the pacific, or exactly your situation where your want to put 'radar island' somewhere.

Longer version:
I've successfully used such with aircraft bases and other mostly singular units without an noticeable issue to work around the missing island issue or I want a fictional island base, including recently. Keep in mind though when it comes to radar you're gonna have a problem due to depth (-elevation) very likely being used for it's elevation calcs for radar horizon. A cute trick I found at one point, and can't say if it still works or not (didn't use it recently) but I used to use the aero-stat units with 3000-4000 meter MASTS to counter depth of the sea, as far as radar horizon (generally speaking it would use the difference between the two if surface-to-air role-code), obviously if you go too deep you're still screwed and underwater, if you're relatively shallow you obviously have a larger horizon then roughly sealevel like you really would a dredged island. Gotta take the bad with the good on that I think. If dealing with -3 -10 -20 shallow sort of areas though as I recall there a handful of other units with small masts...I think one of the s-300 variants has 15m mast, and some other russian radar I think has 100m mast.. you could "rebuild" those units into whatever you want for something closer to "just above sea-level" if the extended horizon is an issue. Or if you have pro...just build your own unit with a mast you lucky devil. :)

I almost didn't want to mention any of this because I do not want someone thinking it's a bug that should be fixed because it really really comes in handy here and there for special cases like this or other what-if's, and the gui stops 99% of people from making unintentional mistakes which is good but love that we can tweak via lua for these cases. Where it will not help you is say an area like salton sea cali\mexico border with the depth is technically right (below sea level) but being such still makes land units get stuck or try to nav around it, equally there will be no actual island in your case for the ships to navigate around.

I do think it would be great if we could live-overide the lat\lon ranges with our own altitude data with like a map-modify zone that was accounted for during navigation or something like that. idk While back I kinda looked into map data tweaking once and looked like I'd have to decode and patch the data encoded in related png file on disk in just the right way for the given area - which seemed sorta doable (obviously just for my local instance) but really not worth the effort. Maybe something for the long-term wish list, in the mean time the above handles some of the case like this. Another though unrelated trick for things the St.Lawrence river (above sea level) is a ton of port units all orientated such that their bypass range overlaps the whole range. Not pretty though.
Post Reply

Return to “Lua Legion”