* Added ZONE_OVAL. This can be useful for simulating the area of a view zone from an object looking down at the ground for example.
Can be constructed from a Mission Editor drawing.
* add to DB
Supports closed line segments, rects and freely drawn polygons.
Added the correct way of generating a point within a polygon with trial and error
Added a way to get the surface area.
Added a helper class (_ZONE_TRIANGLE), which shouldn't ever be used on its own. It's there to support the update ZONE_POLYGON.
Some test code, assuming there's a poygon drawn in the mission editor called "poly":
```Lua
-- make a new zone from a drawing
poly = ZONE_POLYGON:NewFromDrawing("poly")
-- draw the zone for everyone, include the individual triangles that make up the polygon
poly:DrawZone(-1, {1,0,0}, 1, {1,0,0}, 255, 4, false, true)
-- generate 500 random points, evenly distributed in the polygon
for i=1, 500 do
COORDINATE:NewFromVec2(poly:GetRandomVec2()):CircleToAll(1000)
end
-- remove the drawing from the game
poly:UndrawZone()
```
* Added option movecratesbeforebuild
* Added option surfacetypes for build-in reloads
* Inject function can optionally take surfacetypes
* Inject function can use the center of the zone instead of a random position
#EVENT
* Handle landing event if the place is a SCENERY object (helopad on a map, but not an airbase)
#ZONE
* docu corrections
Fix documentation references.
Correct spelling errors.
Remove empty whitespaces.
Correct a single mis-spelled ZONE_BASE variable, see 'Core/Zone.lua' (variable "Sureface" -> "Surface", no references to mis-spelled "Sureface" throughout the codebase).
Correct mis-spelling of "coaltion" in 'Functional/Mantis.lua', corrected to "coalition".
* #ZONE * Fixed ZONE_RADIUS Not being added to _Database
Bugfix for #1797.
ZONE_RADIUS was not being registered within the _Database table, thus for CTLD, the Zone could not be found for moving units to ZONE_RADIUS zones. Because other Zone types inherit ZONE_RADIUS, I've added a RegisterZone parameter that is default to true, and modified the inheritance of the other Zone types to register the zone in the _Database depending if the zone does not get registered in that zone type.
* #ZONE * Updated ZONE_RADIUS RegisterZone to DoNotRegisterZone
Changed RegisterZone to DoNotRegisterZone and updated the different zone types values for RegisterZone.
Suggested by Applevangelist.
Co-authored-by: Jason du Plessis <jason.duplessis@ebtax.co.za>
* General minor
Code formatting and minor typo/document fixes.
* Update Marker.lua
Code formatting and minor typo/document fixes. Note specifically the correction of "self.tocoaliton" to "self.tocoalition".
- Implement Scheduled Trace - Now source and line number are shown for scheduled calls.
- Info lines are now shown where appropriate.
- The width of trace for the class name is now 25 characters instead of 20.
- Remove from ZONE_GOAL the Zone field, and make it inherit from ZONE_BASE instead of FSM!
- Rework the new inheritance tree in the code. (Remove .Zone fields).
- Implement the determination of attack and defense zones.
- Reworked the TaskInfo to include Type and ShowKey.
- Flash A2G Tasking Details. Added menu option.
FOX v0.6.0
- Missile target constantly updated.
- Increased safety distance to 200 m.
- Added safety distance for BIG missiles > 50 kg TNT as 400 m.
- More output to dcs.log file.
SPAWN
- enabled uncontrolled
UTILS
- LLDMS accurracy fix.
AI_A2A_DISPATCHER
- Squadron visible improvements
ZONE
- Added MarkZone function for F10 zone markings.
AI_PATROL_ZONE
- Some WP code improvements.