Define Prosecution Area: circle. How?

Take command of air and naval assets from post-WW2 to the near future in tactical and operational scale, complete with historical and hypothetical scenarios and an integrated scenario editor.

Moderator: MOD_Command

Post Reply
apoll
Posts: 54
Joined: Wed Jun 20, 2007 10:08 am

Define Prosecution Area: circle. How?

Post by apoll »

In the latest Kushan air warfare tutorial, he defines a prosecution area for an OCA mission as a circle. Some sort of, I think, right click and a menu came up with circle or rectangle. He chose a circle, defined it, and used a circular prosecution area. How did he do that? I use the Define area drop down menu at the top but it only allows me to place 4 rectangular Reference points. How did he get to that context menu where he had a choice of circle or rectangle? Or was that some sort of other define area menu?

Grateful advice.

Apoll
apoll
User avatar
Gunner98
Posts: 5476
Joined: Fri Apr 29, 2005 12:49 am
Location: The Great White North!
Contact:

RE: Define Prosecution Area: circle. How?

Post by Gunner98 »

Cntrl + Right click - should give you the option
Check out our novel, Northern Fury: H-Hour!: http://northernfury.us/
And our blog: http://northernfury.us/blog/post2/
Twitter: @NorthernFury94 or Facebook https://www.facebook.com/northernfury/
stww2
Posts: 255
Joined: Tue May 23, 2017 4:58 am

RE: Define Prosecution Area: circle. How?

Post by stww2 »

I never even realized that was a thing-I guess you learn something new every day!
apoll
Posts: 54
Joined: Wed Jun 20, 2007 10:08 am

RE: Define Prosecution Area: circle. How?

Post by apoll »

Tks! That's very handy way of doing things.

apoll
DWReese
Posts: 1879
Joined: Fri Mar 21, 2014 11:40 am
Location: Miami, Florida

RE: Define Prosecution Area: circle. How?

Post by DWReese »

One tip that I can give you is this:

That generated circle creates LOTS of reference points, and it uses lots of memory, which it slows down the machine.

You likely don't NEED all of those reference points to create the area that you want.

So, eliminate some of them, keeping the basic shape of the area. Perhaps, after editing, your area will look more like an octagon rather than a circle, and it will use a lot less memory.

It's just a tip.

Doug
User avatar
stilesw
Posts: 1514
Joined: Wed Jun 25, 2014 10:08 pm
Location: Hansville, WA, USA

RE: Define Prosecution Area: circle. How?

Post by stilesw »

DWReese is right on. The below LUA code was created before the "reference point circle" feature was added to CMO/CMANO.

I don't recall who created it but it lets you assign any number of reference points around a given unit and, allows you to name them as you like. I've found that 12 works very well and have used this code extensively.

-WS

-----------------------------------------------------------------------------------

function draw_circle(a, b, First_Pt, Last_Pt, Num_Pts, txt) -- ([lat,lon], First_Pt, Last_Pt, Number_of_Pointsts, name)
if txt == nil then
txt = ""
end
lat1 = a.latitude
lon1 = a.longitude
r = b / 60
-----
for i = First_Pt, Last_Pt do -- Consecutive integer numbers
th = 2 * math.pi * i / Num_Pts
rlat = lat1 + r * math.cos(th)
rlon = lon1 + r * math.sin(th) / math.cos(math.rad(lat1))
ScenEdit_AddReferencePoint({
side = 'PlayerSide',
lat = rlat,
lon = rlon,
name = txt..i,
highlighted = "yes"})
end
end
---------------------------------------------------
Owner = "Appropriate Side Name"
Unit_Name = "Appropriate Unit Name"
Radius =1
Number_of_Points = 12
First_Pt = 00
Last_Pt = 11
Point_Names = "AAW Patrol Zone-"
---------------------------------------------------
local unit = ScenEdit_GetUnit({side=Owner, name=Unit_Name})
draw_circle({latitude=unit.latitude, longitude=unit.longitude}, Radius, First_Pt, Last_Pt, Number_of_Points, Point_Names)
---------------------------------------------------
“There is no limit to what a man can do so long as he does not care a straw who gets the credit for it.”

Charles Edward Montague, English novelist and essayist
~Disenchantment, ch. 15 (1922)
User avatar
SeaQueen
Posts: 1338
Joined: Sat Apr 14, 2007 4:20 am
Location: Washington D.C.

RE: Define Prosecution Area: circle. How?

Post by SeaQueen »

ORIGINAL: stww2
I never even realized that was a thing-I guess you learn something new every day!

It's one of the best kept secrets of Command.


User avatar
Kushan04
Posts: 692
Joined: Tue Jun 28, 2005 9:27 pm

RE: Define Prosecution Area: circle. How?

Post by Kushan04 »

ORIGINAL: stww2

I never even realized that was a thing-I guess you learn something new every day!

Just to clarify a little bit, ctrl + right click directly on a unit will bring up the unit orders menu, ctrl + right click on an empty area will bring up the reference point options.
apoll
Posts: 54
Joined: Wed Jun 20, 2007 10:08 am

RE: Define Prosecution Area: circle. How?

Post by apoll »

Tks all.
apoll
parmenio
Posts: 266
Joined: Thu Aug 06, 2009 8:02 am
Location: United Kingdom

RE: Define Prosecution Area: circle. How?

Post by parmenio »

Here's an alternative version of the script that reflects its use in the tutorial. Create a reference point called "PA-1" where you want the centre of the Prosecution Area. Change the radius (mine is at 20nm for no particular reason) and run it. "PA-1" is removed at the end.

function Draw_circle(a, b, First_Pt, Last_Pt, Num_Pts, txt) -- ([lat,lon], First_Pt, Last_Pt, Number_of_Points, name)
if txt == nil then
txt = ""
end
lat1 = a.latitude
lon1 = a.longitude
r = b / 60
-----
for i = First_Pt, Last_Pt do -- Consecutive integer numbers
th = 2 * math.pi * i / Num_Pts
rlat = lat1 + r * math.cos(th)
rlon = lon1 + r * math.sin(th) / math.cos(math.rad(lat1))
ScenEdit_AddReferencePoint(
{
side = "PlayerSide",
lat = rlat,
lon = rlon,
name = txt .. i,
highlighted = "yes"
}
)
end
end
---------------------------------------------------
Radius = 20
Number_of_Points = 12
First_Pt = 00
Last_Pt = 11
Point_Names = "AAW Patrol Zone-"
---------------------------------------------------
local points = ScenEdit_GetReferencePoints({side="PlayerSide", area={"PA-1"}})
Draw_circle(
{latitude = points[1].latitude, longitude = points[1].longitude},
Radius,
First_Pt,
Last_Pt,
Number_of_Points,
Point_Names
)
ScenEdit_DeleteReferencePoint({side="PlayerSide", name="PA-1"})
WDS Modern Air Power | WDS Naval Campaigns | WDS Squad Battles | WDS Strategic War
Post Reply

Return to “Command: Modern Operations series”