mirror of
https://github.com/FlightControl-Master/MOOSE.git
synced 2025-10-29 16:58:06 +00:00
Progress
This commit is contained in:
@@ -121,9 +121,9 @@ GroupZoneCompletely = GROUP:FindByName( "Zone Completely" )
|
||||
GroupZonePartly = GROUP:FindByName( "Zone Partly" )
|
||||
GroupZoneNot = GROUP:FindByName( "Zone Not" )
|
||||
|
||||
ZoneCompletely = ZONE_POLYGON:New( "Zone Completely", GroupZoneCompletely ):SmokeZone( POINT_VEC3.SmokeColor.White )
|
||||
ZonePartly = ZONE_POLYGON:New( "Zone Partly", GroupZonePartly ):SmokeZone( POINT_VEC3.SmokeColor.White )
|
||||
ZoneNot = ZONE_POLYGON:New( "Zone Not", GroupZoneNot ):SmokeZone( POINT_VEC3.SmokeColor.White )
|
||||
ZoneCompletely = ZONE_POLYGON:New( "Zone Completely", GroupZoneCompletely ):SmokeZone( SMOKECOLOR.White )
|
||||
ZonePartly = ZONE_POLYGON:New( "Zone Partly", GroupZonePartly ):SmokeZone( SMOKECOLOR.White )
|
||||
ZoneNot = ZONE_POLYGON:New( "Zone Not", GroupZoneNot ):SmokeZone( SMOKECOLOR.White )
|
||||
|
||||
SetVehicleCompletely:ForEachGroupCompletelyInZone( ZoneCompletely,
|
||||
--- @param Wrapper.Group#GROUP MooseGroup
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
|
||||
-- This test mission is a test bed for the TASKING framework.
|
||||
-- It creates an head quarters (HQ), which contains one mission with one task to be accomplished.
|
||||
-- When the pilot joins the plane, it will need to accept the task using the HQ menu.
|
||||
@@ -102,8 +103,27 @@ FsmSEADTemplate:AddScoreProcess( "Updated", "Account", "Failed", "failed to dest
|
||||
FsmSEADTemplate:AddScore( "Success", "Destroyed all target radars", 250 )
|
||||
FsmSEADTemplate:AddScore( "Failed", "Failed to destroy all target radars", -100 )
|
||||
|
||||
|
||||
|
||||
--local TestTask = TASK_BASE:New( Mission, SEADSet, "TEST TASK", "TEST" )
|
||||
--TestTask:E("Clean TestTask")
|
||||
--TestTask = nil
|
||||
--collectgarbage()
|
||||
--
|
||||
--local TestUnit = GROUP:FindByName( "HQ" ):GetUnit(1)
|
||||
--
|
||||
--local fsm = FSM_PROCESS:New( TestUnit, TaskSEAD )
|
||||
--
|
||||
--fsm:AddProcess("test","test",FSM_ACCOUNT_DEADS:New( TargetSet, "SEAD" ))
|
||||
--
|
||||
----Mission:AddTask(fsm)
|
||||
--
|
||||
--fsm:E("CLEAN fsm")
|
||||
--fsm = nil
|
||||
--collectgarbage()
|
||||
--
|
||||
--
|
||||
--TaskSEAD:E("CLEAN TASK")
|
||||
--TaskSEAD = nil
|
||||
--collectgarbage()
|
||||
|
||||
function FsmSEADTemplate:onenterUpdated( TaskUnit )
|
||||
self:E( { self } )
|
||||
@@ -112,9 +132,13 @@ function FsmSEADTemplate:onenterUpdated( TaskUnit )
|
||||
end
|
||||
|
||||
|
||||
local TaskSEAD2 = TASK_BASE:New( Mission, SEADSet, "SEAD Radars Vector 2", "SEAD" ) -- Tasking.Task#TASK_BASE
|
||||
TaskSEAD2:SetFsmTemplate( TaskSEAD:GetFsmTemplate():Copy() )
|
||||
--local TaskSEAD2 = TASK_BASE:New( Mission, SEADSet, "SEAD Radars Vector 2", "SEAD" ) -- Tasking.Task#TASK_BASE
|
||||
--TaskSEAD2:SetFsmTemplate( TaskSEAD:GetFsmTemplate():Copy() )
|
||||
--Mission:AddTask( TaskSEAD2 )
|
||||
|
||||
TaskSEAD = nil
|
||||
FsmSEADTemplate = nil
|
||||
|
||||
HQ:SetMenu()
|
||||
|
||||
collectgarbage()
|
||||
|
||||
Binary file not shown.
@@ -6,7 +6,7 @@
|
||||
local GroupInside = GROUP:FindByName( "Test Inside Polygon" )
|
||||
local GroupOutside = GROUP:FindByName( "Test Outside Polygon" )
|
||||
|
||||
local ZoneA = ZONE:New( "Zone A" ):SmokeZone( POINT_VEC3.SmokeColor.White, 90 )
|
||||
local ZoneA = ZONE:New( "Zone A" ):SmokeZone( SMOKECOLOR.White, 90 )
|
||||
|
||||
Messager = SCHEDULER:New( nil,
|
||||
function()
|
||||
|
||||
@@ -7,7 +7,7 @@ local GroupInside = GROUP:FindByName( "Test Inside Polygon" )
|
||||
local GroupOutside = GROUP:FindByName( "Test Outside Polygon" )
|
||||
|
||||
local House = STATIC:FindByName( "House" )
|
||||
local ZoneA = ZONE_RADIUS:New( "Zone A", House:GetPointVec2(), 300 ):SmokeZone( POINT_VEC3.SmokeColor.White, 90 )
|
||||
local ZoneA = ZONE_RADIUS:New( "Zone A", House:GetPointVec2(), 300 ):SmokeZone( SMOKECOLOR.White, 90 )
|
||||
|
||||
Messager = SCHEDULER:New( nil,
|
||||
function()
|
||||
|
||||
@@ -8,7 +8,7 @@ local GroupOutside = GROUP:FindByName( "Test Outside Polygon" )
|
||||
|
||||
local GroupPolygon = GROUP:FindByName( "Polygon A" )
|
||||
|
||||
local PolygonZone = ZONE_POLYGON:New( "Polygon A", GroupPolygon ):SmokeZone( POINT_VEC3.SmokeColor.White, 20 )
|
||||
local PolygonZone = ZONE_POLYGON:New( "Polygon A", GroupPolygon ):SmokeZone( SMOKECOLOR.White, 20 )
|
||||
|
||||
Messager = SCHEDULER:New( nil,
|
||||
function()
|
||||
|
||||
Reference in New Issue
Block a user