mirror of
https://github.com/FlightControl-Master/MOOSE_Demos.git
synced 2025-08-15 10:37:47 +00:00
Updated Moose.lua
This commit is contained in:
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -1,57 +1,57 @@
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 25.03.2017
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 24.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Scheduler.html
|
||||
--
|
||||
-- # Description:
|
||||
--
|
||||
-- Three air units are flying and are commanded to return a specific airbase.
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Observe group Air1 will return to Batumi after 10 seconds.
|
||||
-- 2. Observe group Air2 will return to Kobuleti after 300 seconds.
|
||||
-- - It was planned to land at Kutaisi in mission editor.
|
||||
-- 3. Observe group Air3 will return to the home (landing) airbase after 300 seconds.
|
||||
-- - It was planned to land at Kutaisi in mission editor.
|
||||
|
||||
--- Function to send RouteRTB command to the group
|
||||
-- @param Wrapper.Group#GROUP AirGroup
|
||||
function ReturnToBatumi( AirGroup )
|
||||
AirGroup:MessageToAll("ReturnToBatumi", 30)
|
||||
AirGroup:RouteRTB( AIRBASE:FindByName("Batumi") )
|
||||
end
|
||||
|
||||
--- Function to send RouteRTB command to the group
|
||||
-- @param Wrapper.Group#GROUP AirGroup
|
||||
function ReturnToKobuleti( AirGroup )
|
||||
AirGroup:MessageToAll("ReturnToKobuleti", 30)
|
||||
AirGroup:RouteRTB( AIRBASE:FindByName("Kobuleti") )
|
||||
end
|
||||
|
||||
--- Function to send RouteRTB command to the group
|
||||
-- @param Wrapper.Group#GROUP AirGroup
|
||||
function ReturnToHome( AirGroup )
|
||||
AirGroup:MessageToAll("ReturnToHome", 30)
|
||||
AirGroup:RouteRTB()
|
||||
end
|
||||
|
||||
-- Get needed group objects:
|
||||
Air1Group = GROUP:FindByName( "Air1" )
|
||||
Air2Group = GROUP:FindByName( "Air2" )
|
||||
Air3Group = GROUP:FindByName( "Air3" )
|
||||
|
||||
-- Setup different schedulers:
|
||||
Scheduler = SCHEDULER:New( nil )
|
||||
ScheduleIDAir1 = Scheduler:Schedule(nil, ReturnToBatumi, { Air1Group }, 10 )
|
||||
ScheduleIDAir2 = Scheduler:Schedule(nil, ReturnToKobuleti, { Air2Group }, 300 )
|
||||
ScheduleIDAir3 = Scheduler:Schedule(nil, ReturnToHome, { Air3Group }, 300 )
|
||||
|
||||
-- Inform player about the schudule:
|
||||
Air1Group:MessageToAll("Air1 will RTB to Batumi in 10 seconds", 30 )
|
||||
Air2Group:MessageToAll("Air2 will RTB to Kobuleti in 300 seconds (~12:05:00)", 60 )
|
||||
Air3Group:MessageToAll("Air3 will RTB to Kutaisi in 300 seconds (~12:05:00)", 60 )
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 25.03.2017
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 24.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Scheduler.html
|
||||
--
|
||||
-- # Description:
|
||||
--
|
||||
-- Three air units are flying and are commanded to return a specific airbase.
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Observe group Air1 will return to Batumi after 10 seconds.
|
||||
-- 2. Observe group Air2 will return to Kobuleti after 300 seconds.
|
||||
-- - It was planned to land at Kutaisi in mission editor.
|
||||
-- 3. Observe group Air3 will return to the home (landing) airbase after 300 seconds.
|
||||
-- - It was planned to land at Kutaisi in mission editor.
|
||||
|
||||
--- Function to send RouteRTB command to the group
|
||||
-- @param Wrapper.Group#GROUP AirGroup
|
||||
function ReturnToBatumi( AirGroup )
|
||||
AirGroup:MessageToAll("ReturnToBatumi", 30)
|
||||
AirGroup:RouteRTB( AIRBASE:FindByName("Batumi") )
|
||||
end
|
||||
|
||||
--- Function to send RouteRTB command to the group
|
||||
-- @param Wrapper.Group#GROUP AirGroup
|
||||
function ReturnToKobuleti( AirGroup )
|
||||
AirGroup:MessageToAll("ReturnToKobuleti", 30)
|
||||
AirGroup:RouteRTB( AIRBASE:FindByName("Kobuleti") )
|
||||
end
|
||||
|
||||
--- Function to send RouteRTB command to the group
|
||||
-- @param Wrapper.Group#GROUP AirGroup
|
||||
function ReturnToHome( AirGroup )
|
||||
AirGroup:MessageToAll("ReturnToHome", 30)
|
||||
AirGroup:RouteRTB()
|
||||
end
|
||||
|
||||
-- Get needed group objects:
|
||||
Air1Group = GROUP:FindByName( "Air1" )
|
||||
Air2Group = GROUP:FindByName( "Air2" )
|
||||
Air3Group = GROUP:FindByName( "Air3" )
|
||||
|
||||
-- Setup different schedulers:
|
||||
Scheduler = SCHEDULER:New( nil )
|
||||
ScheduleIDAir1 = Scheduler:Schedule(nil, ReturnToBatumi, { Air1Group }, 10 )
|
||||
ScheduleIDAir2 = Scheduler:Schedule(nil, ReturnToKobuleti, { Air2Group }, 300 )
|
||||
ScheduleIDAir3 = Scheduler:Schedule(nil, ReturnToHome, { Air3Group }, 300 )
|
||||
|
||||
-- Inform player about the schudule:
|
||||
Air1Group:MessageToAll("Air1 will RTB to Batumi in 10 seconds", 30 )
|
||||
Air2Group:MessageToAll("Air2 will RTB to Kobuleti in 300 seconds (~12:05:00)", 60 )
|
||||
Air3Group:MessageToAll("Air3 will RTB to Kutaisi in 300 seconds (~12:05:00)", 60 )
|
||||
|
||||
Binary file not shown.
@@ -1,39 +1,39 @@
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 20.10.2018
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 25.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Point.html
|
||||
--
|
||||
-- # Description:
|
||||
--
|
||||
-- An APC is placed in the mission editor without any waypoints.
|
||||
-- We will give him a waypoint by the script and task him to move.
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Observe the APC to drive 1km to the east.
|
||||
|
||||
-- Get needed object of APC.
|
||||
local GroundGroup = GROUP:FindByName( "Vehicle" )
|
||||
|
||||
-- Get the current coordinate of APC.
|
||||
FromCoord = GroundGroup:GetCoordinate()
|
||||
|
||||
-- From the current coordinate, calculate 1km away with an angle of 90 degrees (south).
|
||||
ToCoord = FromCoord:Translate( 1000, 90 )
|
||||
|
||||
-- Create an empty list of route points.
|
||||
RoutePoints = {}
|
||||
|
||||
-- Create a list of "ground route points", which is a "point" structure that can be given as a parameter to a Task.
|
||||
RoutePoints[#RoutePoints+1] = FromCoord:WaypointGround( 0 ) -- Parameters: Speed
|
||||
RoutePoints[#RoutePoints+1] = ToCoord:WaypointGround( 60, "Cone" ) -- Parameters: Speed, Formation
|
||||
|
||||
-- Create a combo task, that creates a route task to the RoutePoint
|
||||
RouteTask = GroundGroup:TaskRoute( RoutePoints )
|
||||
|
||||
-- Set the task to be executed by the GroundGroup
|
||||
GroundGroup:SetTask( RouteTask, 1 )
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 20.10.2018
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 25.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Point.html
|
||||
--
|
||||
-- # Description:
|
||||
--
|
||||
-- An APC is placed in the mission editor without any waypoints.
|
||||
-- We will give him a waypoint by the script and task him to move.
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Observe the APC to drive 1km to the east.
|
||||
|
||||
-- Get needed object of APC.
|
||||
local GroundGroup = GROUP:FindByName( "Vehicle" )
|
||||
|
||||
-- Get the current coordinate of APC.
|
||||
FromCoord = GroundGroup:GetCoordinate()
|
||||
|
||||
-- From the current coordinate, calculate 1km away with an angle of 90 degrees (south).
|
||||
ToCoord = FromCoord:Translate( 1000, 90 )
|
||||
|
||||
-- Create an empty list of route points.
|
||||
RoutePoints = {}
|
||||
|
||||
-- Create a list of "ground route points", which is a "point" structure that can be given as a parameter to a Task.
|
||||
RoutePoints[#RoutePoints+1] = FromCoord:WaypointGround( 0 ) -- Parameters: Speed
|
||||
RoutePoints[#RoutePoints+1] = ToCoord:WaypointGround( 60, "Cone" ) -- Parameters: Speed, Formation
|
||||
|
||||
-- Create a combo task, that creates a route task to the RoutePoint
|
||||
RouteTask = GroundGroup:TaskRoute( RoutePoints )
|
||||
|
||||
-- Set the task to be executed by the GroundGroup
|
||||
GroundGroup:SetTask( RouteTask, 1 )
|
||||
|
||||
Binary file not shown.
@@ -1,29 +1,29 @@
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 20.10.2018
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 25.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Point.html
|
||||
--
|
||||
-- # Description:
|
||||
--
|
||||
-- An APC is placed in the mission editor without any waypoints.
|
||||
-- We will give him waypoints by the script and task him to move.
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Observe the APC to drive 1km to the east.
|
||||
|
||||
-- Get needed object of APC.
|
||||
local GroundGroup = GROUP:FindByName( "Vehicle" )
|
||||
|
||||
-- Get the current coordinate of GroundGroup.
|
||||
FromCoord = GroundGroup:GetCoordinate()
|
||||
|
||||
-- From the current coordinate, calculate 1km away with an angle of 180 degrees (south).
|
||||
ToCoord = FromCoord:Translate( 1000, 90 )
|
||||
|
||||
-- Create a combo task, that creates a route task to the RoutePoint.
|
||||
GroundGroup:TaskRouteToVec2( ToCoord:GetVec2(), 60 ) -- Parameters: Vec2 & Speed
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 20.10.2018
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 25.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Point.html
|
||||
--
|
||||
-- # Description:
|
||||
--
|
||||
-- An APC is placed in the mission editor without any waypoints.
|
||||
-- We will give him waypoints by the script and task him to move.
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Observe the APC to drive 1km to the east.
|
||||
|
||||
-- Get needed object of APC.
|
||||
local GroundGroup = GROUP:FindByName( "Vehicle" )
|
||||
|
||||
-- Get the current coordinate of GroundGroup.
|
||||
FromCoord = GroundGroup:GetCoordinate()
|
||||
|
||||
-- From the current coordinate, calculate 1km away with an angle of 180 degrees (south).
|
||||
ToCoord = FromCoord:Translate( 1000, 90 )
|
||||
|
||||
-- Create a combo task, that creates a route task to the RoutePoint.
|
||||
GroundGroup:TaskRouteToVec2( ToCoord:GetVec2(), 60 ) -- Parameters: Vec2 & Speed
|
||||
|
||||
Binary file not shown.
@@ -1,58 +1,58 @@
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 08.08.2011
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 25.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Point.html
|
||||
--
|
||||
-- # Description:
|
||||
--
|
||||
-- An APC is placed in the mission editor without any waypoints.
|
||||
-- We will give him waypoints by the script and task him to move.
|
||||
-- On the target waypoint a task is added to call the function RouteToZone again.
|
||||
-- Because of this the vehicle will drive endless from one random zone to another.
|
||||
-- Note: math.random is not good with small numbers so e.g. Zone 1 is selected less frequently than zone 3.
|
||||
-- Note: The script does not prevent the same zone from being selected several times in succession.
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Observe the APC to drive between the zones.
|
||||
|
||||
-- Create a list of zone objects.
|
||||
local ZoneList = {
|
||||
ZONE:New( "ZONE1" ),
|
||||
ZONE:New( "ZONE2" ),
|
||||
ZONE:New( "ZONE3" ),
|
||||
ZONE:New( "ZONE4" ),
|
||||
ZONE:New( "ZONE5" )
|
||||
}
|
||||
|
||||
-- Get needed object of APC.
|
||||
GroundGroup = GROUP:FindByName( "Vehicle" )
|
||||
|
||||
--- @param Wrapper.Group#GROUP GroundGroup
|
||||
function RouteToZone( Vehicle, ZoneRoute )
|
||||
local Route = {}
|
||||
|
||||
-- Get the current coordinate of the Vehicle
|
||||
local FromCoord = Vehicle:GetCoordinate()
|
||||
|
||||
-- Select a random Zone and get the Coordinate of the new Zone.
|
||||
local RandomZone = ZoneList[ math.random( 1, #ZoneList ) ] -- Core.Zone#ZONE
|
||||
local ToCoord = RandomZone:GetCoordinate()
|
||||
Vehicle:MessageToAll( "Moving to zone " .. RandomZone:GetName(), 20 )
|
||||
|
||||
-- Create a task object, which will call this function.
|
||||
local TaskRouteToZone = Vehicle:TaskFunction( "RouteToZone", RandomZone )
|
||||
|
||||
-- Create a list of ground waypoints. Add the task object to the target waypoint.
|
||||
-- If the vehicle will reach the waypoint the function will be triggered again.
|
||||
Route[#Route+1] = FromCoord:WaypointGround( 72 )
|
||||
Route[#Route+1] = ToCoord:WaypointGround( 72, "Vee", {TaskRouteToZone} )
|
||||
|
||||
Vehicle:Route( Route, 3 ) -- Follow the Route after 3 seconds.
|
||||
end
|
||||
|
||||
RouteToZone( GroundGroup, ZoneList[1] )
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 08.08.2011
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 25.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Point.html
|
||||
--
|
||||
-- # Description:
|
||||
--
|
||||
-- An APC is placed in the mission editor without any waypoints.
|
||||
-- We will give him waypoints by the script and task him to move.
|
||||
-- On the target waypoint a task is added to call the function RouteToZone again.
|
||||
-- Because of this the vehicle will drive endless from one random zone to another.
|
||||
-- Note: math.random is not good with small numbers so e.g. Zone 1 is selected less frequently than zone 3.
|
||||
-- Note: The script does not prevent the same zone from being selected several times in succession.
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Observe the APC to drive between the zones.
|
||||
|
||||
-- Create a list of zone objects.
|
||||
local ZoneList = {
|
||||
ZONE:New( "ZONE1" ),
|
||||
ZONE:New( "ZONE2" ),
|
||||
ZONE:New( "ZONE3" ),
|
||||
ZONE:New( "ZONE4" ),
|
||||
ZONE:New( "ZONE5" )
|
||||
}
|
||||
|
||||
-- Get needed object of APC.
|
||||
GroundGroup = GROUP:FindByName( "Vehicle" )
|
||||
|
||||
--- @param Wrapper.Group#GROUP GroundGroup
|
||||
function RouteToZone( Vehicle, ZoneRoute )
|
||||
local Route = {}
|
||||
|
||||
-- Get the current coordinate of the Vehicle
|
||||
local FromCoord = Vehicle:GetCoordinate()
|
||||
|
||||
-- Select a random Zone and get the Coordinate of the new Zone.
|
||||
local RandomZone = ZoneList[ math.random( 1, #ZoneList ) ] -- Core.Zone#ZONE
|
||||
local ToCoord = RandomZone:GetCoordinate()
|
||||
Vehicle:MessageToAll( "Moving to zone " .. RandomZone:GetName(), 20 )
|
||||
|
||||
-- Create a task object, which will call this function.
|
||||
local TaskRouteToZone = Vehicle:TaskFunction( "RouteToZone", RandomZone )
|
||||
|
||||
-- Create a list of ground waypoints. Add the task object to the target waypoint.
|
||||
-- If the vehicle will reach the waypoint the function will be triggered again.
|
||||
Route[#Route+1] = FromCoord:WaypointGround( 72 )
|
||||
Route[#Route+1] = ToCoord:WaypointGround( 72, "Vee", {TaskRouteToZone} )
|
||||
|
||||
Vehicle:Route( Route, 3 ) -- Follow the Route after 3 seconds.
|
||||
end
|
||||
|
||||
RouteToZone( GroundGroup, ZoneList[1] )
|
||||
|
||||
Binary file not shown.
@@ -1,54 +1,54 @@
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 08.08.2017
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 24.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Zone.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Point.html
|
||||
--
|
||||
-- # Description:
|
||||
-- In this mission a vehicle drive (endless) to random zones when a waypoint has been reached.
|
||||
|
||||
-- Create a list of all zones in the mission.
|
||||
local ZoneList = {
|
||||
ZONE:New( "ZONE1" ),
|
||||
ZONE:New( "ZONE2" ),
|
||||
ZONE:New( "ZONE3" ),
|
||||
ZONE:New( "ZONE4" ),
|
||||
ZONE:New( "ZONE5" ),
|
||||
}
|
||||
|
||||
-- Get object of the APC.
|
||||
VehicleGroup = GROUP:FindByName( "APC" )
|
||||
|
||||
--- Function to ReRoute the APC to another zone.
|
||||
-- @param Wrapper.Group#GROUP RoutedGroup
|
||||
function ReRoute( VehicleGroup )
|
||||
local ZoneNumber = math.random( 1, #ZoneList )
|
||||
|
||||
-- Write informations to the log.
|
||||
VehicleGroup:E( "Routing" )
|
||||
VehicleGroup:E( ZoneNumber )
|
||||
-- Print informations on the screen
|
||||
VehicleGroup:MessageToAll( "Routing to Zone" .. tostring( ZoneNumber ),30 )
|
||||
|
||||
-- Create Waypoints.
|
||||
local FromCoord = VehicleGroup:GetCoordinate() -- Core.Point#COORDINATE
|
||||
local FromWP = FromCoord:WaypointGround()
|
||||
|
||||
local ZoneTo = ZoneList[ ZoneNumber ] -- Core.Zone#ZONE
|
||||
local ToCoord = ZoneTo:GetCoordinate()
|
||||
local ToWP = ToCoord:WaypointGround( 72, "Vee" ) -- Speed 72 km/h, formation Vee.
|
||||
|
||||
-- Create a Task, which will be executed if the waypoint is reached.
|
||||
-- It will call this function again and because of that the APC will drive endless from one random point to antoher.
|
||||
local TaskReRoute = VehicleGroup:TaskFunction( "ReRoute" )
|
||||
VehicleGroup:SetTaskWaypoint( ToWP, TaskReRoute )
|
||||
|
||||
VehicleGroup:Route( { FromWP, ToWP }, 1 )
|
||||
end
|
||||
|
||||
ReRoute( VehicleGroup )
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 08.08.2017
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 24.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Zone.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Point.html
|
||||
--
|
||||
-- # Description:
|
||||
-- In this mission a vehicle drive (endless) to random zones when a waypoint has been reached.
|
||||
|
||||
-- Create a list of all zones in the mission.
|
||||
local ZoneList = {
|
||||
ZONE:New( "ZONE1" ),
|
||||
ZONE:New( "ZONE2" ),
|
||||
ZONE:New( "ZONE3" ),
|
||||
ZONE:New( "ZONE4" ),
|
||||
ZONE:New( "ZONE5" ),
|
||||
}
|
||||
|
||||
-- Get object of the APC.
|
||||
VehicleGroup = GROUP:FindByName( "APC" )
|
||||
|
||||
--- Function to ReRoute the APC to another zone.
|
||||
-- @param Wrapper.Group#GROUP RoutedGroup
|
||||
function ReRoute( VehicleGroup )
|
||||
local ZoneNumber = math.random( 1, #ZoneList )
|
||||
|
||||
-- Write informations to the log.
|
||||
VehicleGroup:E( "Routing" )
|
||||
VehicleGroup:E( ZoneNumber )
|
||||
-- Print informations on the screen
|
||||
VehicleGroup:MessageToAll( "Routing to Zone" .. tostring( ZoneNumber ),30 )
|
||||
|
||||
-- Create Waypoints.
|
||||
local FromCoord = VehicleGroup:GetCoordinate() -- Core.Point#COORDINATE
|
||||
local FromWP = FromCoord:WaypointGround()
|
||||
|
||||
local ZoneTo = ZoneList[ ZoneNumber ] -- Core.Zone#ZONE
|
||||
local ToCoord = ZoneTo:GetCoordinate()
|
||||
local ToWP = ToCoord:WaypointGround( 72, "Vee" ) -- Speed 72 km/h, formation Vee.
|
||||
|
||||
-- Create a Task, which will be executed if the waypoint is reached.
|
||||
-- It will call this function again and because of that the APC will drive endless from one random point to antoher.
|
||||
local TaskReRoute = VehicleGroup:TaskFunction( "ReRoute" )
|
||||
VehicleGroup:SetTaskWaypoint( ToWP, TaskReRoute )
|
||||
|
||||
VehicleGroup:Route( { FromWP, ToWP }, 1 )
|
||||
end
|
||||
|
||||
ReRoute( VehicleGroup )
|
||||
|
||||
Binary file not shown.
@@ -1,148 +1,148 @@
|
||||
---
|
||||
-- Author: Wingthor
|
||||
-- Created: 22.08.2020
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 23.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Point.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Scheduler.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Spawn.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Static.html
|
||||
--
|
||||
-- # Description:
|
||||
-- Mission illustrates how to make an air GROUP do a bomb run by script.
|
||||
-- One template group is placed on map by DCS's Mission Editor.
|
||||
-- Template is set to TASK "Ground Attack" and given proper ordonance in Mission Editor.
|
||||
-- One function handles both attacks by give targets coordinates as arguments.
|
||||
-- This also shows how to do a delayed function call using BASE:ScheduleOnce function.
|
||||
-- Mission also feature a helper function which will return a random waypoint between Airbase and Target.
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Start the mission and wait 5 seconds
|
||||
-- 2. Press F2/F10 to observe the attack run of the blue aircrafts
|
||||
-- 3. Use time acceleration to shorten waiting times
|
||||
|
||||
-- Enable tracing when the mission doesn't work as expected.
|
||||
--BASE:TraceOnOff(true)
|
||||
--BASE:TraceAll(true)
|
||||
|
||||
--- This function will make a random waypoint between two coordinates.
|
||||
-- @param Core.Point#COORDINATE TargetCoordinate Coordinate of the target
|
||||
-- @param Core.Point#COORDINATE InitCoordinate Initial Coordinate
|
||||
function MakeMiddleWaypoint (TargetCoordinate, InitCoordinate)
|
||||
BASE:F({TargetCoordinate,InitCoordinate})
|
||||
|
||||
-- If we can not resolve the parameters throw noting back so we don't break anything.
|
||||
if TargetCoordinate == nil or InitCoordinate == nil then return nil end
|
||||
|
||||
local _TargetCoordinate = TargetCoordinate -- Core.Point#COORDINATE
|
||||
local _InitCoordinate = InitCoordinate -- Core.Point#COORDINATE
|
||||
local Distance = TargetCoordinate:Get3DDistance( InitCoordinate )
|
||||
|
||||
if Distance < 30000 then
|
||||
return nil -- To close for us
|
||||
elseif Distance > 70000 then
|
||||
Distance = 70000
|
||||
else
|
||||
Distance = math.random(30000,70000)
|
||||
end -- This is max distance from target we want our Waypoint
|
||||
|
||||
local Direction = _TargetCoordinate:GetAngleDegrees(_TargetCoordinate:GetDirectionVec3(_InitCoordinate))
|
||||
|
||||
if Direction > 0 and Direction <=90 then -- North East
|
||||
return _TargetCoordinate:Translate( Distance, math.random(1,90) )
|
||||
elseif Direction > 90 and Direction <= 180 then -- South East
|
||||
return _TargetCoordinate:Translate( Distance, math.random(91,180) )
|
||||
elseif Direction > 180 and Direction <= 270 then -- South West then
|
||||
return _TargetCoordinate:Translate( Distance,math.random(181,270) )
|
||||
elseif Direction > 270 and Direction <= 360 then -- South West then then
|
||||
return _TargetCoordinate:Translate( Distance,math.random(271,360) )
|
||||
else
|
||||
BASE:E("--- Something wrong in function MakeMiddleWaypoint ---")
|
||||
return nil
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
--- Function to order a strike
|
||||
-- @param #string Group Name of the group
|
||||
-- @param Core.Point#COORDINATE Target Coordinates of the target
|
||||
-- @param #string Base Name of the home base
|
||||
-- @param #string TargetDescription Description of the target
|
||||
function PinpointStrike( Group, Target, Base, TargetDescription )
|
||||
BASE:F({ Group, Target, Base })
|
||||
|
||||
-- nil check for arguments.
|
||||
if Group == nil or Target == nil or Base == nil then return nil end
|
||||
|
||||
-- Make a default description
|
||||
if TargetDescription == nil then
|
||||
TargetDescription = "Bomb Target"
|
||||
end
|
||||
|
||||
-- Make a Random heading from the target which will serve as an IP (90-180°)
|
||||
local heading = math.random( 90, 180 )
|
||||
|
||||
-- Get targets vectors
|
||||
local targetVec = Target:GetVec2()
|
||||
|
||||
-- Make a Spawn counter
|
||||
if SpawnCounter == nil then
|
||||
SpawnCounter = 0
|
||||
else
|
||||
SpawnCounter = SpawnCounter + 1
|
||||
end
|
||||
|
||||
-- Spawn the bomber and return a GROUP object
|
||||
local SpawnBomber = SPAWN:NewWithAlias( Group, "Bomber_" .. tostring(SpawnCounter) )
|
||||
:OnSpawnGroup(
|
||||
--- @param
|
||||
function ( group )
|
||||
group:MessageToBlue( "Launching the Pinpoint strike", 40 )
|
||||
end, {}
|
||||
)
|
||||
|
||||
local homebasecoords = AIRBASE:FindByName(Base):GetCoordinate() --Core.Point#COORDINATE
|
||||
local bomber = SpawnBomber:SpawnAtAirbase( AIRBASE:FindByName( Base ), SPAWN.Takeoff.Cold )
|
||||
local task = bomber:TaskBombing( targetVec, false, "All", nil, heading, 10000)
|
||||
|
||||
--- Make a waypoint table
|
||||
local waypoints = {}
|
||||
|
||||
--- Get coordinate for Home Base
|
||||
local homecoords = AIRBASE:FindByName(Base):GetCoordinate():SetAltitude(8000):Translate(10 * 10000,300)
|
||||
|
||||
-- Make an ingress point for the bomber
|
||||
local IngressPoint = MakeMiddleWaypoint( Target, homebasecoords ) --Core.Point#COORDINATE
|
||||
if IngressPoint == nil then -- Its important to handle the edge cases so we don't break anything. Better throw something to log.
|
||||
BASE:E("--- Error in PinpointStrike target is too close to base ---" )
|
||||
return nil
|
||||
end
|
||||
|
||||
-- Set the coordinate altitude
|
||||
IngressPoint:SetAltitude(8000)
|
||||
|
||||
-- Add coordinates to table and make Waypoints
|
||||
waypoints[1] = homebasecoords:WaypointAirTakeOffParking()
|
||||
waypoints[2] = IngressPoint:WaypointAirTurningPoint( nil, 950, {task}, TargetDescription )
|
||||
waypoints[3] = homecoords:WaypointAirTurningPoint()
|
||||
waypoints[4] = homebasecoords:WaypointAirLanding()
|
||||
|
||||
-- Push the waypoint table the bomber
|
||||
bomber:Route( waypoints )
|
||||
|
||||
end
|
||||
|
||||
-- local targetCoords = ZONE:New("Blue Bridge"):GetCoordinate()
|
||||
local CommandCenterCoords = STATIC:FindByName( "SAM ControlCenter", false ):GetCoordinate() -- Core.Point#COORDINATE
|
||||
|
||||
-- I have added a small zone over a scenery object in order to grab the coordinates.
|
||||
local SceneryTargetCoordiate = ZONE:New("SceneryTarget"):GetCoordinate()
|
||||
|
||||
-- Call the function PinpointStrike 5 seconds after mission start with 4 parameters: Group, Target, Base, TargetDescription
|
||||
BASE:ScheduleOnce( 5, PinpointStrike, "Blue Owl 1-1", CommandCenterCoords, AIRBASE.Caucasus.Sukhumi_Babushara, "Bomb Command Center" )
|
||||
|
||||
-- Call the function PinpointStrike 10 seconds after mission start with 4 parameters: Group, Target, Base, TargetDescription
|
||||
BASE:ScheduleOnce( 10, PinpointStrike, "Blue Owl 1-1", SceneryTargetCoordiate, AIRBASE.Caucasus.Sukhumi_Babushara, "Bomb Commanders House" )
|
||||
---
|
||||
-- Author: Wingthor
|
||||
-- Created: 22.08.2020
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 23.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Point.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Scheduler.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Spawn.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Static.html
|
||||
--
|
||||
-- # Description:
|
||||
-- Mission illustrates how to make an air GROUP do a bomb run by script.
|
||||
-- One template group is placed on map by DCS's Mission Editor.
|
||||
-- Template is set to TASK "Ground Attack" and given proper ordonance in Mission Editor.
|
||||
-- One function handles both attacks by give targets coordinates as arguments.
|
||||
-- This also shows how to do a delayed function call using BASE:ScheduleOnce function.
|
||||
-- Mission also feature a helper function which will return a random waypoint between Airbase and Target.
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Start the mission and wait 5 seconds
|
||||
-- 2. Press F2/F10 to observe the attack run of the blue aircrafts
|
||||
-- 3. Use time acceleration to shorten waiting times
|
||||
|
||||
-- Enable tracing when the mission doesn't work as expected.
|
||||
--BASE:TraceOnOff(true)
|
||||
--BASE:TraceAll(true)
|
||||
|
||||
--- This function will make a random waypoint between two coordinates.
|
||||
-- @param Core.Point#COORDINATE TargetCoordinate Coordinate of the target
|
||||
-- @param Core.Point#COORDINATE InitCoordinate Initial Coordinate
|
||||
function MakeMiddleWaypoint (TargetCoordinate, InitCoordinate)
|
||||
BASE:F({TargetCoordinate,InitCoordinate})
|
||||
|
||||
-- If we can not resolve the parameters throw noting back so we don't break anything.
|
||||
if TargetCoordinate == nil or InitCoordinate == nil then return nil end
|
||||
|
||||
local _TargetCoordinate = TargetCoordinate -- Core.Point#COORDINATE
|
||||
local _InitCoordinate = InitCoordinate -- Core.Point#COORDINATE
|
||||
local Distance = TargetCoordinate:Get3DDistance( InitCoordinate )
|
||||
|
||||
if Distance < 30000 then
|
||||
return nil -- To close for us
|
||||
elseif Distance > 70000 then
|
||||
Distance = 70000
|
||||
else
|
||||
Distance = math.random(30000,70000)
|
||||
end -- This is max distance from target we want our Waypoint
|
||||
|
||||
local Direction = _TargetCoordinate:GetAngleDegrees(_TargetCoordinate:GetDirectionVec3(_InitCoordinate))
|
||||
|
||||
if Direction > 0 and Direction <=90 then -- North East
|
||||
return _TargetCoordinate:Translate( Distance, math.random(1,90) )
|
||||
elseif Direction > 90 and Direction <= 180 then -- South East
|
||||
return _TargetCoordinate:Translate( Distance, math.random(91,180) )
|
||||
elseif Direction > 180 and Direction <= 270 then -- South West then
|
||||
return _TargetCoordinate:Translate( Distance,math.random(181,270) )
|
||||
elseif Direction > 270 and Direction <= 360 then -- South West then then
|
||||
return _TargetCoordinate:Translate( Distance,math.random(271,360) )
|
||||
else
|
||||
BASE:E("--- Something wrong in function MakeMiddleWaypoint ---")
|
||||
return nil
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
--- Function to order a strike
|
||||
-- @param #string Group Name of the group
|
||||
-- @param Core.Point#COORDINATE Target Coordinates of the target
|
||||
-- @param #string Base Name of the home base
|
||||
-- @param #string TargetDescription Description of the target
|
||||
function PinpointStrike( Group, Target, Base, TargetDescription )
|
||||
BASE:F({ Group, Target, Base })
|
||||
|
||||
-- nil check for arguments.
|
||||
if Group == nil or Target == nil or Base == nil then return nil end
|
||||
|
||||
-- Make a default description
|
||||
if TargetDescription == nil then
|
||||
TargetDescription = "Bomb Target"
|
||||
end
|
||||
|
||||
-- Make a Random heading from the target which will serve as an IP (90-180°)
|
||||
local heading = math.random( 90, 180 )
|
||||
|
||||
-- Get targets vectors
|
||||
local targetVec = Target:GetVec2()
|
||||
|
||||
-- Make a Spawn counter
|
||||
if SpawnCounter == nil then
|
||||
SpawnCounter = 0
|
||||
else
|
||||
SpawnCounter = SpawnCounter + 1
|
||||
end
|
||||
|
||||
-- Spawn the bomber and return a GROUP object
|
||||
local SpawnBomber = SPAWN:NewWithAlias( Group, "Bomber_" .. tostring(SpawnCounter) )
|
||||
:OnSpawnGroup(
|
||||
--- @param
|
||||
function ( group )
|
||||
group:MessageToBlue( "Launching the Pinpoint strike", 40 )
|
||||
end, {}
|
||||
)
|
||||
|
||||
local homebasecoords = AIRBASE:FindByName(Base):GetCoordinate() --Core.Point#COORDINATE
|
||||
local bomber = SpawnBomber:SpawnAtAirbase( AIRBASE:FindByName( Base ), SPAWN.Takeoff.Cold )
|
||||
local task = bomber:TaskBombing( targetVec, false, "All", nil, heading, 10000)
|
||||
|
||||
--- Make a waypoint table
|
||||
local waypoints = {}
|
||||
|
||||
--- Get coordinate for Home Base
|
||||
local homecoords = AIRBASE:FindByName(Base):GetCoordinate():SetAltitude(8000):Translate(10 * 10000,300)
|
||||
|
||||
-- Make an ingress point for the bomber
|
||||
local IngressPoint = MakeMiddleWaypoint( Target, homebasecoords ) --Core.Point#COORDINATE
|
||||
if IngressPoint == nil then -- Its important to handle the edge cases so we don't break anything. Better throw something to log.
|
||||
BASE:E("--- Error in PinpointStrike target is too close to base ---" )
|
||||
return nil
|
||||
end
|
||||
|
||||
-- Set the coordinate altitude
|
||||
IngressPoint:SetAltitude(8000)
|
||||
|
||||
-- Add coordinates to table and make Waypoints
|
||||
waypoints[1] = homebasecoords:WaypointAirTakeOffParking()
|
||||
waypoints[2] = IngressPoint:WaypointAirTurningPoint( nil, 950, {task}, TargetDescription )
|
||||
waypoints[3] = homecoords:WaypointAirTurningPoint()
|
||||
waypoints[4] = homebasecoords:WaypointAirLanding()
|
||||
|
||||
-- Push the waypoint table the bomber
|
||||
bomber:Route( waypoints )
|
||||
|
||||
end
|
||||
|
||||
-- local targetCoords = ZONE:New("Blue Bridge"):GetCoordinate()
|
||||
local CommandCenterCoords = STATIC:FindByName( "SAM ControlCenter", false ):GetCoordinate() -- Core.Point#COORDINATE
|
||||
|
||||
-- I have added a small zone over a scenery object in order to grab the coordinates.
|
||||
local SceneryTargetCoordiate = ZONE:New("SceneryTarget"):GetCoordinate()
|
||||
|
||||
-- Call the function PinpointStrike 5 seconds after mission start with 4 parameters: Group, Target, Base, TargetDescription
|
||||
BASE:ScheduleOnce( 5, PinpointStrike, "Blue Owl 1-1", CommandCenterCoords, AIRBASE.Caucasus.Sukhumi_Babushara, "Bomb Command Center" )
|
||||
|
||||
-- Call the function PinpointStrike 10 seconds after mission start with 4 parameters: Group, Target, Base, TargetDescription
|
||||
BASE:ScheduleOnce( 10, PinpointStrike, "Blue Owl 1-1", SceneryTargetCoordiate, AIRBASE.Caucasus.Sukhumi_Babushara, "Bomb Commanders House" )
|
||||
|
||||
Binary file not shown.
@@ -1,52 +1,52 @@
|
||||
---
|
||||
-- Author: Targs35 (from 62nd Air Wing) & FlightControl
|
||||
-- Created: 11.01.2021
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 26.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Point.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Spawn.html
|
||||
--
|
||||
-- # Description:
|
||||
-- A tanker will start from Sochi-Adler.
|
||||
-- Two F-15C will also start from Sochi-Adler and join the tanker as escort.
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Start the mission and wait some seconds
|
||||
-- 2. Press F2/F10 to observe the aircrafts
|
||||
-- 3. Use time acceleration to shorten waiting times
|
||||
|
||||
-- Create Spawn Groups
|
||||
local Tanker_Texaco = SPAWN:New( "Tanker_Texaco_Droge" )
|
||||
:InitLimit( 1, 10 )
|
||||
:InitCleanUp( 240 )
|
||||
:SpawnScheduled( 60, .0 )
|
||||
|
||||
local Escort_Texaco_1 = SPAWN:New( "Escort_Texaco_F15C-1" )
|
||||
:InitLimit( 1, 20 )
|
||||
:InitCleanUp( 240 )
|
||||
:SpawnScheduled( 120, .1 )
|
||||
|
||||
local Escort_Texaco_2 = SPAWN:New( "Escort_Texaco_F15C" )
|
||||
:InitLimit( 1, 20 )
|
||||
:InitCleanUp( 240 )
|
||||
:SpawnScheduled( 120, .2 )
|
||||
|
||||
-- Spawn Groups into world
|
||||
local GroupTanker_Texaco = Tanker_Texaco:Spawn()
|
||||
local GroupEscort_Texaco_1 = Escort_Texaco_1:Spawn()
|
||||
local GroupEscort_Texaco_2 = Escort_Texaco_2:Spawn()
|
||||
|
||||
-- Define the distance from Tanker to Escort
|
||||
local PointVec1 = POINT_VEC3:New( -100, 20, 80 ) -- This is a Vec3 class.
|
||||
local PointVec2 = POINT_VEC3:New( -100, 20, 150 ) -- This is a Vec3 class.
|
||||
|
||||
-- Define Escort tasks
|
||||
local FollowDCSTask1 = GroupEscort_Texaco_1:TaskFollow( GroupTanker_Texaco, PointVec1:GetVec3() )
|
||||
local FollowDCSTask2 = GroupEscort_Texaco_2:TaskFollow( GroupTanker_Texaco, PointVec2:GetVec3() )
|
||||
GroupEscort_Texaco_1:SetTask( FollowDCSTask1, 1 )
|
||||
GroupEscort_Texaco_2:SetTask( FollowDCSTask2, 2 )
|
||||
|
||||
MESSAGE:New( "Tanker_Texaco Loaded", 25 ):ToAll()
|
||||
---
|
||||
-- Author: Targs35 (from 62nd Air Wing) & FlightControl
|
||||
-- Created: 11.01.2021
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 26.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Point.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Spawn.html
|
||||
--
|
||||
-- # Description:
|
||||
-- A tanker will start from Sochi-Adler.
|
||||
-- Two F-15C will also start from Sochi-Adler and join the tanker as escort.
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Start the mission and wait some seconds
|
||||
-- 2. Press F2/F10 to observe the aircrafts
|
||||
-- 3. Use time acceleration to shorten waiting times
|
||||
|
||||
-- Create Spawn Groups
|
||||
local Tanker_Texaco = SPAWN:New( "Tanker_Texaco_Droge" )
|
||||
:InitLimit( 1, 10 )
|
||||
:InitCleanUp( 240 )
|
||||
:SpawnScheduled( 60, .0 )
|
||||
|
||||
local Escort_Texaco_1 = SPAWN:New( "Escort_Texaco_F15C-1" )
|
||||
:InitLimit( 1, 20 )
|
||||
:InitCleanUp( 240 )
|
||||
:SpawnScheduled( 120, .1 )
|
||||
|
||||
local Escort_Texaco_2 = SPAWN:New( "Escort_Texaco_F15C" )
|
||||
:InitLimit( 1, 20 )
|
||||
:InitCleanUp( 240 )
|
||||
:SpawnScheduled( 120, .2 )
|
||||
|
||||
-- Spawn Groups into world
|
||||
local GroupTanker_Texaco = Tanker_Texaco:Spawn()
|
||||
local GroupEscort_Texaco_1 = Escort_Texaco_1:Spawn()
|
||||
local GroupEscort_Texaco_2 = Escort_Texaco_2:Spawn()
|
||||
|
||||
-- Define the distance from Tanker to Escort
|
||||
local PointVec1 = POINT_VEC3:New( -100, 20, 80 ) -- This is a Vec3 class.
|
||||
local PointVec2 = POINT_VEC3:New( -100, 20, 150 ) -- This is a Vec3 class.
|
||||
|
||||
-- Define Escort tasks
|
||||
local FollowDCSTask1 = GroupEscort_Texaco_1:TaskFollow( GroupTanker_Texaco, PointVec1:GetVec3() )
|
||||
local FollowDCSTask2 = GroupEscort_Texaco_2:TaskFollow( GroupTanker_Texaco, PointVec2:GetVec3() )
|
||||
GroupEscort_Texaco_1:SetTask( FollowDCSTask1, 1 )
|
||||
GroupEscort_Texaco_2:SetTask( FollowDCSTask2, 2 )
|
||||
|
||||
MESSAGE:New( "Tanker_Texaco Loaded", 25 ):ToAll()
|
||||
|
||||
Binary file not shown.
@@ -1,30 +1,30 @@
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 24.09.2017
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 26.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
--
|
||||
-- # Description:
|
||||
-- In this mission two vehicles drive their route in a repetitive way.
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Start the mission and wait some seconds.
|
||||
-- 2. Press F10 to observe the ship and the tank traveling around.
|
||||
-- 3. The boat will drive to the red markings on the F10 map.
|
||||
-- 4. The APC will drive to the placed cones.
|
||||
-- 5. Use time acceleration to shorten waiting times
|
||||
|
||||
-- Find the Vehicle and create a GROUP object.
|
||||
Vehicle = GROUP:FindByName( "Vehicle" )
|
||||
|
||||
-- Patrol the route of the Vehicle.
|
||||
Vehicle:PatrolRoute()
|
||||
|
||||
-- Find the Ship and create a GROUP object.
|
||||
Ship = GROUP:FindByName( "Ship" )
|
||||
|
||||
-- Patrol the route of the Ship.
|
||||
Ship:PatrolRoute()
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 24.09.2017
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 26.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
--
|
||||
-- # Description:
|
||||
-- In this mission two vehicles drive their route in a repetitive way.
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Start the mission and wait some seconds.
|
||||
-- 2. Press F10 to observe the ship and the tank traveling around.
|
||||
-- 3. The boat will drive to the red markings on the F10 map.
|
||||
-- 4. The APC will drive to the placed cones.
|
||||
-- 5. Use time acceleration to shorten waiting times
|
||||
|
||||
-- Find the Vehicle and create a GROUP object.
|
||||
Vehicle = GROUP:FindByName( "Vehicle" )
|
||||
|
||||
-- Patrol the route of the Vehicle.
|
||||
Vehicle:PatrolRoute()
|
||||
|
||||
-- Find the Ship and create a GROUP object.
|
||||
Ship = GROUP:FindByName( "Ship" )
|
||||
|
||||
-- Patrol the route of the Ship.
|
||||
Ship:PatrolRoute()
|
||||
|
||||
Binary file not shown.
@@ -1,29 +1,29 @@
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 24.09.2017
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 26.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
--
|
||||
-- # Description:
|
||||
-- This makes vehicles drive its route in a random way.
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Start the mission and wait some seconds.
|
||||
-- 2. Press F10 to observe the ship and the tank traveling around.
|
||||
-- 3. The boat will drive to a random red marking on the F10 map.
|
||||
-- 4. The APC will drive to a random one of the placed cones.
|
||||
|
||||
-- Find the Vehicle and create a GROUP object.
|
||||
Vehicle = GROUP:FindByName( "Vehicle" )
|
||||
|
||||
-- Patrol to a random chosen waypoint of the route at 120 km/h in "Vee" formation.
|
||||
Vehicle:PatrolRouteRandom( 120, "Vee" )
|
||||
|
||||
-- Find the Ship and create a GROUP object.
|
||||
Ship = GROUP:FindByName( "Ship" )
|
||||
|
||||
-- Patrol to a random chosen waypoint of the route at 120 km/h in "Vee" formation.
|
||||
Ship:PatrolRouteRandom( 120, "Vee" )
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 24.09.2017
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 26.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
--
|
||||
-- # Description:
|
||||
-- This makes vehicles drive its route in a random way.
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Start the mission and wait some seconds.
|
||||
-- 2. Press F10 to observe the ship and the tank traveling around.
|
||||
-- 3. The boat will drive to a random red marking on the F10 map.
|
||||
-- 4. The APC will drive to a random one of the placed cones.
|
||||
|
||||
-- Find the Vehicle and create a GROUP object.
|
||||
Vehicle = GROUP:FindByName( "Vehicle" )
|
||||
|
||||
-- Patrol to a random chosen waypoint of the route at 120 km/h in "Vee" formation.
|
||||
Vehicle:PatrolRouteRandom( 120, "Vee" )
|
||||
|
||||
-- Find the Ship and create a GROUP object.
|
||||
Ship = GROUP:FindByName( "Ship" )
|
||||
|
||||
-- Patrol to a random chosen waypoint of the route at 120 km/h in "Vee" formation.
|
||||
Ship:PatrolRouteRandom( 120, "Vee" )
|
||||
|
||||
Binary file not shown.
@@ -1,28 +1,28 @@
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 24.09.2017
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 26.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
--
|
||||
-- # Description:
|
||||
-- In this mission two vehicles drive its route selecting random points in a zone.
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Start the mission and wait some seconds.
|
||||
-- 2. Press F10 to observe the ship and the tank traveling around in the zones.
|
||||
-- 3. Use time acceleration to shorten waiting times
|
||||
|
||||
-- Find the Vehicles and create GROUP objects.
|
||||
Vehicle = GROUP:FindByName( "Vehicle" )
|
||||
Ship = GROUP:FindByName( "Ship" )
|
||||
|
||||
-- Find zones and create ZONE objects and mark both zones on the F10 map.
|
||||
local zoneVehicle = ZONE:New( "ZONEVEHICLE" ):DrawZone()
|
||||
local zoneShip = ZONE:New( "ZONESHIP" ):DrawZone()
|
||||
|
||||
-- Patrol to random points in the trigger zone at 120 km/h in Vee format.
|
||||
Vehicle:PatrolZones( { zoneVehicle }, 120, "Vee" )
|
||||
Ship:PatrolZones( { zoneShip }, 120, "Vee" )
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 24.09.2017
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 26.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
--
|
||||
-- # Description:
|
||||
-- In this mission two vehicles drive its route selecting random points in a zone.
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Start the mission and wait some seconds.
|
||||
-- 2. Press F10 to observe the ship and the tank traveling around in the zones.
|
||||
-- 3. Use time acceleration to shorten waiting times
|
||||
|
||||
-- Find the Vehicles and create GROUP objects.
|
||||
Vehicle = GROUP:FindByName( "Vehicle" )
|
||||
Ship = GROUP:FindByName( "Ship" )
|
||||
|
||||
-- Find zones and create ZONE objects and mark both zones on the F10 map.
|
||||
local zoneVehicle = ZONE:New( "ZONEVEHICLE" ):DrawZone()
|
||||
local zoneShip = ZONE:New( "ZONESHIP" ):DrawZone()
|
||||
|
||||
-- Patrol to random points in the trigger zone at 120 km/h in Vee format.
|
||||
Vehicle:PatrolZones( { zoneVehicle }, 120, "Vee" )
|
||||
Ship:PatrolZones( { zoneShip }, 120, "Vee" )
|
||||
|
||||
Binary file not shown.
@@ -1,37 +1,37 @@
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 24.09.2017
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 27.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Zone.html
|
||||
--
|
||||
-- # Description:
|
||||
-- In this mission two vehicles drive their routes selecting random points in random zones.
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Start the mission and wait some seconds.
|
||||
-- 2. Press F10 to observe the ship and the tank traveling around in the zones.
|
||||
-- 3. Use time acceleration to shorten waiting times
|
||||
|
||||
-- Find the Vehicles and create GROUP objects.
|
||||
Vehicle = GROUP:FindByName( "Vehicle" )
|
||||
Ship = GROUP:FindByName( "Ship" )
|
||||
|
||||
-- Patrol to random points in the zones ZONEVEHICLE1, ZONEVEHICLE2, ZONEVEHICLE3, at 120 km/h in Vee format.
|
||||
Vehicle:PatrolZones(
|
||||
{
|
||||
ZONE:New( "ZONEVEHICLE1" ):DrawZone(),
|
||||
ZONE:New( "ZONEVEHICLE2" ):DrawZone(),
|
||||
ZONE:New( "ZONEVEHICLE3" ):DrawZone()
|
||||
}, 120, "Vee" )
|
||||
|
||||
-- Patrol to random points in the zones ZONESHIP1, ZONESHIP2, ZONESHIP3, at 120 km/h in Vee format.
|
||||
Ship:PatrolZones(
|
||||
{
|
||||
ZONE:New( "ZONESHIP1" ):DrawZone(),
|
||||
ZONE:New( "ZONESHIP2" ):DrawZone(),
|
||||
ZONE:New( "ZONESHIP3" ):DrawZone()
|
||||
}, 120, "Vee" )
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 24.09.2017
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 27.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Zone.html
|
||||
--
|
||||
-- # Description:
|
||||
-- In this mission two vehicles drive their routes selecting random points in random zones.
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Start the mission and wait some seconds.
|
||||
-- 2. Press F10 to observe the ship and the tank traveling around in the zones.
|
||||
-- 3. Use time acceleration to shorten waiting times
|
||||
|
||||
-- Find the Vehicles and create GROUP objects.
|
||||
Vehicle = GROUP:FindByName( "Vehicle" )
|
||||
Ship = GROUP:FindByName( "Ship" )
|
||||
|
||||
-- Patrol to random points in the zones ZONEVEHICLE1, ZONEVEHICLE2, ZONEVEHICLE3, at 120 km/h in Vee format.
|
||||
Vehicle:PatrolZones(
|
||||
{
|
||||
ZONE:New( "ZONEVEHICLE1" ):DrawZone(),
|
||||
ZONE:New( "ZONEVEHICLE2" ):DrawZone(),
|
||||
ZONE:New( "ZONEVEHICLE3" ):DrawZone()
|
||||
}, 120, "Vee" )
|
||||
|
||||
-- Patrol to random points in the zones ZONESHIP1, ZONESHIP2, ZONESHIP3, at 120 km/h in Vee format.
|
||||
Ship:PatrolZones(
|
||||
{
|
||||
ZONE:New( "ZONESHIP1" ):DrawZone(),
|
||||
ZONE:New( "ZONESHIP2" ):DrawZone(),
|
||||
ZONE:New( "ZONESHIP3" ):DrawZone()
|
||||
}, 120, "Vee" )
|
||||
|
||||
Binary file not shown.
@@ -1,31 +1,31 @@
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 01.03.2018
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 27.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Timer.html
|
||||
--
|
||||
-- # Description:
|
||||
-- In this mission a vehicle will be damaged by Explode and then respawned with full health.
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Start the mission and wait 10 seconds.
|
||||
-- 2. The Vehicle will be damaged.
|
||||
-- 3. Wait additional 10 seconds and the Vehicle will be respawned with full health.
|
||||
|
||||
-- Find the Vehicle and create a GROUP object.
|
||||
Vehicle = GROUP:FindByName( "Vehicle" )
|
||||
|
||||
-- Damage the vehicle with a delay of 10 seconds.
|
||||
Vehicle:Explode( 1, 10 )
|
||||
MESSAGE:New( "Vehicle will be damaged in 10 seconds and respawn in 20 seconds!", 10 ):ToAll():ToLog()
|
||||
|
||||
-- Respawn the vehicle 20 seconds after mission start.
|
||||
TIMER:New(
|
||||
function()
|
||||
Vehicle:Respawn()
|
||||
end
|
||||
):Start( 20 )
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 01.03.2018
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 27.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Timer.html
|
||||
--
|
||||
-- # Description:
|
||||
-- In this mission a vehicle will be damaged by Explode and then respawned with full health.
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Start the mission and wait 10 seconds.
|
||||
-- 2. The Vehicle will be damaged.
|
||||
-- 3. Wait additional 10 seconds and the Vehicle will be respawned with full health.
|
||||
|
||||
-- Find the Vehicle and create a GROUP object.
|
||||
Vehicle = GROUP:FindByName( "Vehicle" )
|
||||
|
||||
-- Damage the vehicle with a delay of 10 seconds.
|
||||
Vehicle:Explode( 1, 10 )
|
||||
MESSAGE:New( "Vehicle will be damaged in 10 seconds and respawn in 20 seconds!", 10 ):ToAll():ToLog()
|
||||
|
||||
-- Respawn the vehicle 20 seconds after mission start.
|
||||
TIMER:New(
|
||||
function()
|
||||
Vehicle:Respawn()
|
||||
end
|
||||
):Start( 20 )
|
||||
|
||||
Binary file not shown.
@@ -1,32 +1,32 @@
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 01.03.2018
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 27.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Timer.html
|
||||
--
|
||||
-- # Description:
|
||||
-- In this mission a vehicle will be damaged by Explode and then respawned with full health.
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Start the mission and wait 10 seconds.
|
||||
-- 2. The Vehicle will be damaged.
|
||||
-- 3. Wait additional 10 seconds and the Vehicle will be respawned with full health.
|
||||
-- Note: In this mission the vehicle is set hidden, so it is not shown on the F10 map.
|
||||
|
||||
-- Find the Vehicle and create a GROUP object.
|
||||
Vehicle = GROUP:FindByName( "Vehicle" )
|
||||
|
||||
-- Damage the vehicle with a delay of 10 seconds.
|
||||
Vehicle:Explode( 1, 10 )
|
||||
MESSAGE:New( "Vehicle will be damaged in 10 seconds and respawn in 20 seconds!", 10 ):ToAll():ToLog()
|
||||
|
||||
-- Respawn the vehicle 20 seconds after mission start.
|
||||
TIMER:New(
|
||||
function()
|
||||
Vehicle:Respawn()
|
||||
end
|
||||
):Start( 20 )
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 01.03.2018
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 27.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Timer.html
|
||||
--
|
||||
-- # Description:
|
||||
-- In this mission a vehicle will be damaged by Explode and then respawned with full health.
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Start the mission and wait 10 seconds.
|
||||
-- 2. The Vehicle will be damaged.
|
||||
-- 3. Wait additional 10 seconds and the Vehicle will be respawned with full health.
|
||||
-- Note: In this mission the vehicle is set hidden, so it is not shown on the F10 map.
|
||||
|
||||
-- Find the Vehicle and create a GROUP object.
|
||||
Vehicle = GROUP:FindByName( "Vehicle" )
|
||||
|
||||
-- Damage the vehicle with a delay of 10 seconds.
|
||||
Vehicle:Explode( 1, 10 )
|
||||
MESSAGE:New( "Vehicle will be damaged in 10 seconds and respawn in 20 seconds!", 10 ):ToAll():ToLog()
|
||||
|
||||
-- Respawn the vehicle 20 seconds after mission start.
|
||||
TIMER:New(
|
||||
function()
|
||||
Vehicle:Respawn()
|
||||
end
|
||||
):Start( 20 )
|
||||
|
||||
Binary file not shown.
@@ -1,36 +1,36 @@
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 01.03.2018
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 27.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Timer.html
|
||||
--
|
||||
-- # Description:
|
||||
-- In this mission a vehicle will be respawned in a zone.
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Start the mission.
|
||||
-- 2. Take a look at F10 map. The Vehicle is outside of the zone.
|
||||
-- 3. Wait 10 seconds.
|
||||
-- 2. The Vehicle will be respawned. This time it is in the target zone.
|
||||
|
||||
-- Find the Vehicle and create a GROUP object.
|
||||
Vehicle = GROUP:FindByName( "Vehicle" )
|
||||
|
||||
-- Setup RespawnZone1 linking to the trigger zone ZONEVEHICLE1.
|
||||
RespawnZone1 = ZONE:New( "ZONEVEHICLE1" ):DrawZone()
|
||||
|
||||
-- Prepare the spawning to be done in RespawnZone1.
|
||||
Vehicle:InitZone( RespawnZone1 )
|
||||
|
||||
MESSAGE:New( "Vehicle will be respawned in 10 seconds in the zone!", 10 ):ToAll():ToLog()
|
||||
|
||||
-- Respawn the vehicle 10 seconds after mission start.
|
||||
TIMER:New(
|
||||
function()
|
||||
Vehicle:Respawn( nil, true ) -- Parameters: #table Template, #boolean Reset position
|
||||
end
|
||||
):Start( 10 )
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 01.03.2018
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 27.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Timer.html
|
||||
--
|
||||
-- # Description:
|
||||
-- In this mission a vehicle will be respawned in a zone.
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Start the mission.
|
||||
-- 2. Take a look at F10 map. The Vehicle is outside of the zone.
|
||||
-- 3. Wait 10 seconds.
|
||||
-- 2. The Vehicle will be respawned. This time it is in the target zone.
|
||||
|
||||
-- Find the Vehicle and create a GROUP object.
|
||||
Vehicle = GROUP:FindByName( "Vehicle" )
|
||||
|
||||
-- Setup RespawnZone1 linking to the trigger zone ZONEVEHICLE1.
|
||||
RespawnZone1 = ZONE:New( "ZONEVEHICLE1" ):DrawZone()
|
||||
|
||||
-- Prepare the spawning to be done in RespawnZone1.
|
||||
Vehicle:InitZone( RespawnZone1 )
|
||||
|
||||
MESSAGE:New( "Vehicle will be respawned in 10 seconds in the zone!", 10 ):ToAll():ToLog()
|
||||
|
||||
-- Respawn the vehicle 10 seconds after mission start.
|
||||
TIMER:New(
|
||||
function()
|
||||
Vehicle:Respawn( nil, true ) -- Parameters: #table Template, #boolean Reset position
|
||||
end
|
||||
):Start( 10 )
|
||||
|
||||
Binary file not shown.
@@ -1,38 +1,38 @@
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 01.03.2018
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 27.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Timer.html
|
||||
--
|
||||
-- # Description:
|
||||
-- In this mission a vehicle group will be respawned in a zone.
|
||||
-- The vehicle group consists of multiple units and are spawned in relation to the original template position.
|
||||
-- The first unit will be placed at the center of the zone.
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Start the mission.
|
||||
-- 2. Take a look at F10 map. The vehicle group is outside of the zone.
|
||||
-- 3. Wait 10 seconds.
|
||||
-- 2. The vehicle group will be respawned. This time it is in the target zone.
|
||||
|
||||
-- Find the Vehicle and create a GROUP object.
|
||||
Vehicle = GROUP:FindByName( "Vehicle" )
|
||||
|
||||
-- Setup RespawnZone1 linking to the trigger zone ZONEVEHICLE1.
|
||||
RespawnZone1 = ZONE:New( "ZONEVEHICLE1" ):DrawZone()
|
||||
|
||||
-- Prepare the spawning to be done in RespawnZone1.
|
||||
Vehicle:InitZone( RespawnZone1 )
|
||||
|
||||
MESSAGE:New( "Vehicle will be respawned in 10 seconds in the zone!", 10 ):ToAll():ToLog()
|
||||
|
||||
-- Respawn the vehicle 10 seconds after mission start.
|
||||
TIMER:New(
|
||||
function()
|
||||
Vehicle:Respawn( nil, true ) -- Parameters: #table Template, #boolean Reset position
|
||||
end
|
||||
):Start( 10 )
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 01.03.2018
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 27.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Timer.html
|
||||
--
|
||||
-- # Description:
|
||||
-- In this mission a vehicle group will be respawned in a zone.
|
||||
-- The vehicle group consists of multiple units and are spawned in relation to the original template position.
|
||||
-- The first unit will be placed at the center of the zone.
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Start the mission.
|
||||
-- 2. Take a look at F10 map. The vehicle group is outside of the zone.
|
||||
-- 3. Wait 10 seconds.
|
||||
-- 2. The vehicle group will be respawned. This time it is in the target zone.
|
||||
|
||||
-- Find the Vehicle and create a GROUP object.
|
||||
Vehicle = GROUP:FindByName( "Vehicle" )
|
||||
|
||||
-- Setup RespawnZone1 linking to the trigger zone ZONEVEHICLE1.
|
||||
RespawnZone1 = ZONE:New( "ZONEVEHICLE1" ):DrawZone()
|
||||
|
||||
-- Prepare the spawning to be done in RespawnZone1.
|
||||
Vehicle:InitZone( RespawnZone1 )
|
||||
|
||||
MESSAGE:New( "Vehicle will be respawned in 10 seconds in the zone!", 10 ):ToAll():ToLog()
|
||||
|
||||
-- Respawn the vehicle 10 seconds after mission start.
|
||||
TIMER:New(
|
||||
function()
|
||||
Vehicle:Respawn( nil, true ) -- Parameters: #table Template, #boolean Reset position
|
||||
end
|
||||
):Start( 10 )
|
||||
|
||||
Binary file not shown.
@@ -1,40 +1,40 @@
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 01.03.2018
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 27.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Timer.html
|
||||
--
|
||||
-- # Description:
|
||||
-- In this mission a vehicle group will be respawned in a zone.
|
||||
-- The vehicle group consists of multiple units and are spawned randomized within the new zone.
|
||||
-- The first unit will be placed at the center of the zone.
|
||||
-- NOTE: InitRandomizePositionZone will not ensure, that every unit is placed within the zone!
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Start the mission.
|
||||
-- 2. Take a look at F10 map. The vehicle group is outside of the zone.
|
||||
-- 3. Wait 10 seconds.
|
||||
-- 2. The vehicle group will be respawned. This time it is in the target zone.
|
||||
|
||||
-- Find the Vehicle and create a GROUP object.
|
||||
Vehicle = GROUP:FindByName( "Vehicle" )
|
||||
|
||||
-- Setup RespawnZone1 linking to the trigger zone ZONEVEHICLE1.
|
||||
RespawnZone1 = ZONE:New( "ZONEVEHICLE1" ):DrawZone()
|
||||
|
||||
-- Prepare the spawning to be done in RespawnZone1.
|
||||
Vehicle:InitZone( RespawnZone1 )
|
||||
Vehicle:InitRandomizePositionZone( true )
|
||||
|
||||
MESSAGE:New( "Vehicle will be respawned in 10 seconds in the zone!", 10 ):ToAll():ToLog()
|
||||
|
||||
-- Respawn the vehicle 10 seconds after mission start.
|
||||
TIMER:New(
|
||||
function()
|
||||
Vehicle:Respawn( nil, true ) -- Parameters: #table Template, #boolean Reset position
|
||||
end
|
||||
):Start( 10 )
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 01.03.2018
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 27.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Timer.html
|
||||
--
|
||||
-- # Description:
|
||||
-- In this mission a vehicle group will be respawned in a zone.
|
||||
-- The vehicle group consists of multiple units and are spawned randomized within the new zone.
|
||||
-- The first unit will be placed at the center of the zone.
|
||||
-- NOTE: InitRandomizePositionZone will not ensure, that every unit is placed within the zone!
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Start the mission.
|
||||
-- 2. Take a look at F10 map. The vehicle group is outside of the zone.
|
||||
-- 3. Wait 10 seconds.
|
||||
-- 2. The vehicle group will be respawned. This time it is in the target zone.
|
||||
|
||||
-- Find the Vehicle and create a GROUP object.
|
||||
Vehicle = GROUP:FindByName( "Vehicle" )
|
||||
|
||||
-- Setup RespawnZone1 linking to the trigger zone ZONEVEHICLE1.
|
||||
RespawnZone1 = ZONE:New( "ZONEVEHICLE1" ):DrawZone()
|
||||
|
||||
-- Prepare the spawning to be done in RespawnZone1.
|
||||
Vehicle:InitZone( RespawnZone1 )
|
||||
Vehicle:InitRandomizePositionZone( true )
|
||||
|
||||
MESSAGE:New( "Vehicle will be respawned in 10 seconds in the zone!", 10 ):ToAll():ToLog()
|
||||
|
||||
-- Respawn the vehicle 10 seconds after mission start.
|
||||
TIMER:New(
|
||||
function()
|
||||
Vehicle:Respawn( nil, true ) -- Parameters: #table Template, #boolean Reset position
|
||||
end
|
||||
):Start( 10 )
|
||||
|
||||
Binary file not shown.
@@ -1,36 +1,36 @@
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 01.03.2018
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 27.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Timer.html
|
||||
--
|
||||
-- # Description:
|
||||
-- In this mission a vehicle will be respawned in a zone. The vehicle is hidden on F10 map.
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Start the mission.
|
||||
-- 2. Take a look at F10 map. The Vehicle is outside of the zone.
|
||||
-- 3. Wait 10 seconds.
|
||||
-- 2. The Vehicle will be respawned. This time it is in the target zone.
|
||||
|
||||
-- Find the Vehicle and create a GROUP object.
|
||||
Vehicle = GROUP:FindByName( "Vehicle" )
|
||||
|
||||
-- Setup RespawnZone1 linking to the trigger zone ZONEVEHICLE1.
|
||||
RespawnZone1 = ZONE:New( "ZONEVEHICLE1" ):DrawZone()
|
||||
|
||||
-- Prepare the spawning to be done in RespawnZone1.
|
||||
Vehicle:InitZone( RespawnZone1 )
|
||||
|
||||
MESSAGE:New( "Vehicle will be respawned in 10 seconds in the zone!", 10 ):ToAll():ToLog()
|
||||
|
||||
-- Respawn the vehicle 10 seconds after mission start.
|
||||
TIMER:New(
|
||||
function()
|
||||
Vehicle:Respawn( nil, true ) -- Parameters: #table Template, #boolean Reset position
|
||||
end
|
||||
):Start( 10 )
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 01.03.2018
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 27.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Timer.html
|
||||
--
|
||||
-- # Description:
|
||||
-- In this mission a vehicle will be respawned in a zone. The vehicle is hidden on F10 map.
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Start the mission.
|
||||
-- 2. Take a look at F10 map. The Vehicle is outside of the zone.
|
||||
-- 3. Wait 10 seconds.
|
||||
-- 2. The Vehicle will be respawned. This time it is in the target zone.
|
||||
|
||||
-- Find the Vehicle and create a GROUP object.
|
||||
Vehicle = GROUP:FindByName( "Vehicle" )
|
||||
|
||||
-- Setup RespawnZone1 linking to the trigger zone ZONEVEHICLE1.
|
||||
RespawnZone1 = ZONE:New( "ZONEVEHICLE1" ):DrawZone()
|
||||
|
||||
-- Prepare the spawning to be done in RespawnZone1.
|
||||
Vehicle:InitZone( RespawnZone1 )
|
||||
|
||||
MESSAGE:New( "Vehicle will be respawned in 10 seconds in the zone!", 10 ):ToAll():ToLog()
|
||||
|
||||
-- Respawn the vehicle 10 seconds after mission start.
|
||||
TIMER:New(
|
||||
function()
|
||||
Vehicle:Respawn( nil, true ) -- Parameters: #table Template, #boolean Reset position
|
||||
end
|
||||
):Start( 10 )
|
||||
|
||||
Binary file not shown.
@@ -1,38 +1,38 @@
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 01.03.2018
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 27.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Timer.html
|
||||
--
|
||||
-- # Description:
|
||||
-- In this mission a vehicle group will be respawned in a zone. The vehicles are hidden on F10 map.
|
||||
-- The vehicle group consists of multiple units and are spawned in relation to the original template position.
|
||||
-- The first unit will be placed at the center of the zone.
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Start the mission.
|
||||
-- 2. Take a look at F10 map. The vehicle group is outside of the zone.
|
||||
-- 3. Wait 10 seconds.
|
||||
-- 2. The vehicle group will be respawned. This time it is in the target zone.
|
||||
|
||||
-- Find the Vehicle and create a GROUP object.
|
||||
Vehicle = GROUP:FindByName( "Vehicle" )
|
||||
|
||||
-- Setup RespawnZone1 linking to the trigger zone ZONEVEHICLE1.
|
||||
RespawnZone1 = ZONE:New( "ZONEVEHICLE1" ):DrawZone()
|
||||
|
||||
-- Prepare the spawning to be done in RespawnZone1.
|
||||
Vehicle:InitZone( RespawnZone1 )
|
||||
|
||||
MESSAGE:New( "Vehicle will be respawned in 10 seconds in the zone!", 10 ):ToAll():ToLog()
|
||||
|
||||
-- Respawn the vehicle 10 seconds after mission start.
|
||||
TIMER:New(
|
||||
function()
|
||||
Vehicle:Respawn( nil, true ) -- Parameters: #table Template, #boolean Reset position
|
||||
end
|
||||
):Start( 10 )
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 01.03.2018
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 27.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Timer.html
|
||||
--
|
||||
-- # Description:
|
||||
-- In this mission a vehicle group will be respawned in a zone. The vehicles are hidden on F10 map.
|
||||
-- The vehicle group consists of multiple units and are spawned in relation to the original template position.
|
||||
-- The first unit will be placed at the center of the zone.
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Start the mission.
|
||||
-- 2. Take a look at F10 map. The vehicle group is outside of the zone.
|
||||
-- 3. Wait 10 seconds.
|
||||
-- 2. The vehicle group will be respawned. This time it is in the target zone.
|
||||
|
||||
-- Find the Vehicle and create a GROUP object.
|
||||
Vehicle = GROUP:FindByName( "Vehicle" )
|
||||
|
||||
-- Setup RespawnZone1 linking to the trigger zone ZONEVEHICLE1.
|
||||
RespawnZone1 = ZONE:New( "ZONEVEHICLE1" ):DrawZone()
|
||||
|
||||
-- Prepare the spawning to be done in RespawnZone1.
|
||||
Vehicle:InitZone( RespawnZone1 )
|
||||
|
||||
MESSAGE:New( "Vehicle will be respawned in 10 seconds in the zone!", 10 ):ToAll():ToLog()
|
||||
|
||||
-- Respawn the vehicle 10 seconds after mission start.
|
||||
TIMER:New(
|
||||
function()
|
||||
Vehicle:Respawn( nil, true ) -- Parameters: #table Template, #boolean Reset position
|
||||
end
|
||||
):Start( 10 )
|
||||
|
||||
Binary file not shown.
@@ -1,40 +1,40 @@
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 01.03.2018
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 27.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Timer.html
|
||||
--
|
||||
-- # Description:
|
||||
-- In this mission a vehicle group will be respawned in a zone. The units are hiiden on F10 map.
|
||||
-- The vehicle group consists of multiple units and are spawned randomized within the new zone.
|
||||
-- The first unit will be placed at the center of the zone.
|
||||
-- NOTE: InitRandomizePositionZone will not ensure, that every unit is placed within the zone!
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Start the mission.
|
||||
-- 2. The vehicle group is outside of the zone.
|
||||
-- 3. Wait 10 seconds.
|
||||
-- 2. The vehicle group will be respawned. This time it is in the target zone.
|
||||
|
||||
-- Find the Vehicle and create a GROUP object.
|
||||
Vehicle = GROUP:FindByName( "Vehicle" )
|
||||
|
||||
-- Setup RespawnZone1 linking to the trigger zone ZONEVEHICLE1.
|
||||
RespawnZone1 = ZONE:New( "ZONEVEHICLE1" ):SmokeZone( SMOKECOLOR.White )
|
||||
|
||||
-- Prepare the spawning to be done in RespawnZone1.
|
||||
Vehicle:InitZone( RespawnZone1 )
|
||||
Vehicle:InitRandomizePositionZone( true )
|
||||
|
||||
MESSAGE:New( "Vehicle will be respawned in 10 seconds in the zone!", 10 ):ToAll():ToLog()
|
||||
|
||||
-- Respawn the vehicle 10 seconds after mission start.
|
||||
TIMER:New(
|
||||
function()
|
||||
Vehicle:Respawn( nil, true ) -- Parameters: #table Template, #boolean Reset position
|
||||
end
|
||||
):Start( 10 )
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 01.03.2018
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 27.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Timer.html
|
||||
--
|
||||
-- # Description:
|
||||
-- In this mission a vehicle group will be respawned in a zone. The units are hiiden on F10 map.
|
||||
-- The vehicle group consists of multiple units and are spawned randomized within the new zone.
|
||||
-- The first unit will be placed at the center of the zone.
|
||||
-- NOTE: InitRandomizePositionZone will not ensure, that every unit is placed within the zone!
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Start the mission.
|
||||
-- 2. The vehicle group is outside of the zone.
|
||||
-- 3. Wait 10 seconds.
|
||||
-- 2. The vehicle group will be respawned. This time it is in the target zone.
|
||||
|
||||
-- Find the Vehicle and create a GROUP object.
|
||||
Vehicle = GROUP:FindByName( "Vehicle" )
|
||||
|
||||
-- Setup RespawnZone1 linking to the trigger zone ZONEVEHICLE1.
|
||||
RespawnZone1 = ZONE:New( "ZONEVEHICLE1" ):SmokeZone( SMOKECOLOR.White )
|
||||
|
||||
-- Prepare the spawning to be done in RespawnZone1.
|
||||
Vehicle:InitZone( RespawnZone1 )
|
||||
Vehicle:InitRandomizePositionZone( true )
|
||||
|
||||
MESSAGE:New( "Vehicle will be respawned in 10 seconds in the zone!", 10 ):ToAll():ToLog()
|
||||
|
||||
-- Respawn the vehicle 10 seconds after mission start.
|
||||
TIMER:New(
|
||||
function()
|
||||
Vehicle:Respawn( nil, true ) -- Parameters: #table Template, #boolean Reset position
|
||||
end
|
||||
):Start( 10 )
|
||||
|
||||
Binary file not shown.
@@ -1,28 +1,28 @@
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 10.12.2017
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 27.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
--
|
||||
-- # Description:
|
||||
-- This mission will show the option to set the alarm state of a group to RED or GREEN.
|
||||
-- Both options are tested with one group for each.
|
||||
-- Please check the dcs.log in case of errors, and the time the group reacts to the approaching target.
|
||||
-- The Red State Group should react much faster than the Green State Group.
|
||||
-- State Blue is attacking. State Green is defending.
|
||||
-- The south SAM is "Red State".
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Start the mission.
|
||||
-- 2. Watch the situation on F10 map.
|
||||
|
||||
-- Find the SAMs and create GROUP objects.
|
||||
RedStateGroup = GROUP:FindByName( "Red State" )
|
||||
GreenStateGroup = GROUP:FindByName( "Green State" )
|
||||
|
||||
-- Set the states.
|
||||
RedStateGroup:OptionAlarmStateRed()
|
||||
GreenStateGroup:OptionAlarmStateGreen()
|
||||
---
|
||||
-- Author: FlightControl
|
||||
-- Created: 10.12.2017
|
||||
-- Contributors: kaltokri
|
||||
-- Modified: 27.02.2024
|
||||
--
|
||||
-- # Documentation:
|
||||
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
|
||||
--
|
||||
-- # Description:
|
||||
-- This mission will show the option to set the alarm state of a group to RED or GREEN.
|
||||
-- Both options are tested with one group for each.
|
||||
-- Please check the dcs.log in case of errors, and the time the group reacts to the approaching target.
|
||||
-- The Red State Group should react much faster than the Green State Group.
|
||||
-- State Blue is attacking. State Green is defending.
|
||||
-- The south SAM is "Red State".
|
||||
--
|
||||
-- # Guide:
|
||||
-- 1. Start the mission.
|
||||
-- 2. Watch the situation on F10 map.
|
||||
|
||||
-- Find the SAMs and create GROUP objects.
|
||||
RedStateGroup = GROUP:FindByName( "Red State" )
|
||||
GreenStateGroup = GROUP:FindByName( "Green State" )
|
||||
|
||||
-- Set the states.
|
||||
RedStateGroup:OptionAlarmStateRed()
|
||||
GreenStateGroup:OptionAlarmStateGreen()
|
||||
|
||||
Binary file not shown.
Reference in New Issue
Block a user