mirror of
https://github.com/FlightControl-Master/MOOSE.git
synced 2025-08-15 10:47:21 +00:00
Merge remote-tracking branch 'refs/remotes/origin/master' into Build-Sets
This commit is contained in:
commit
bff0c0bf4e
@ -41,9 +41,9 @@
|
||||
-- @module Airbase
|
||||
-- @author FlightControl
|
||||
|
||||
Include.File( "Routines" )
|
||||
Include.File( "Base" )
|
||||
Include.File( "Message" )
|
||||
|
||||
|
||||
|
||||
|
||||
--- The AIRBASE class
|
||||
-- @type AIRBASE
|
||||
|
||||
@ -53,7 +53,7 @@
|
||||
-- @module Base
|
||||
-- @author FlightControl
|
||||
|
||||
Include.File( "Routines" )
|
||||
|
||||
|
||||
local _TraceOn = true
|
||||
local _TraceLevel = 1
|
||||
|
||||
@ -1,10 +1,10 @@
|
||||
--- CARGO Classes
|
||||
-- @module CARGO
|
||||
|
||||
Include.File( "Routines" )
|
||||
Include.File( "Base" )
|
||||
Include.File( "Message" )
|
||||
Include.File( "Scheduler" )
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
--- Clients are those Groups defined within the Mission Editor that have the skillset defined as "Client" or "Player".
|
||||
|
||||
@ -2,11 +2,11 @@
|
||||
-- @module CleanUp
|
||||
-- @author Flightcontrol
|
||||
|
||||
Include.File( "Routines" )
|
||||
Include.File( "Base" )
|
||||
Include.File( "Mission" )
|
||||
Include.File( "Client" )
|
||||
Include.File( "Task" )
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
--- The CLEANUP class.
|
||||
-- @type CLEANUP
|
||||
@ -58,7 +58,6 @@ function CLEANUP:_DestroyGroup( GroupObject, CleanUpGroupName )
|
||||
self:F( { GroupObject, CleanUpGroupName } )
|
||||
|
||||
if GroupObject then -- and GroupObject:isExist() then
|
||||
--MESSAGE:New( "Destroy Group " .. CleanUpGroupName, CleanUpGroupName, 1, CleanUpGroupName ):ToAll()
|
||||
trigger.action.deactivateGroup(GroupObject)
|
||||
self:T( { "GroupObject Destroyed", GroupObject } )
|
||||
end
|
||||
@ -72,7 +71,6 @@ function CLEANUP:_DestroyUnit( CleanUpUnit, CleanUpUnitName )
|
||||
self:F( { CleanUpUnit, CleanUpUnitName } )
|
||||
|
||||
if CleanUpUnit then
|
||||
--MESSAGE:New( "Destroy " .. CleanUpUnitName, CleanUpUnitName, 1, CleanUpUnitName ):ToAll()
|
||||
local CleanUpGroup = Unit.getGroup(CleanUpUnit)
|
||||
-- TODO Client bug in 1.5.3
|
||||
if CleanUpGroup and CleanUpGroup:isExist() then
|
||||
@ -142,7 +140,6 @@ function CLEANUP:_EventCrash( Event )
|
||||
self:F( { Event } )
|
||||
|
||||
--TODO: This stuff is not working due to a DCS bug. Burning units cannot be destroyed.
|
||||
--MESSAGE:New( "Crash ", "Crash", 10, "Crash" ):ToAll()
|
||||
-- self:T("before getGroup")
|
||||
-- local _grp = Unit.getGroup(event.initiator)-- Identify the group that fired
|
||||
-- self:T("after getGroup")
|
||||
@ -277,7 +274,6 @@ function CLEANUP:_CleanUpScheduler()
|
||||
--self:T( CleanUpUnitVec2 )
|
||||
local CleanUpSurfaceType = land.getSurfaceType(CleanUpUnitVec2)
|
||||
--self:T( CleanUpSurfaceType )
|
||||
--MESSAGE:New( "Surface " .. CleanUpUnitName .. " = " .. CleanUpSurfaceTypeText[CleanUpSurfaceType], CleanUpUnitName, 10, CleanUpUnitName ):ToAll()
|
||||
|
||||
if CleanUpUnit and CleanUpUnit:getLife() <= CleanUpUnit:getLife0() * 0.95 then
|
||||
if CleanUpSurfaceType == land.SurfaceType.RUNWAY then
|
||||
@ -309,7 +305,6 @@ function CLEANUP:_CleanUpScheduler()
|
||||
else
|
||||
UnitData.CleanUpTime = timer.getTime()
|
||||
UnitData.CleanUpMoved = true
|
||||
--MESSAGE:New( "Moved " .. CleanUpUnitName, CleanUpUnitName, 10, CleanUpUnitName ):ToAll()
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
@ -37,10 +37,10 @@
|
||||
-- @module Client
|
||||
-- @author FlightControl
|
||||
|
||||
Include.File( "Routines" )
|
||||
Include.File( "Base" )
|
||||
Include.File( "Cargo" )
|
||||
Include.File( "Message" )
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
--- The CLIENT class
|
||||
@ -462,16 +462,16 @@ function CLIENT:Message( Message, MessageDuration, MessageId, MessageCategory, M
|
||||
else
|
||||
self.Messages[MessageId].MessageInterval = MessageInterval
|
||||
end
|
||||
MESSAGE:New( Message, MessageCategory, MessageDuration, MessageId ):ToClient( self )
|
||||
MESSAGE:New( Message, MessageDuration, MessageCategory ):ToClient( self )
|
||||
else
|
||||
if self:GetClientGroupDCSUnit() and not self:GetClientGroupDCSUnit():inAir() then
|
||||
if timer.getTime() - self.Messages[MessageId].MessageTime >= self.Messages[MessageId].MessageDuration + 10 then
|
||||
MESSAGE:New( Message, MessageCategory, MessageDuration, MessageId ):ToClient( self )
|
||||
MESSAGE:New( Message, MessageDuration , MessageCategory):ToClient( self )
|
||||
self.Messages[MessageId].MessageTime = timer.getTime()
|
||||
end
|
||||
else
|
||||
if timer.getTime() - self.Messages[MessageId].MessageTime >= self.Messages[MessageId].MessageDuration + self.Messages[MessageId].MessageInterval then
|
||||
MESSAGE:New( Message, MessageCategory, MessageDuration, MessageId ):ToClient( self )
|
||||
MESSAGE:New( Message, MessageDuration, MessageCategory ):ToClient( self )
|
||||
self.Messages[MessageId].MessageTime = timer.getTime()
|
||||
end
|
||||
end
|
||||
|
||||
@ -32,15 +32,15 @@
|
||||
-- @module Database
|
||||
-- @author FlightControl
|
||||
|
||||
Include.File( "Routines" )
|
||||
Include.File( "Base" )
|
||||
Include.File( "Menu" )
|
||||
Include.File( "Group" )
|
||||
Include.File( "Static" )
|
||||
Include.File( "Unit" )
|
||||
Include.File( "Event" )
|
||||
Include.File( "Client" )
|
||||
Include.File( "Scheduler" )
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
--- DATABASE class
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
--- A DEPLOYTASK orchestrates the deployment of CARGO within a specific landing zone.
|
||||
-- @module DEPLOYTASK
|
||||
|
||||
Include.File( "Task" )
|
||||
|
||||
|
||||
--- A DeployTask
|
||||
-- @type DEPLOYTASK
|
||||
|
||||
@ -4,7 +4,7 @@
|
||||
-- @see DESTROYUNITTYPESTASK
|
||||
-- @see DESTROY_RADARS_TASK
|
||||
|
||||
Include.File("Task")
|
||||
|
||||
|
||||
--- The DESTROYBASETASK class
|
||||
-- @type DESTROYBASETASK
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
--- DESTROYGROUPSTASK
|
||||
-- @module DESTROYGROUPSTASK
|
||||
|
||||
Include.File("DestroyBaseTask")
|
||||
|
||||
|
||||
--- The DESTROYGROUPSTASK class
|
||||
-- @type
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
--- Task class to destroy radar installations.
|
||||
-- @module DESTROYRADARSTASK
|
||||
|
||||
Include.File("DestroyBaseTask")
|
||||
|
||||
|
||||
--- The DESTROYRADARS class
|
||||
-- @type
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
--- Set TASK to destroy certain unit types.
|
||||
-- @module DESTROYUNITTYPESTASK
|
||||
|
||||
Include.File("DestroyBaseTask")
|
||||
|
||||
|
||||
--- The DESTROYUNITTYPESTASK class
|
||||
-- @type
|
||||
|
||||
@ -102,11 +102,11 @@
|
||||
-- @module Escort
|
||||
-- @author FlightControl
|
||||
|
||||
Include.File( "Routines" )
|
||||
Include.File( "Base" )
|
||||
Include.File( "Database" )
|
||||
Include.File( "Group" )
|
||||
Include.File( "Zone" )
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
---
|
||||
-- @type ESCORT
|
||||
|
||||
@ -2,9 +2,6 @@
|
||||
-- @module Event
|
||||
-- @author FlightControl
|
||||
|
||||
Include.File( "Routines" )
|
||||
Include.File( "Base" )
|
||||
|
||||
--- The EVENT structure
|
||||
-- @type EVENT
|
||||
-- @field #EVENT.Events Events
|
||||
|
||||
@ -1,8 +1,6 @@
|
||||
--- A GOHOMETASK orchestrates the travel back to the home base, which is a specific zone defined within the ME.
|
||||
-- @module GOHOMETASK
|
||||
|
||||
Include.File("Task")
|
||||
|
||||
--- The GOHOMETASK class
|
||||
-- @type
|
||||
GOHOMETASK = {
|
||||
|
||||
@ -146,11 +146,6 @@
|
||||
-- @module Group
|
||||
-- @author FlightControl
|
||||
|
||||
Include.File( "Routines" )
|
||||
Include.File( "Base" )
|
||||
Include.File( "Message" )
|
||||
Include.File( "Unit" )
|
||||
|
||||
--- The GROUP class
|
||||
-- @type GROUP
|
||||
-- @extends Base#BASE
|
||||
@ -2672,7 +2667,7 @@ function GROUP:Message( Message, Duration )
|
||||
|
||||
local DCSGroup = self:GetDCSGroup()
|
||||
if DCSGroup then
|
||||
return MESSAGE:New( Message, self:GetCallsign() .. " (" .. self:GetTypeName() .. ")", Duration, self:GetClassNameAndID() )
|
||||
return MESSAGE:New( Message, Duration, self:GetCallsign() .. " (" .. self:GetTypeName() .. ")" )
|
||||
end
|
||||
|
||||
return nil
|
||||
|
||||
@ -1,9 +1,6 @@
|
||||
--- Encapsulation of DCS World Menu system in a set of MENU classes.
|
||||
-- @module Menu
|
||||
|
||||
Include.File( "Routines" )
|
||||
Include.File( "Base" )
|
||||
|
||||
--- The MENU class
|
||||
-- @type MENU
|
||||
-- @extends Base#BASE
|
||||
|
||||
@ -1,17 +1,30 @@
|
||||
--- Message System to display Messages for Clients and Coalitions or All.
|
||||
-- Messages are grouped on the display panel per Category to improve readability for the players.
|
||||
--- This module contains the MESSAGE class.
|
||||
--
|
||||
-- 1) @{Message#MESSAGE} class, extends @{Base#BASE}
|
||||
-- =================================================
|
||||
-- Message System to display Messages to Clients, Coalitions or All.
|
||||
-- Messages are shown on the display panel for an amount of seconds, and will then disappear.
|
||||
-- Messages are identified by an ID. The messages with the same ID belonging to the same category will be overwritten if they were still being displayed on the display panel.
|
||||
-- Messages are created with MESSAGE:@{New}().
|
||||
-- Messages are sent to Clients with MESSAGE:@{ToClient}().
|
||||
-- Messages are sent to Coalitions with MESSAGE:@{ToCoalition}().
|
||||
-- Messages are sent to All Players with MESSAGE:@{ToAll}().
|
||||
-- Messages can contain a category which is indicating the category of the message.
|
||||
--
|
||||
-- 1.1) MESSAGE construction methods
|
||||
-- ---------------------------------
|
||||
-- Messages are created with @{Message#MESSAGE.New}. Note that when the MESSAGE object is created, no message is sent yet.
|
||||
-- To send messages, you need to use the To functions.
|
||||
--
|
||||
-- 1.2) Send messages with MESSAGE To methods
|
||||
-- ------------------------------------------
|
||||
-- Messages are sent to:
|
||||
--
|
||||
-- * Clients with @{Message#MESSAGE.ToClient}.
|
||||
-- * Coalitions with @{Message#MESSAGE.ToCoalition}.
|
||||
-- * All Players with @{Message#MESSAGE.ToAll}.
|
||||
--
|
||||
-- @module Message
|
||||
|
||||
Include.File( "Base" )
|
||||
-- @author FlightControl
|
||||
|
||||
--- The MESSAGE class
|
||||
-- @type MESSAGE
|
||||
-- @extends Base#BASE
|
||||
MESSAGE = {
|
||||
ClassName = "MESSAGE",
|
||||
MessageCategory = 0,
|
||||
@ -22,9 +35,8 @@ MESSAGE = {
|
||||
--- Creates a new MESSAGE object. Note that these MESSAGE objects are not yet displayed on the display panel. You must use the functions @{ToClient} or @{ToCoalition} or @{ToAll} to send these Messages to the respective recipients.
|
||||
-- @param self
|
||||
-- @param #string MessageText is the text of the Message.
|
||||
-- @param #string MessageCategory is a string expressing the Category of the Message. Messages are grouped on the display panel per Category to improve readability.
|
||||
-- @param #number MessageDuration is a number in seconds of how long the MESSAGE should be shown on the display panel.
|
||||
-- @param #string MessageID is a string expressing the ID of the Message.
|
||||
-- @param #string MessageCategory (optional) is a string expressing the "category" of the Message. The category will be shown as the first text in the message followed by a ": ".
|
||||
-- @return #MESSAGE
|
||||
-- @usage
|
||||
-- -- Create a series of new Messages.
|
||||
@ -32,15 +44,15 @@ MESSAGE = {
|
||||
-- -- MessageRED is meant to be sent to the RED players only, for 10 seconds, and is classified as "End of Mission", with ID "Win".
|
||||
-- -- MessageClient1 is meant to be sent to a Client, for 25 seconds, and is classified as "Score", with ID "Score".
|
||||
-- -- MessageClient1 is meant to be sent to a Client, for 25 seconds, and is classified as "Score", with ID "Score".
|
||||
-- MessageAll = MESSAGE:New( "To all Players: BLUE has won! Each player of BLUE wins 50 points!", "End of Mission", 25, "Win" )
|
||||
-- MessageRED = MESSAGE:New( "To the RED Players: You receive a penalty because you've killed one of your own units", "Penalty", 25, "Score" )
|
||||
-- MessageClient1 = MESSAGE:New( "Congratulations, you've just hit a target", "Score", 25, "Score" )
|
||||
-- MessageClient2 = MESSAGE:New( "Congratulations, you've just killed a target", "Score", 25, "Score" )
|
||||
function MESSAGE:New( MessageText, MessageCategory, MessageDuration, MessageID )
|
||||
-- MessageAll = MESSAGE:New( "To all Players: BLUE has won! Each player of BLUE wins 50 points!", 25, "End of Mission" )
|
||||
-- MessageRED = MESSAGE:New( "To the RED Players: You receive a penalty because you've killed one of your own units", 25, "Penalty" )
|
||||
-- MessageClient1 = MESSAGE:New( "Congratulations, you've just hit a target", 25, "Score" )
|
||||
-- MessageClient2 = MESSAGE:New( "Congratulations, you've just killed a target", 25, "Score")
|
||||
function MESSAGE:New( MessageText, MessageDuration, MessageCategory )
|
||||
local self = BASE:Inherit( self, BASE:New() )
|
||||
self:F( { MessageText, MessageCategory, MessageDuration, MessageID } )
|
||||
self:F( { MessageText, MessageDuration, MessageCategory } )
|
||||
|
||||
-- When no messagecategory is given, we don't show it as a title...
|
||||
-- When no MessageCategory is given, we don't show it as a title...
|
||||
if MessageCategory and MessageCategory ~= "" then
|
||||
self.MessageCategory = MessageCategory .. ": "
|
||||
else
|
||||
@ -48,7 +60,6 @@ function MESSAGE:New( MessageText, MessageCategory, MessageDuration, MessageID )
|
||||
end
|
||||
|
||||
self.MessageDuration = MessageDuration
|
||||
self.MessageID = MessageID
|
||||
self.MessageTime = timer.getTime()
|
||||
self.MessageText = MessageText
|
||||
|
||||
@ -174,77 +185,77 @@ end
|
||||
|
||||
|
||||
|
||||
--- The MESSAGEQUEUE class
|
||||
-- @type MESSAGEQUEUE
|
||||
MESSAGEQUEUE = {
|
||||
ClientGroups = {},
|
||||
CoalitionSides = {}
|
||||
}
|
||||
|
||||
function MESSAGEQUEUE:New( RefreshInterval )
|
||||
local self = BASE:Inherit( self, BASE:New() )
|
||||
self:F( { RefreshInterval } )
|
||||
|
||||
self.RefreshInterval = RefreshInterval
|
||||
|
||||
--self.DisplayFunction = routines.scheduleFunction( self._DisplayMessages, { self }, 0, RefreshInterval )
|
||||
self.DisplayFunction = SCHEDULER:New( self, self._DisplayMessages, {}, 0, RefreshInterval )
|
||||
|
||||
return self
|
||||
end
|
||||
|
||||
--- This function is called automatically by the MESSAGEQUEUE scheduler.
|
||||
function MESSAGEQUEUE:_DisplayMessages()
|
||||
|
||||
-- First we display all messages that a coalition needs to receive... Also those who are not in a client (CA module clients...).
|
||||
for CoalitionSideID, CoalitionSideData in pairs( self.CoalitionSides ) do
|
||||
for MessageID, MessageData in pairs( CoalitionSideData.Messages ) do
|
||||
if MessageData.MessageSent == false then
|
||||
--trigger.action.outTextForCoalition( CoalitionSideID, MessageData.MessageCategory .. '\n' .. MessageData.MessageText:gsub("\n$",""):gsub("\n$",""), MessageData.MessageDuration )
|
||||
MessageData.MessageSent = true
|
||||
end
|
||||
local MessageTimeLeft = ( MessageData.MessageTime + MessageData.MessageDuration ) - timer.getTime()
|
||||
if MessageTimeLeft <= 0 then
|
||||
MessageData = nil
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
-- Then we send the messages for each individual client, but also to be included are those Coalition messages for the Clients who belong to a coalition.
|
||||
-- Because the Client messages will overwrite the Coalition messages (for that Client).
|
||||
for ClientGroupName, ClientGroupData in pairs( self.ClientGroups ) do
|
||||
for MessageID, MessageData in pairs( ClientGroupData.Messages ) do
|
||||
if MessageData.MessageGroup == false then
|
||||
trigger.action.outTextForGroup( Group.getByName(ClientGroupName):getID(), MessageData.MessageCategory .. '\n' .. MessageData.MessageText:gsub("\n$",""):gsub("\n$",""), MessageData.MessageDuration )
|
||||
MessageData.MessageGroup = true
|
||||
end
|
||||
local MessageTimeLeft = ( MessageData.MessageTime + MessageData.MessageDuration ) - timer.getTime()
|
||||
if MessageTimeLeft <= 0 then
|
||||
MessageData = nil
|
||||
end
|
||||
end
|
||||
|
||||
-- Now check if the Client also has messages that belong to the Coalition of the Client...
|
||||
for CoalitionSideID, CoalitionSideData in pairs( self.CoalitionSides ) do
|
||||
for MessageID, MessageData in pairs( CoalitionSideData.Messages ) do
|
||||
local CoalitionGroup = Group.getByName( ClientGroupName )
|
||||
if CoalitionGroup and CoalitionGroup:getCoalition() == CoalitionSideID then
|
||||
if MessageData.MessageCoalition == false then
|
||||
trigger.action.outTextForGroup( Group.getByName(ClientGroupName):getID(), MessageData.MessageCategory .. '\n' .. MessageData.MessageText:gsub("\n$",""):gsub("\n$",""), MessageData.MessageDuration )
|
||||
MessageData.MessageCoalition = true
|
||||
end
|
||||
end
|
||||
local MessageTimeLeft = ( MessageData.MessageTime + MessageData.MessageDuration ) - timer.getTime()
|
||||
if MessageTimeLeft <= 0 then
|
||||
MessageData = nil
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
--- The _MessageQueue object is created when the MESSAGE class module is loaded.
|
||||
--_MessageQueue = MESSAGEQUEUE:New( 0.5 )
|
||||
|
||||
----- The MESSAGEQUEUE class
|
||||
---- @type MESSAGEQUEUE
|
||||
--MESSAGEQUEUE = {
|
||||
-- ClientGroups = {},
|
||||
-- CoalitionSides = {}
|
||||
--}
|
||||
--
|
||||
--function MESSAGEQUEUE:New( RefreshInterval )
|
||||
-- local self = BASE:Inherit( self, BASE:New() )
|
||||
-- self:F( { RefreshInterval } )
|
||||
--
|
||||
-- self.RefreshInterval = RefreshInterval
|
||||
--
|
||||
-- --self.DisplayFunction = routines.scheduleFunction( self._DisplayMessages, { self }, 0, RefreshInterval )
|
||||
-- self.DisplayFunction = SCHEDULER:New( self, self._DisplayMessages, {}, 0, RefreshInterval )
|
||||
--
|
||||
-- return self
|
||||
--end
|
||||
--
|
||||
----- This function is called automatically by the MESSAGEQUEUE scheduler.
|
||||
--function MESSAGEQUEUE:_DisplayMessages()
|
||||
--
|
||||
-- -- First we display all messages that a coalition needs to receive... Also those who are not in a client (CA module clients...).
|
||||
-- for CoalitionSideID, CoalitionSideData in pairs( self.CoalitionSides ) do
|
||||
-- for MessageID, MessageData in pairs( CoalitionSideData.Messages ) do
|
||||
-- if MessageData.MessageSent == false then
|
||||
-- --trigger.action.outTextForCoalition( CoalitionSideID, MessageData.MessageCategory .. '\n' .. MessageData.MessageText:gsub("\n$",""):gsub("\n$",""), MessageData.MessageDuration )
|
||||
-- MessageData.MessageSent = true
|
||||
-- end
|
||||
-- local MessageTimeLeft = ( MessageData.MessageTime + MessageData.MessageDuration ) - timer.getTime()
|
||||
-- if MessageTimeLeft <= 0 then
|
||||
-- MessageData = nil
|
||||
-- end
|
||||
-- end
|
||||
-- end
|
||||
--
|
||||
-- -- Then we send the messages for each individual client, but also to be included are those Coalition messages for the Clients who belong to a coalition.
|
||||
-- -- Because the Client messages will overwrite the Coalition messages (for that Client).
|
||||
-- for ClientGroupName, ClientGroupData in pairs( self.ClientGroups ) do
|
||||
-- for MessageID, MessageData in pairs( ClientGroupData.Messages ) do
|
||||
-- if MessageData.MessageGroup == false then
|
||||
-- trigger.action.outTextForGroup( Group.getByName(ClientGroupName):getID(), MessageData.MessageCategory .. '\n' .. MessageData.MessageText:gsub("\n$",""):gsub("\n$",""), MessageData.MessageDuration )
|
||||
-- MessageData.MessageGroup = true
|
||||
-- end
|
||||
-- local MessageTimeLeft = ( MessageData.MessageTime + MessageData.MessageDuration ) - timer.getTime()
|
||||
-- if MessageTimeLeft <= 0 then
|
||||
-- MessageData = nil
|
||||
-- end
|
||||
-- end
|
||||
--
|
||||
-- -- Now check if the Client also has messages that belong to the Coalition of the Client...
|
||||
-- for CoalitionSideID, CoalitionSideData in pairs( self.CoalitionSides ) do
|
||||
-- for MessageID, MessageData in pairs( CoalitionSideData.Messages ) do
|
||||
-- local CoalitionGroup = Group.getByName( ClientGroupName )
|
||||
-- if CoalitionGroup and CoalitionGroup:getCoalition() == CoalitionSideID then
|
||||
-- if MessageData.MessageCoalition == false then
|
||||
-- trigger.action.outTextForGroup( Group.getByName(ClientGroupName):getID(), MessageData.MessageCategory .. '\n' .. MessageData.MessageText:gsub("\n$",""):gsub("\n$",""), MessageData.MessageDuration )
|
||||
-- MessageData.MessageCoalition = true
|
||||
-- end
|
||||
-- end
|
||||
-- local MessageTimeLeft = ( MessageData.MessageTime + MessageData.MessageDuration ) - timer.getTime()
|
||||
-- if MessageTimeLeft <= 0 then
|
||||
-- MessageData = nil
|
||||
-- end
|
||||
-- end
|
||||
-- end
|
||||
-- end
|
||||
--
|
||||
-- return true
|
||||
--end
|
||||
--
|
||||
----- The _MessageQueue object is created when the MESSAGE class module is loaded.
|
||||
----_MessageQueue = MESSAGEQUEUE:New( 0.5 )
|
||||
--
|
||||
|
||||
@ -70,9 +70,6 @@
|
||||
-- @author FlightControl
|
||||
|
||||
|
||||
Include.File( "Client" )
|
||||
Include.File( "Scheduler" )
|
||||
|
||||
--- The MISSILETRAINER class
|
||||
-- @type MISSILETRAINER
|
||||
-- @extends Base#BASE
|
||||
@ -217,9 +214,9 @@ function MISSILETRAINER:InitMessagesOnOff( MessagesOnOff )
|
||||
|
||||
self.MessagesOnOff = MessagesOnOff
|
||||
if self.MessagesOnOff == true then
|
||||
MESSAGE:New( "Messages ON", "Menu", 15, "ID" ):ToAll()
|
||||
MESSAGE:New( "Messages ON", 15, "Menu" ):ToAll()
|
||||
else
|
||||
MESSAGE:New( "Messages OFF", "Menu", 15, "ID" ):ToAll()
|
||||
MESSAGE:New( "Messages OFF", 15, "Menu" ):ToAll()
|
||||
end
|
||||
|
||||
return self
|
||||
@ -234,9 +231,9 @@ function MISSILETRAINER:InitTrackingToAll( TrackingToAll )
|
||||
|
||||
self.TrackingToAll = TrackingToAll
|
||||
if self.TrackingToAll == true then
|
||||
MESSAGE:New( "Missile tracking to all players ON", "Menu", 15, "ID" ):ToAll()
|
||||
MESSAGE:New( "Missile tracking to all players ON", 15, "Menu" ):ToAll()
|
||||
else
|
||||
MESSAGE:New( "Missile tracking to all players OFF", "Menu", 15, "ID" ):ToAll()
|
||||
MESSAGE:New( "Missile tracking to all players OFF", 15, "Menu" ):ToAll()
|
||||
end
|
||||
|
||||
return self
|
||||
@ -251,9 +248,9 @@ function MISSILETRAINER:InitTrackingOnOff( TrackingOnOff )
|
||||
|
||||
self.TrackingOnOff = TrackingOnOff
|
||||
if self.TrackingOnOff == true then
|
||||
MESSAGE:New( "Missile tracking ON", "Menu", 15, "ID" ):ToAll()
|
||||
MESSAGE:New( "Missile tracking ON", 15, "Menu" ):ToAll()
|
||||
else
|
||||
MESSAGE:New( "Missile tracking OFF", "Menu", 15, "ID" ):ToAll()
|
||||
MESSAGE:New( "Missile tracking OFF", 15, "Menu" ):ToAll()
|
||||
end
|
||||
|
||||
return self
|
||||
@ -272,7 +269,7 @@ function MISSILETRAINER:InitTrackingFrequency( TrackingFrequency )
|
||||
self.TrackingFrequency = 0.5
|
||||
end
|
||||
if self.TrackingFrequency then
|
||||
MESSAGE:New( "Missile tracking frequency is " .. self.TrackingFrequency .. " seconds.", "Menu", 15, "ID" ):ToAll()
|
||||
MESSAGE:New( "Missile tracking frequency is " .. self.TrackingFrequency .. " seconds.", 15, "Menu" ):ToAll()
|
||||
end
|
||||
|
||||
return self
|
||||
@ -287,9 +284,9 @@ function MISSILETRAINER:InitAlertsToAll( AlertsToAll )
|
||||
|
||||
self.AlertsToAll = AlertsToAll
|
||||
if self.AlertsToAll == true then
|
||||
MESSAGE:New( "Alerts to all players ON", "Menu", 15, "ID" ):ToAll()
|
||||
MESSAGE:New( "Alerts to all players ON", 15, "Menu" ):ToAll()
|
||||
else
|
||||
MESSAGE:New( "Alerts to all players OFF", "Menu", 15, "ID" ):ToAll()
|
||||
MESSAGE:New( "Alerts to all players OFF", 15, "Menu" ):ToAll()
|
||||
end
|
||||
|
||||
return self
|
||||
@ -304,9 +301,9 @@ function MISSILETRAINER:InitAlertsHitsOnOff( AlertsHitsOnOff )
|
||||
|
||||
self.AlertsHitsOnOff = AlertsHitsOnOff
|
||||
if self.AlertsHitsOnOff == true then
|
||||
MESSAGE:New( "Alerts Hits ON", "Menu", 15, "ID" ):ToAll()
|
||||
MESSAGE:New( "Alerts Hits ON", 15, "Menu" ):ToAll()
|
||||
else
|
||||
MESSAGE:New( "Alerts Hits OFF", "Menu", 15, "ID" ):ToAll()
|
||||
MESSAGE:New( "Alerts Hits OFF", 15, "Menu" ):ToAll()
|
||||
end
|
||||
|
||||
return self
|
||||
@ -321,9 +318,9 @@ function MISSILETRAINER:InitAlertsLaunchesOnOff( AlertsLaunchesOnOff )
|
||||
|
||||
self.AlertsLaunchesOnOff = AlertsLaunchesOnOff
|
||||
if self.AlertsLaunchesOnOff == true then
|
||||
MESSAGE:New( "Alerts Launches ON", "Menu", 15, "ID" ):ToAll()
|
||||
MESSAGE:New( "Alerts Launches ON", 15, "Menu" ):ToAll()
|
||||
else
|
||||
MESSAGE:New( "Alerts Launches OFF", "Menu", 15, "ID" ):ToAll()
|
||||
MESSAGE:New( "Alerts Launches OFF", 15, "Menu" ):ToAll()
|
||||
end
|
||||
|
||||
return self
|
||||
@ -338,9 +335,9 @@ function MISSILETRAINER:InitRangeOnOff( DetailsRangeOnOff )
|
||||
|
||||
self.DetailsRangeOnOff = DetailsRangeOnOff
|
||||
if self.DetailsRangeOnOff == true then
|
||||
MESSAGE:New( "Range display ON", "Menu", 15, "ID" ):ToAll()
|
||||
MESSAGE:New( "Range display ON", 15, "Menu" ):ToAll()
|
||||
else
|
||||
MESSAGE:New( "Range display OFF", "Menu", 15, "ID" ):ToAll()
|
||||
MESSAGE:New( "Range display OFF", 15, "Menu" ):ToAll()
|
||||
end
|
||||
|
||||
return self
|
||||
@ -355,9 +352,9 @@ function MISSILETRAINER:InitBearingOnOff( DetailsBearingOnOff )
|
||||
|
||||
self.DetailsBearingOnOff = DetailsBearingOnOff
|
||||
if self.DetailsBearingOnOff == true then
|
||||
MESSAGE:New( "Bearing display OFF", "Menu", 15, "ID" ):ToAll()
|
||||
MESSAGE:New( "Bearing display OFF", 15, "Menu" ):ToAll()
|
||||
else
|
||||
MESSAGE:New( "Bearing display OFF", "Menu", 15, "ID" ):ToAll()
|
||||
MESSAGE:New( "Bearing display OFF", 15, "Menu" ):ToAll()
|
||||
end
|
||||
|
||||
return self
|
||||
@ -372,9 +369,9 @@ function MISSILETRAINER:InitMenusOnOff( MenusOnOff )
|
||||
|
||||
self.MenusOnOff = MenusOnOff
|
||||
if self.MenusOnOff == true then
|
||||
MESSAGE:New( "Menus are ENABLED (only when a player rejoins a slot)", "Menu", 15, "ID" ):ToAll()
|
||||
MESSAGE:New( "Menus are ENABLED (only when a player rejoins a slot)", 15, "Menu" ):ToAll()
|
||||
else
|
||||
MESSAGE:New( "Menus are DISABLED", "Menu", 15, "ID" ):ToAll()
|
||||
MESSAGE:New( "Menus are DISABLED", 15, "Menu" ):ToAll()
|
||||
end
|
||||
|
||||
return self
|
||||
@ -425,7 +422,7 @@ function MISSILETRAINER._MenuMessages( MenuParameters )
|
||||
|
||||
if MenuParameters.Distance ~= nil then
|
||||
self.Distance = MenuParameters.Distance
|
||||
MESSAGE:New( "Hit detection distance set to " .. self.Distance .. " meters", "Menu", 15, "ID" ):ToAll()
|
||||
MESSAGE:New( "Hit detection distance set to " .. self.Distance .. " meters", 15, "Menu" ):ToAll()
|
||||
end
|
||||
|
||||
end
|
||||
@ -461,7 +458,7 @@ function MISSILETRAINER:_EventShot( Event )
|
||||
string.format( "%s launched a %s",
|
||||
TrainerSourceUnit:GetTypeName(),
|
||||
TrainerWeaponName
|
||||
) .. self:_AddRange( Client, TrainerWeapon ) .. self:_AddBearing( Client, TrainerWeapon ),"Launch Alert", 5, "ID" )
|
||||
) .. self:_AddRange( Client, TrainerWeapon ) .. self:_AddBearing( Client, TrainerWeapon ), 5, "Launch Alert" )
|
||||
|
||||
if self.AlertsToAll then
|
||||
Message:ToAll()
|
||||
@ -576,7 +573,7 @@ function MISSILETRAINER:_TrackMissiles()
|
||||
TrainerWeapon:getTypeName(),
|
||||
TrainerSourceUnit:GetTypeName(),
|
||||
TrainerTargetUnit:GetPlayerName()
|
||||
),"Hit Alert", 15, "ID" )
|
||||
), 15, "Hit Alert" )
|
||||
|
||||
if self.AlertsToAll == true then
|
||||
Message:ToAll()
|
||||
@ -597,7 +594,7 @@ function MISSILETRAINER:_TrackMissiles()
|
||||
string.format( "%s launched by %s self destructed!",
|
||||
TrainerWeaponTypeName,
|
||||
TrainerSourceUnit:GetTypeName()
|
||||
),"Tracking", 5, "ID" )
|
||||
), 5, "Tracking" )
|
||||
|
||||
if self.AlertsToAll == true then
|
||||
Message:ToAll()
|
||||
@ -671,7 +668,7 @@ function MISSILETRAINER:_TrackMissiles()
|
||||
|
||||
-- Once the Player Client and the Other Player Client tracking messages are prepared, show them.
|
||||
if ClientData.MessageToClient ~= "" or ClientData.MessageToAll ~= "" then
|
||||
local Message = MESSAGE:New( ClientData.MessageToClient .. ClientData.MessageToAll, "Tracking", 1, "ID" ):ToClient( Client )
|
||||
local Message = MESSAGE:New( ClientData.MessageToClient .. ClientData.MessageToAll, 1, "Tracking" ):ToClient( Client )
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
@ -2,11 +2,6 @@
|
||||
-- A @{CLIENT} needs to be registered within the @{MISSION} through the function @{AddClient}. A @{TASK} needs to be registered within the @{MISSION} through the function @{AddTask}.
|
||||
-- @module Mission
|
||||
|
||||
Include.File( "Routines" )
|
||||
Include.File( "Base" )
|
||||
Include.File( "Client" )
|
||||
Include.File( "Task" )
|
||||
|
||||
--- The MISSION class
|
||||
-- @type MISSION
|
||||
-- @extends Base#BASE
|
||||
@ -191,7 +186,7 @@ function MISSION:ReportToAll()
|
||||
for TaskID, TaskData in pairs( Tasks ) do
|
||||
TaskText = TaskText .. " - Task " .. TaskID .. ": " .. TaskData.Name .. ": " .. TaskData:GetGoalProgress() .. "\n"
|
||||
end
|
||||
MESSAGE:New( self.MissionCoalition .. ' "' .. self.Name .. '": ' .. self.MissionStatus .. ' ( ' .. self.MissionPriority .. ' mission )' .. AlivePlayers .. "\n" .. TaskText:gsub("\n$",""), "Mission Command: Mission Report", 10, self.Name .. '/Status'):ToAll()
|
||||
MESSAGE:New( self.MissionCoalition .. ' "' .. self.Name .. '": ' .. self.MissionStatus .. ' ( ' .. self.MissionPriority .. ' mission )' .. AlivePlayers .. "\n" .. TaskText:gsub("\n$",""), 10, "Mission Command: Mission Report" ):ToAll()
|
||||
end
|
||||
|
||||
|
||||
@ -650,7 +645,7 @@ function MISSIONSCHEDULER:TimeShow()
|
||||
self.TimeIntervalCount = self.TimeIntervalCount + 1
|
||||
if self.TimeIntervalCount >= self.TimeTriggerShow then
|
||||
local TimeMsg = string.format("%00d", ( self.TimeSeconds / 60 ) - ( timer.getTime() / 60 )) .. ' minutes left until mission reload.'
|
||||
MESSAGE:New( TimeMsg, "Mission time", self.TimeShow, '/TimeMsg' ):ToAll()
|
||||
MESSAGE:New( TimeMsg, self.TimeShow, "Mission time" ):ToAll()
|
||||
self.TimeIntervalCount = 0
|
||||
end
|
||||
end
|
||||
|
||||
@ -2,8 +2,73 @@
|
||||
|
||||
Include.File( "Routines" )
|
||||
Include.File( "Base" )
|
||||
Include.File( "Database" )
|
||||
Include.File( "Scheduler" )
|
||||
Include.File( "Event" )
|
||||
Include.File( "Menu" )
|
||||
Include.File( "Group" )
|
||||
Include.File( "Unit" )
|
||||
Include.File( "Zone" )
|
||||
Include.File( "Client" )
|
||||
Include.File( "Static" )
|
||||
Include.File( "Database" )
|
||||
Include.File( "Set" )
|
||||
Include.File( "Point" )
|
||||
Include.File( "Moose" )
|
||||
Include.File( "Scoring" )
|
||||
Include.File( "Cargo" )
|
||||
Include.File( "Message" )
|
||||
Include.File( "Stage" )
|
||||
Include.File( "Task" )
|
||||
Include.File( "GoHomeTask" )
|
||||
Include.File( "DestroyBaseTask" )
|
||||
Include.File( "DestroyGroupsTask" )
|
||||
Include.File( "DestroyRadarsTask" )
|
||||
Include.File( "DestroyUnitTypesTask" )
|
||||
Include.File( "PickupTask" )
|
||||
Include.File( "DeployTask" )
|
||||
Include.File( "NoTask" )
|
||||
Include.File( "RouteTask" )
|
||||
Include.File( "Mission" )
|
||||
Include.File( "CleanUp" )
|
||||
Include.File( "Spawn" )
|
||||
Include.File( "Movement" )
|
||||
Include.File( "Sead" )
|
||||
Include.File( "Escort" )
|
||||
Include.File( "MissileTrainer" )
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
-- The order of the declarations is important here. Don't touch it.
|
||||
|
||||
|
||||
@ -5,8 +5,6 @@
|
||||
-- on defined intervals (currently every minute).
|
||||
-- @module MOVEMENT
|
||||
|
||||
Include.File( "Routines" )
|
||||
|
||||
--- the MOVEMENT class
|
||||
-- @type
|
||||
MOVEMENT = {
|
||||
|
||||
@ -1,8 +1,6 @@
|
||||
--- A NOTASK is a dummy activity... But it will show a Mission Briefing...
|
||||
-- @module NOTASK
|
||||
|
||||
Include.File("Task")
|
||||
|
||||
--- The NOTASK class
|
||||
-- @type
|
||||
NOTASK = {
|
||||
|
||||
@ -2,9 +2,6 @@
|
||||
-- @module PICKUPTASK
|
||||
-- @parent TASK
|
||||
|
||||
Include.File("Task")
|
||||
Include.File("Cargo")
|
||||
|
||||
--- The PICKUPTASK class
|
||||
-- @type
|
||||
PICKUPTASK = {
|
||||
|
||||
@ -25,10 +25,6 @@
|
||||
-- @module Point
|
||||
-- @author FlightControl
|
||||
|
||||
Include.File( "Routines" )
|
||||
Include.File( "Base" )
|
||||
Include.File( "Point" )
|
||||
|
||||
--- The POINT_VEC3 class
|
||||
-- @type POINT_VEC3
|
||||
-- @extends Base#BASE
|
||||
|
||||
@ -2,10 +2,6 @@
|
||||
-- @module routines
|
||||
-- @author Flightcontrol
|
||||
|
||||
--Include.File( "Trace" )
|
||||
--Include.File( "Message" )
|
||||
|
||||
|
||||
env.setErrorMessageBoxEnabled(false)
|
||||
|
||||
--- Extract of MIST functions.
|
||||
@ -2310,19 +2306,19 @@ end
|
||||
function MessageToAll( MsgText, MsgTime, MsgName )
|
||||
--trace.f()
|
||||
|
||||
MESSAGE:New( MsgText, "Message", MsgTime, MsgName ):ToCoalition( coalition.side.RED ):ToCoalition( coalition.side.BLUE )
|
||||
MESSAGE:New( MsgText, MsgTime, "Message" ):ToCoalition( coalition.side.RED ):ToCoalition( coalition.side.BLUE )
|
||||
end
|
||||
|
||||
function MessageToRed( MsgText, MsgTime, MsgName )
|
||||
--trace.f()
|
||||
|
||||
MESSAGE:New( MsgText, "To Red Coalition", MsgTime, MsgName ):ToCoalition( coalition.side.RED )
|
||||
MESSAGE:New( MsgText, MsgTime, "To Red Coalition" ):ToCoalition( coalition.side.RED )
|
||||
end
|
||||
|
||||
function MessageToBlue( MsgText, MsgTime, MsgName )
|
||||
--trace.f()
|
||||
|
||||
MESSAGE:New( MsgText, "To Blue Coalition", MsgTime, MsgName ):ToCoalition( coalition.side.RED )
|
||||
MESSAGE:New( MsgText, MsgTime, "To Blue Coalition" ):ToCoalition( coalition.side.RED )
|
||||
end
|
||||
|
||||
function getCarrierHeight( CarrierGroup )
|
||||
|
||||
@ -20,10 +20,6 @@
|
||||
-- @module Scheduler
|
||||
-- @author FlightControl
|
||||
|
||||
Include.File( "Routines" )
|
||||
Include.File( "Base" )
|
||||
|
||||
|
||||
--- The SCHEDULER class
|
||||
-- @type SCHEDULER
|
||||
-- @extends Base#BASE
|
||||
|
||||
@ -7,13 +7,6 @@
|
||||
-- @author FlightControl
|
||||
|
||||
|
||||
Include.File( "Routines" )
|
||||
Include.File( "Base" )
|
||||
Include.File( "Menu" )
|
||||
Include.File( "Group" )
|
||||
Include.File( "Event" )
|
||||
|
||||
|
||||
--- The Scoring class
|
||||
-- @type SCORING
|
||||
-- @field Players A collection of the current players that have joined the game.
|
||||
@ -176,7 +169,7 @@ function SCORING:_EventOnDeadOrCrash( Event )
|
||||
MESSAGE:New( "Player '" .. PlayerName .. "' killed a friendly " .. TargetUnitCategory .. " ( " .. TargetType .. " ) " ..
|
||||
PlayerData.Kill[TargetCategory][TargetType].PenaltyKill .. " times. Penalty: -" .. PlayerData.Kill[TargetCategory][TargetType].Penalty ..
|
||||
". Score Total:" .. PlayerData.Score - PlayerData.Penalty,
|
||||
"", 5, "/PENALTY" .. PlayerName .. "/" .. InitUnitName ):ToAll()
|
||||
5 ):ToAll()
|
||||
self:ScoreCSV( PlayerName, "KILL_PENALTY", 1, -125, InitUnitName, InitUnitCoalition, InitUnitCategory, InitUnitType, TargetUnitName, TargetUnitCoalition, TargetUnitCategory, TargetUnitType )
|
||||
else
|
||||
PlayerData.Score = PlayerData.Score + 10
|
||||
@ -185,7 +178,7 @@ function SCORING:_EventOnDeadOrCrash( Event )
|
||||
MESSAGE:New( "Player '" .. PlayerName .. "' killed an enemy " .. TargetUnitCategory .. " ( " .. TargetType .. " ) " ..
|
||||
PlayerData.Kill[TargetCategory][TargetType].ScoreKill .. " times. Score: " .. PlayerData.Kill[TargetCategory][TargetType].Score ..
|
||||
". Score Total:" .. PlayerData.Score - PlayerData.Penalty,
|
||||
"", 5, "/SCORE" .. PlayerName .. "/" .. InitUnitName ):ToAll()
|
||||
5 ):ToAll()
|
||||
self:ScoreCSV( PlayerName, "KILL_SCORE", 1, 10, InitUnitName, InitUnitCoalition, InitUnitCategory, InitUnitType, TargetUnitName, TargetUnitCoalition, TargetUnitCategory, TargetUnitType )
|
||||
end
|
||||
end
|
||||
@ -236,9 +229,7 @@ function SCORING:_AddPlayerFromUnit( UnitData )
|
||||
self.Players[PlayerName].PenaltyCoalition = self.Players[PlayerName].PenaltyCoalition + 1
|
||||
MESSAGE:New( "Player '" .. PlayerName .. "' changed coalition from " .. _SCORINGCoalition[self.Players[PlayerName].UnitCoalition] .. " to " .. _SCORINGCoalition[UnitCoalition] ..
|
||||
"(changed " .. self.Players[PlayerName].PenaltyCoalition .. " times the coalition). 50 Penalty points added.",
|
||||
"",
|
||||
2,
|
||||
"/PENALTYCOALITION" .. PlayerName
|
||||
2
|
||||
):ToAll()
|
||||
self:ScoreCSV( PlayerName, "COALITION_PENALTY", 1, -50, self.Players[PlayerName].UnitName, _SCORINGCoalition[self.Players[PlayerName].UnitCoalition], _SCORINGCategory[self.Players[PlayerName].UnitCategory], self.Players[PlayerName].UnitType,
|
||||
UnitName, _SCORINGCoalition[UnitCoalition], _SCORINGCategory[UnitCategory], UnitData:getTypeName() )
|
||||
@ -252,9 +243,7 @@ function SCORING:_AddPlayerFromUnit( UnitData )
|
||||
if self.Players[PlayerName].Penalty > 100 then
|
||||
if self.Players[PlayerName].PenaltyWarning < 1 then
|
||||
MESSAGE:New( "Player '" .. PlayerName .. "': WARNING! If you continue to commit FRATRICIDE and have a PENALTY score higher than 150, you will be COURT MARTIALED and DISMISSED from this mission! \nYour total penalty is: " .. self.Players[PlayerName].Penalty,
|
||||
"",
|
||||
30,
|
||||
"/PENALTYCOALITION" .. PlayerName
|
||||
30
|
||||
):ToAll()
|
||||
self.Players[PlayerName].PenaltyWarning = self.Players[PlayerName].PenaltyWarning + 1
|
||||
end
|
||||
@ -264,9 +253,7 @@ function SCORING:_AddPlayerFromUnit( UnitData )
|
||||
ClientGroup = GROUP:NewFromDCSUnit( UnitData )
|
||||
ClientGroup:Destroy()
|
||||
MESSAGE:New( "Player '" .. PlayerName .. "' committed FRATRICIDE, he will be COURT MARTIALED and is DISMISSED from this mission!",
|
||||
"",
|
||||
10,
|
||||
"/PENALTYCOALITION" .. PlayerName
|
||||
10
|
||||
):ToAll()
|
||||
end
|
||||
|
||||
@ -294,7 +281,7 @@ function SCORING:_AddMissionTaskScore( PlayerUnit, MissionName, Score )
|
||||
|
||||
MESSAGE:New( "Player '" .. PlayerName .. "' has finished another Task in Mission '" .. MissionName .. "'. " ..
|
||||
Score .. " Score points added.",
|
||||
"", 20, "/SCORETASK" .. PlayerName ):ToAll()
|
||||
20 ):ToAll()
|
||||
|
||||
self:ScoreCSV( PlayerName, "TASK_" .. MissionName:gsub( ' ', '_' ), 1, Score, PlayerUnit:getName() )
|
||||
end
|
||||
@ -311,7 +298,7 @@ function SCORING:_AddMissionScore( MissionName, Score )
|
||||
PlayerData.Mission[MissionName].ScoreMission = PlayerData.Mission[MissionName].ScoreMission + Score
|
||||
MESSAGE:New( "Player '" .. PlayerName .. "' has finished Mission '" .. MissionName .. "'. " ..
|
||||
Score .. " Score points added.",
|
||||
"", 20, "/SCOREMISSION" .. PlayerName ):ToAll()
|
||||
20 ):ToAll()
|
||||
self:ScoreCSV( PlayerName, "MISSION_" .. MissionName:gsub( ' ', '_' ), 1, Score )
|
||||
end
|
||||
end
|
||||
@ -421,9 +408,7 @@ function SCORING:_EventOnHit( Event )
|
||||
MESSAGE:New( "Player '" .. InitPlayerName .. "' hit a friendly " .. TargetUnitCategory .. " ( " .. TargetType .. " ) " ..
|
||||
self.Players[InitPlayerName].Hit[TargetCategory][TargetUnitName].PenaltyHit .. " times. Penalty: -" .. self.Players[InitPlayerName].Hit[TargetCategory][TargetUnitName].Penalty ..
|
||||
". Score Total:" .. self.Players[InitPlayerName].Score - self.Players[InitPlayerName].Penalty,
|
||||
"",
|
||||
2,
|
||||
"/PENALTY" .. InitPlayerName .. "/" .. InitUnitName
|
||||
2
|
||||
):ToAll()
|
||||
self:ScoreCSV( InitPlayerName, "HIT_PENALTY", 1, -25, InitUnitName, InitUnitCoalition, InitUnitCategory, InitUnitType, TargetUnitName, TargetUnitCoalition, TargetUnitCategory, TargetUnitType )
|
||||
else
|
||||
@ -433,9 +418,7 @@ function SCORING:_EventOnHit( Event )
|
||||
MESSAGE:New( "Player '" .. InitPlayerName .. "' hit a target " .. TargetUnitCategory .. " ( " .. TargetType .. " ) " ..
|
||||
self.Players[InitPlayerName].Hit[TargetCategory][TargetUnitName].ScoreHit .. " times. Score: " .. self.Players[InitPlayerName].Hit[TargetCategory][TargetUnitName].Score ..
|
||||
". Score Total:" .. self.Players[InitPlayerName].Score - self.Players[InitPlayerName].Penalty,
|
||||
"",
|
||||
2,
|
||||
"/SCORE" .. InitPlayerName .. "/" .. InitUnitName
|
||||
2
|
||||
):ToAll()
|
||||
self:ScoreCSV( InitPlayerName, "HIT_SCORE", 1, 1, InitUnitName, InitUnitCoalition, InitUnitCategory, InitUnitType, TargetUnitName, TargetUnitCoalition, TargetUnitCategory, TargetUnitType )
|
||||
end
|
||||
@ -556,7 +539,7 @@ function SCORING:ReportScoreAll()
|
||||
PlayerMessage = PlayerMessage .. string.format( "Player '%s' Score:%d (%d Score -%d Penalties)%s", PlayerName, PlayerScore - PlayerPenalty, PlayerScore, PlayerPenalty, ScoreMessage )
|
||||
end
|
||||
end
|
||||
MESSAGE:New( PlayerMessage, "Player Scores", 30, "AllPlayerScores"):ToAll()
|
||||
MESSAGE:New( PlayerMessage, 30, "Player Scores" ):ToAll()
|
||||
end
|
||||
|
||||
|
||||
@ -669,7 +652,7 @@ function SCORING:ReportScorePlayer()
|
||||
PlayerMessage = PlayerMessage .. string.format( "Player '%s' Score = %d ( %d Score, -%d Penalties ):%s", PlayerName, PlayerScore - PlayerPenalty, PlayerScore, PlayerPenalty, ScoreMessage )
|
||||
end
|
||||
end
|
||||
MESSAGE:New( PlayerMessage, "Player Scores", 30, "AllPlayerScores"):ToAll()
|
||||
MESSAGE:New( PlayerMessage, 30, "Player Scores" ):ToAll()
|
||||
|
||||
end
|
||||
|
||||
|
||||
@ -3,13 +3,6 @@
|
||||
-- @author to be searched on the forum
|
||||
-- @author (co) Flightcontrol (Modified and enriched with functionality)
|
||||
|
||||
Include.File( "Routines" )
|
||||
Include.File( "Event" )
|
||||
Include.File( "Base" )
|
||||
Include.File( "Mission" )
|
||||
Include.File( "Client" )
|
||||
Include.File( "Task" )
|
||||
|
||||
--- The SEAD class
|
||||
-- @type SEAD
|
||||
-- @extends Base#BASE
|
||||
|
||||
@ -181,14 +181,6 @@
|
||||
-- @module Set
|
||||
-- @author FlightControl
|
||||
|
||||
Include.File( "Routines" )
|
||||
Include.File( "Base" )
|
||||
Include.File( "Menu" )
|
||||
Include.File( "Group" )
|
||||
Include.File( "Unit" )
|
||||
Include.File( "Event" )
|
||||
Include.File( "Client" )
|
||||
|
||||
--- SET_BASE class
|
||||
-- @type SET_BASE
|
||||
-- @extends Base#BASE
|
||||
|
||||
@ -74,14 +74,6 @@
|
||||
-- @module Spawn
|
||||
-- @author FlightControl
|
||||
|
||||
Include.File( "Routines" )
|
||||
Include.File( "Base" )
|
||||
Include.File( "Database" )
|
||||
Include.File( "Group" )
|
||||
Include.File( "Zone" )
|
||||
Include.File( "Event" )
|
||||
Include.File( "Scheduler" )
|
||||
|
||||
--- SPAWN Class
|
||||
-- @type SPAWN
|
||||
-- @extends Base#BASE
|
||||
@ -783,7 +775,7 @@ end
|
||||
-- If no index is given, it will return the first group in the list.
|
||||
-- @param #SPAWN self
|
||||
-- @param #number SpawnIndex The index of the group to return.
|
||||
-- @return Group#GROUP
|
||||
-- @return Group#GROUP self
|
||||
function SPAWN:GetGroupFromIndex( SpawnIndex )
|
||||
self:F( { self.SpawnTemplatePrefix, self.SpawnAliasPrefix, SpawnIndex } )
|
||||
|
||||
|
||||
@ -2,11 +2,11 @@
|
||||
-- @module STAGE
|
||||
-- @author Flightcontrol
|
||||
|
||||
Include.File( "Routines" )
|
||||
Include.File( "Base" )
|
||||
Include.File( "Mission" )
|
||||
Include.File( "Client" )
|
||||
Include.File( "Task" )
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
--- The STAGE class
|
||||
-- @type
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
--- Provides a logging of statistics in a running DCS Mission.
|
||||
-- @script eStatHandler
|
||||
|
||||
Include.File( "Routines" )
|
||||
|
||||
|
||||
|
||||
--Handler table
|
||||
|
||||
@ -31,9 +31,9 @@
|
||||
-- @module Static
|
||||
-- @author FlightControl
|
||||
|
||||
Include.File( "Routines" )
|
||||
Include.File( "Base" )
|
||||
Include.File( "Message" )
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
--- The STATIC class
|
||||
|
||||
@ -1,11 +1,11 @@
|
||||
--- The TASK Classes define major end-to-end activities within a MISSION. The TASK Class is the Master Class to orchestrate these activities. From this class, many concrete TASK classes are inherited.
|
||||
-- @module TASK
|
||||
|
||||
Include.File( "Routines" )
|
||||
Include.File( "Base" )
|
||||
Include.File( "Mission" )
|
||||
Include.File( "Client" )
|
||||
Include.File( "Stage" )
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
--- The TASK class
|
||||
-- @type TASK
|
||||
|
||||
@ -68,9 +68,9 @@
|
||||
-- @module Unit
|
||||
-- @author FlightControl
|
||||
|
||||
Include.File( "Routines" )
|
||||
Include.File( "Base" )
|
||||
Include.File( "Message" )
|
||||
|
||||
|
||||
|
||||
|
||||
--- The UNIT class
|
||||
-- @type UNIT
|
||||
|
||||
@ -62,10 +62,10 @@
|
||||
-- @author FlightControl
|
||||
|
||||
|
||||
Include.File( "Routines" )
|
||||
Include.File( "Base" )
|
||||
Include.File( "Message" )
|
||||
Include.File( "Point" )
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -1,6 +1,6 @@
|
||||
Include.File( 'Cleanup' )
|
||||
Include.File( 'Spawn' )
|
||||
Include.File( 'Event')
|
||||
|
||||
|
||||
|
||||
|
||||
Clean = CLEANUP:New( 'CLEAN_BATUMI', 180 )
|
||||
|
||||
|
||||
Binary file not shown.
@ -1,108 +0,0 @@
|
||||
|
||||
Include.File( 'UnitSet' )
|
||||
Include.File( 'GroupSet' )
|
||||
Include.File( 'Spawn' )
|
||||
|
||||
DBBluePlanes = UNITSET:New()
|
||||
:FilterCoalitions( "blue" )
|
||||
:FilterCategories( "plane" )
|
||||
:FilterStart()
|
||||
|
||||
DBRedVehicles = UNITSET:New()
|
||||
:FilterCoalitions( "red" )
|
||||
:FilterCategories( "ground" )
|
||||
:FilterStart()
|
||||
|
||||
DBShips = UNITSET:New()
|
||||
:FilterCategories( "ship" )
|
||||
:FilterStart()
|
||||
|
||||
DBBelgium = UNITSET:New()
|
||||
:FilterCategories( "helicopter" )
|
||||
:FilterCountries( "BELGIUM" )
|
||||
:FilterStart()
|
||||
|
||||
DBNorthKorea = UNITSET:New()
|
||||
:FilterCountries( "NORTH_KOREA" )
|
||||
:FilterStart()
|
||||
|
||||
DBKA50Vinson = UNITSET:New()
|
||||
:FilterTypes( { "Ka-50", "VINSON" } )
|
||||
:FilterStart()
|
||||
|
||||
DBBluePlanesGroup = GROUPSET:New()
|
||||
:FilterCoalitions( "blue" )
|
||||
:FilterCategories( "plane" )
|
||||
:FilterStart()
|
||||
|
||||
DBNorthKoreaGroup = GROUPSET:New()
|
||||
:FilterCountries( "NORTH_KOREA" )
|
||||
:FilterStart()
|
||||
|
||||
DBBluePlanes:Flush()
|
||||
DBRedVehicles:Flush()
|
||||
DBShips:Flush()
|
||||
DBBelgium:Flush()
|
||||
DBNorthKorea:Flush()
|
||||
DBKA50Vinson:Flush()
|
||||
DBBluePlanesGroup:Flush()
|
||||
DBNorthKoreaGroup:Flush()
|
||||
|
||||
|
||||
SpawnUS_Plane = SPAWN:New( 'Database Spawn Test USA Plane')
|
||||
GroupUS_Plane = SpawnUS_Plane:Spawn()
|
||||
|
||||
SpawnUS_Vehicle = SPAWN:New( 'Database Spawn Test USA Vehicle')
|
||||
GroupUS_Vehicle = SpawnUS_Vehicle:Spawn()
|
||||
|
||||
SpawnUS_Ship = SPAWN:New( 'Database Spawn Test USA Ship')
|
||||
GroupUS_Ship = SpawnUS_Ship:Spawn()
|
||||
|
||||
SpawnRU_Vehicle = SPAWN:New( 'Database Spawn Test RUSSIA Vehicle')
|
||||
GroupRU_Vehicle = SpawnRU_Vehicle:Spawn()
|
||||
|
||||
SpawnRU_Ship = SPAWN:New( 'Database Spawn Test RUSSIA Ship')
|
||||
GroupRU_Ship = SpawnRU_Ship:Spawn()
|
||||
|
||||
SpawnUS_AttackVehicle = SPAWN:New( 'Database Spawn Test USA Attack Vehicle' )
|
||||
SpawnRU_AttackVehicle = SPAWN:New( 'Database Spawn Test RUSSIA Attack Vehicle' )
|
||||
|
||||
for i = 1, 2 do
|
||||
GroupRU_AttackVehicle = SpawnRU_AttackVehicle:SpawnInZone( ZONE:New("Spawn Zone RU"), true)
|
||||
GroupUS_AttackVehicle = SpawnUS_AttackVehicle:SpawnInZone( ZONE:New("Spawn Zone US"), true)
|
||||
end
|
||||
|
||||
|
||||
--DBBlue:TraceDatabase()
|
||||
SCHEDULER:New( DBBluePlanes, DBBluePlanes.Flush, { }, 1 )
|
||||
SCHEDULER:New( DBRedVehicles, DBRedVehicles.Flush, { }, 1 )
|
||||
SCHEDULER:New( DBShips, DBShips.Flush, { }, 1 )
|
||||
SCHEDULER:New( DBBelgium, DBBelgium.Flush, { }, 1 )
|
||||
SCHEDULER:New( DBNorthKorea, DBNorthKorea.Flush, { }, 1 )
|
||||
SCHEDULER:New( DBKA50Vinson, DBKA50Vinson.Flush, { }, 1 )
|
||||
|
||||
SCHEDULER:New( DBBluePlanesGroup, DBBluePlanesGroup.Flush, { }, 1 )
|
||||
SCHEDULER:New( DBNorthKoreaGroup, DBNorthKoreaGroup.Flush, { }, 1 )
|
||||
|
||||
DBRedVehicles
|
||||
:ForEachUnit( function( MooseUnit )
|
||||
DBRedVehicles:T( MooseUnit:GetName() )
|
||||
end )
|
||||
|
||||
local function FlushPlayers()
|
||||
|
||||
_DATABASE:E( "FlushPlayers" )
|
||||
_DATABASE
|
||||
:ForEachPlayerAlive( function( Player )
|
||||
_DATABASE:E( Player )
|
||||
MESSAGE:New( Player, "Test", 5, "Player Test" ):ToAll()
|
||||
return true
|
||||
end )
|
||||
return true
|
||||
end
|
||||
|
||||
_DATABASE:E( "Schedule" )
|
||||
local PlayerShow = SCHEDULER:New( nil, FlushPlayers, {}, 1, 10 )
|
||||
|
||||
|
||||
|
||||
Binary file not shown.
Binary file not shown.
@ -1,13 +1,3 @@
|
||||
-- MOOSE include files.
|
||||
Include.File( "Mission" )
|
||||
Include.File( "Client" )
|
||||
Include.File( "DestroyGroupsTask" )
|
||||
Include.File( "DestroyRadarsTask" )
|
||||
Include.File( "DestroyUnitTypesTask" )
|
||||
Include.File( "Group" )
|
||||
Include.File( "Unit" )
|
||||
Include.File( "Zone" )
|
||||
Include.File( "Event" )
|
||||
|
||||
do
|
||||
local Mission = MISSION:New( 'Destroy Gound', 'Ground', 'Briefing', 'CCCP' )
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
Include.File( "Mission" )
|
||||
Include.File( "Client" )
|
||||
Include.File( "Spawn" )
|
||||
Include.File( "Escort" )
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
Binary file not shown.
@ -2,7 +2,7 @@
|
||||
-- Only use Include.File when developing new MOOSE classes.
|
||||
-- When using Moose.lua in the DO SCIPTS FILE initialization box,
|
||||
-- these Include.File statements are not needed, because all classes within Moose will be loaded.
|
||||
Include.File("MissileTrainer")
|
||||
|
||||
|
||||
-- This is an example of a global
|
||||
local Trainer = MISSILETRAINER
|
||||
|
||||
Binary file not shown.
Binary file not shown.
@ -1,4 +1,4 @@
|
||||
Include.File( "Sead" )
|
||||
|
||||
|
||||
|
||||
-- CCCP SEAD Defenses
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
|
||||
Include.File( 'Set' )
|
||||
Include.File( 'Spawn' )
|
||||
|
||||
|
||||
|
||||
SetVehicles = SET_GROUP:New()
|
||||
|
||||
|
||||
Binary file not shown.
@ -1,4 +1,4 @@
|
||||
Include.File( "Spawn" )
|
||||
|
||||
|
||||
|
||||
-- Tests Anapa: Spawn Basics
|
||||
|
||||
Binary file not shown.
@ -10,7 +10,7 @@
|
||||
-- @author FlightControl
|
||||
|
||||
|
||||
Include.File("Spawn")
|
||||
|
||||
|
||||
do
|
||||
|
||||
|
||||
Binary file not shown.
@ -1,15 +1,15 @@
|
||||
Include.File( "Mission" )
|
||||
Include.File( "Client" )
|
||||
Include.File( "DeployTask" )
|
||||
Include.File( "PickupTask" )
|
||||
Include.File( "DestroyGroupsTask" )
|
||||
Include.File( "DestroyRadarsTask" )
|
||||
Include.File( "DestroyUnitTypesTask" )
|
||||
Include.File( "GoHomeTask" )
|
||||
Include.File( "Spawn" )
|
||||
Include.File( "Movement" )
|
||||
Include.File( "Sead" )
|
||||
Include.File( "CleanUp" )
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
do
|
||||
local Mission = MISSION:New( 'Pickup', 'Operational', 'Pickup Troops', 'NATO' )
|
||||
|
||||
Binary file not shown.
@ -1,7 +1,7 @@
|
||||
|
||||
Include.File( "Group" )
|
||||
Include.File( "Unit" )
|
||||
Include.File( "Client" )
|
||||
|
||||
|
||||
|
||||
|
||||
BASE:TraceClass( "UNIT" )
|
||||
BASE:TraceClass( "GROUP" )
|
||||
|
||||
Binary file not shown.
@ -1,7 +1,7 @@
|
||||
|
||||
Include.File( "Zone" )
|
||||
Include.File( "Group" )
|
||||
Include.File( "Scheduler" )
|
||||
|
||||
|
||||
|
||||
|
||||
local GroupInside = GROUP:FindByName( "Test Inside Polygon" )
|
||||
local GroupOutside = GROUP:FindByName( "Test Outside Polygon" )
|
||||
|
||||
Binary file not shown.
@ -1,7 +1,7 @@
|
||||
|
||||
Include.File( "Zone" )
|
||||
Include.File( "Group" )
|
||||
Include.File( "Scheduler" )
|
||||
|
||||
|
||||
|
||||
|
||||
local GroupInside = GROUP:FindByName( "Test Inside Polygon" )
|
||||
local GroupOutside = GROUP:FindByName( "Test Outside Polygon" )
|
||||
|
||||
Binary file not shown.
@ -1,7 +1,7 @@
|
||||
|
||||
Include.File( "Zone" )
|
||||
Include.File( "Group" )
|
||||
Include.File( "Scheduler" )
|
||||
|
||||
|
||||
|
||||
|
||||
local GroupInside = GROUP:FindByName( "Test Inside Polygon" )
|
||||
local GroupOutside = GROUP:FindByName( "Test Outside Polygon" )
|
||||
|
||||
Binary file not shown.
@ -1,7 +1,7 @@
|
||||
|
||||
Include.File( "Zone" )
|
||||
Include.File( "Group" )
|
||||
Include.File( "Scheduler" )
|
||||
|
||||
|
||||
|
||||
|
||||
local GroupInside = GROUP:FindByName( "Test Inside Polygon" )
|
||||
local GroupOutside = GROUP:FindByName( "Test Outside Polygon" )
|
||||
|
||||
Binary file not shown.
@ -1,620 +0,0 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html>
|
||||
<head>
|
||||
<link rel="stylesheet" href="stylesheet.css" type="text/css"/>
|
||||
</head>
|
||||
<body>
|
||||
<div id="container">
|
||||
<div id="product">
|
||||
<div id="product_logo"></div>
|
||||
<div id="product_name"><big><b></b></big></div>
|
||||
<div id="product_description"></div>
|
||||
</div>
|
||||
<div id="main">
|
||||
<div id="navigation">
|
||||
<h2>Modules</h2>
|
||||
<ul><li>
|
||||
<a href="index.html">index</a>
|
||||
</li></ul>
|
||||
<ul>
|
||||
<li><a href="Airbase.html">Airbase</a></li>
|
||||
<li><a href="Base.html">Base</a></li>
|
||||
<li><a href="CARGO.html">CARGO</a></li>
|
||||
<li><a href="CleanUp.html">CleanUp</a></li>
|
||||
<li><a href="Client.html">Client</a></li>
|
||||
<li><a href="DCSAirbase.html">DCSAirbase</a></li>
|
||||
<li><a href="DCSCoalitionObject.html">DCSCoalitionObject</a></li>
|
||||
<li><a href="DCSCommand.html">DCSCommand</a></li>
|
||||
<li><a href="DCSController.html">DCSController</a></li>
|
||||
<li><a href="DCSGroup.html">DCSGroup</a></li>
|
||||
<li><a href="DCSObject.html">DCSObject</a></li>
|
||||
<li><a href="DCSTask.html">DCSTask</a></li>
|
||||
<li><a href="DCSTypes.html">DCSTypes</a></li>
|
||||
<li><a href="DCSUnit.html">DCSUnit</a></li>
|
||||
<li><a href="DCSWorld.html">DCSWorld</a></li>
|
||||
<li><a href="DCStimer.html">DCStimer</a></li>
|
||||
<li><a href="DEPLOYTASK.html">DEPLOYTASK</a></li>
|
||||
<li><a href="DESTROYBASETASK.html">DESTROYBASETASK</a></li>
|
||||
<li><a href="DESTROYGROUPSTASK.html">DESTROYGROUPSTASK</a></li>
|
||||
<li><a href="DESTROYRADARSTASK.html">DESTROYRADARSTASK</a></li>
|
||||
<li><a href="DESTROYUNITTYPESTASK.html">DESTROYUNITTYPESTASK</a></li>
|
||||
<li><a href="Database.html">Database</a></li>
|
||||
<li><a href="Escort.html">Escort</a></li>
|
||||
<li><a href="Event.html">Event</a></li>
|
||||
<li><a href="GOHOMETASK.html">GOHOMETASK</a></li>
|
||||
<li><a href="Group.html">Group</a></li>
|
||||
<li>GroupSet</li>
|
||||
<li><a href="MOVEMENT.html">MOVEMENT</a></li>
|
||||
<li><a href="Menu.html">Menu</a></li>
|
||||
<li><a href="Message.html">Message</a></li>
|
||||
<li><a href="MissileTrainer.html">MissileTrainer</a></li>
|
||||
<li><a href="Mission.html">Mission</a></li>
|
||||
<li><a href="NOTASK.html">NOTASK</a></li>
|
||||
<li><a href="PICKUPTASK.html">PICKUPTASK</a></li>
|
||||
<li><a href="Point.html">Point</a></li>
|
||||
<li><a href="ROUTETASK.html">ROUTETASK</a></li>
|
||||
<li><a href="STAGE.html">STAGE</a></li>
|
||||
<li><a href="Scheduler.html">Scheduler</a></li>
|
||||
<li><a href="Scoring.html">Scoring</a></li>
|
||||
<li><a href="Sead.html">Sead</a></li>
|
||||
<li><a href="Set.html">Set</a></li>
|
||||
<li><a href="Spawn.html">Spawn</a></li>
|
||||
<li><a href="Static.html">Static</a></li>
|
||||
<li><a href="StaticObject.html">StaticObject</a></li>
|
||||
<li><a href="TASK.html">TASK</a></li>
|
||||
<li><a href="Unit.html">Unit</a></li>
|
||||
<li><a href="UnitSet.html">UnitSet</a></li>
|
||||
<li><a href="Zone.html">Zone</a></li>
|
||||
<li><a href="env.html">env</a></li>
|
||||
<li><a href="land.html">land</a></li>
|
||||
<li><a href="routines.html">routines</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
<div id="content">
|
||||
<h1>Module <code>GroupSet</code></h1>
|
||||
|
||||
<p>Create and manage a set of groups.</p>
|
||||
|
||||
|
||||
|
||||
<h1><a href="##(GROUPSET)">#GROUPSET</a> class</h1>
|
||||
<p>Mission designers can use the GROUPSET class to build sets of groups belonging to certain:</p>
|
||||
|
||||
<ul>
|
||||
<li>Coalitions</li>
|
||||
<li>Categories</li>
|
||||
<li>Countries</li>
|
||||
<li>Starting with certain prefix strings.</li>
|
||||
</ul>
|
||||
|
||||
<h1>GROUPSET construction methods:</h1>
|
||||
<p>Create a new GROUPSET object with the <a href="##(GROUPSET).New">GROUPSET.New</a> method:</p>
|
||||
|
||||
<ul>
|
||||
<li><a href="##(GROUPSET).New">GROUPSET.New</a>: Creates a new GROUPSET object.</li>
|
||||
</ul>
|
||||
|
||||
|
||||
<h1>GROUPSET filter criteria: </h1>
|
||||
<p>You can set filter criteria to define the set of groups within the GROUPSET.
|
||||
Filter criteria are defined by:</p>
|
||||
|
||||
<ul>
|
||||
<li><a href="##(GROUPSET).FilterCoalitions">GROUPSET.FilterCoalitions</a>: Builds the GROUPSET with the groups belonging to the coalition(s).</li>
|
||||
<li><a href="##(GROUPSET).FilterCategories">GROUPSET.FilterCategories</a>: Builds the GROUPSET with the groups belonging to the category(ies).</li>
|
||||
<li><a href="##(GROUPSET).FilterCountries">GROUPSET.FilterCountries</a>: Builds the GROUPSET with the gruops belonging to the country(ies).</li>
|
||||
<li><a href="##(GROUPSET).FilterPrefixes">GROUPSET.FilterPrefixes</a>: Builds the GROUPSET with the groups starting with the same prefix string(s).</li>
|
||||
</ul>
|
||||
|
||||
<p>Once the filter criteria have been set for the GROUPSET, you can start filtering using:</p>
|
||||
|
||||
<ul>
|
||||
<li><a href="##(GROUPSET).FilterStart">GROUPSET.FilterStart</a>: Starts the filtering of the groups within the GROUPSET.</li>
|
||||
</ul>
|
||||
|
||||
<p>Planned filter criteria within development are (so these are not yet available):</p>
|
||||
|
||||
<ul>
|
||||
<li><a href="##(GROUPSET).FilterZones">GROUPSET.FilterZones</a>: Builds the GROUPSET with the groups within a <a href="Zone.html##(ZONE)">Zone#ZONE</a>.</li>
|
||||
</ul>
|
||||
|
||||
|
||||
<h1>GROUPSET iterators:</h1>
|
||||
<p>Once the filters have been defined and the GROUPSET has been built, you can iterate the GROUPSET with the available iterator methods.
|
||||
The iterator methods will walk the GROUPSET set, and call for each element within the set a function that you provide.
|
||||
The following iterator methods are currently available within the GROUPSET:</p>
|
||||
|
||||
<ul>
|
||||
<li><a href="##(GROUPSET).ForEachGroup">GROUPSET.ForEachGroup</a>: Calls a function for each alive group it finds within the GROUPSET.</li>
|
||||
</ul>
|
||||
|
||||
|
||||
<h2>Global(s)</h2>
|
||||
<table class="function_list">
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="#GROUPSET">GROUPSET</a></td>
|
||||
<td class="summary">
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<h2><a id="#(GROUPSET)">Type <code>GROUPSET</code></a></h2>
|
||||
<table class="function_list">
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(GROUPSET).AddInDatabase">GROUPSET:AddInDatabase(Event)</a></td>
|
||||
<td class="summary">
|
||||
<p>Handles the Database to check on an event (birth) that the Object was added in the Database.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(GROUPSET).ClassName">GROUPSET.ClassName</a></td>
|
||||
<td class="summary">
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(GROUPSET).Filter">GROUPSET.Filter</a></td>
|
||||
<td class="summary">
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(GROUPSET).FilterCategories">GROUPSET:FilterCategories(Categories)</a></td>
|
||||
<td class="summary">
|
||||
<p>Builds a set of groups out of categories.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(GROUPSET).FilterCoalitions">GROUPSET:FilterCoalitions(Coalitions)</a></td>
|
||||
<td class="summary">
|
||||
<p>Builds a set of groups of coalitions.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(GROUPSET).FilterCountries">GROUPSET:FilterCountries(Countries)</a></td>
|
||||
<td class="summary">
|
||||
<p>Builds a set of groups of defined countries.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(GROUPSET).FilterMeta">GROUPSET.FilterMeta</a></td>
|
||||
<td class="summary">
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(GROUPSET).FilterPrefixes">GROUPSET:FilterPrefixes(Prefixes)</a></td>
|
||||
<td class="summary">
|
||||
<p>Builds a set of groups of defined GROUP prefixes.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(GROUPSET).FilterStart">GROUPSET:FilterStart()</a></td>
|
||||
<td class="summary">
|
||||
<p>Starts the filtering.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(GROUPSET).FindGroup">GROUPSET:FindGroup(GroupName)</a></td>
|
||||
<td class="summary">
|
||||
<p>Finds a Group based on the Group Name.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(GROUPSET).FindInDatabase">GROUPSET:FindInDatabase(Event)</a></td>
|
||||
<td class="summary">
|
||||
<p>Handles the Database to check on any event that Object exists in the Database.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(GROUPSET).ForEachGroup">GROUPSET:ForEachGroup(IteratorFunction, ...)</a></td>
|
||||
<td class="summary">
|
||||
<p>Interate the GROUPSET and call an interator function for each <strong>alive</strong> GROUP, providing the GROUP and optional parameters.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(GROUPSET).IsIncludeObject">GROUPSET:IsIncludeObject(MooseGroup)</a></td>
|
||||
<td class="summary">
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(GROUPSET).New">GROUPSET:New()</a></td>
|
||||
<td class="summary">
|
||||
<p>Creates a new GROUPSET object, building a set of groups belonging to a coalitions, categories, countries, types or with defined prefix names.</p>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<h2>Global(s)</h2>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<em><a href="##(GROUPSET)">#GROUPSET</a></em>
|
||||
<a id="GROUPSET" >
|
||||
<strong>GROUPSET</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<h2><a id="#(GroupSet)" >Type <code>GroupSet</code></a></h2>
|
||||
|
||||
<h2><a id="#(GROUPSET)" >Type <code>GROUPSET</code></a></h2>
|
||||
|
||||
<p>GROUPSET class</p>
|
||||
|
||||
<h3>Field(s)</h3>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(GROUPSET).AddInDatabase" >
|
||||
<strong>GROUPSET:AddInDatabase(Event)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Handles the Database to check on an event (birth) that the Object was added in the Database.</p>
|
||||
|
||||
|
||||
<p>This is required, because sometimes the _DATABASE birth event gets called later than the SET birth event!</p>
|
||||
|
||||
<h3>Parameter</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Event.html##(EVENTDATA)">Event#EVENTDATA</a> Event </em></code>: </p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return values</h3>
|
||||
<ol>
|
||||
<li>
|
||||
|
||||
<p><em>#string:</em>
|
||||
The name of the GROUP</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><em>#table:</em>
|
||||
The GROUP</p>
|
||||
|
||||
</li>
|
||||
</ol>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<em>#string</em>
|
||||
<a id="#(GROUPSET).ClassName" >
|
||||
<strong>GROUPSET.ClassName</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<em></em>
|
||||
<a id="#(GROUPSET).Filter" >
|
||||
<strong>GROUPSET.Filter</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(GROUPSET).FilterCategories" >
|
||||
<strong>GROUPSET:FilterCategories(Categories)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Builds a set of groups out of categories.</p>
|
||||
|
||||
|
||||
<p>Possible current categories are plane, helicopter, ground, ship.</p>
|
||||
|
||||
<h3>Parameter</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string Categories </em></code>:
|
||||
Can take the following values: "plane", "helicopter", "ground", "ship".</p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(GROUPSET)">#GROUPSET</a>:</em>
|
||||
self</p>
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(GROUPSET).FilterCoalitions" >
|
||||
<strong>GROUPSET:FilterCoalitions(Coalitions)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Builds a set of groups of coalitions.</p>
|
||||
|
||||
|
||||
<p>Possible current coalitions are red, blue and neutral.</p>
|
||||
|
||||
<h3>Parameter</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string Coalitions </em></code>:
|
||||
Can take the following values: "red", "blue", "neutral".</p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(GROUPSET)">#GROUPSET</a>:</em>
|
||||
self</p>
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(GROUPSET).FilterCountries" >
|
||||
<strong>GROUPSET:FilterCountries(Countries)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Builds a set of groups of defined countries.</p>
|
||||
|
||||
|
||||
<p>Possible current countries are those known within DCS world.</p>
|
||||
|
||||
<h3>Parameter</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string Countries </em></code>:
|
||||
Can take those country strings known within DCS world.</p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(GROUPSET)">#GROUPSET</a>:</em>
|
||||
self</p>
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<em></em>
|
||||
<a id="#(GROUPSET).FilterMeta" >
|
||||
<strong>GROUPSET.FilterMeta</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(GROUPSET).FilterPrefixes" >
|
||||
<strong>GROUPSET:FilterPrefixes(Prefixes)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Builds a set of groups of defined GROUP prefixes.</p>
|
||||
|
||||
|
||||
<p>All the groups starting with the given prefixes will be included within the set.</p>
|
||||
|
||||
<h3>Parameter</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string Prefixes </em></code>:
|
||||
The prefix of which the group name starts with.</p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(GROUPSET)">#GROUPSET</a>:</em>
|
||||
self</p>
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(GROUPSET).FilterStart" >
|
||||
<strong>GROUPSET:FilterStart()</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Starts the filtering.</p>
|
||||
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(GROUPSET)">#GROUPSET</a>:</em>
|
||||
self</p>
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(GROUPSET).FindGroup" >
|
||||
<strong>GROUPSET:FindGroup(GroupName)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Finds a Group based on the Group Name.</p>
|
||||
|
||||
<h3>Parameter</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string GroupName </em></code>: </p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="Group.html##(GROUP)">Group#GROUP</a>:</em>
|
||||
The found Group.</p>
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(GROUPSET).FindInDatabase" >
|
||||
<strong>GROUPSET:FindInDatabase(Event)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Handles the Database to check on any event that Object exists in the Database.</p>
|
||||
|
||||
|
||||
<p>This is required, because sometimes the _DATABASE event gets called later than the SET event or vise versa!</p>
|
||||
|
||||
<h3>Parameter</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Event.html##(EVENTDATA)">Event#EVENTDATA</a> Event </em></code>: </p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return values</h3>
|
||||
<ol>
|
||||
<li>
|
||||
|
||||
<p><em>#string:</em>
|
||||
The name of the GROUP</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><em>#table:</em>
|
||||
The GROUP</p>
|
||||
|
||||
</li>
|
||||
</ol>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(GROUPSET).ForEachGroup" >
|
||||
<strong>GROUPSET:ForEachGroup(IteratorFunction, ...)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Interate the GROUPSET and call an interator function for each <strong>alive</strong> GROUP, providing the GROUP and optional parameters.</p>
|
||||
|
||||
<h3>Parameters</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em>#function IteratorFunction </em></code>:
|
||||
The function that will be called when there is an alive GROUP in the GROUPSET. The function needs to accept a GROUP parameter.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em> ... </em></code>: </p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(GROUPSET)">#GROUPSET</a>:</em>
|
||||
self</p>
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(GROUPSET).IsIncludeObject" >
|
||||
<strong>GROUPSET:IsIncludeObject(MooseGroup)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
|
||||
|
||||
<h3>Parameter</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Group.html##(GROUP)">Group#GROUP</a> MooseGroup </em></code>: </p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(GROUPSET)">#GROUPSET</a>:</em>
|
||||
self</p>
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(GROUPSET).New" >
|
||||
<strong>GROUPSET:New()</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Creates a new GROUPSET object, building a set of groups belonging to a coalitions, categories, countries, types or with defined prefix names.</p>
|
||||
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(GROUPSET)">#GROUPSET</a>:</em></p>
|
||||
|
||||
|
||||
<h3>Usage:</h3>
|
||||
<pre class="example"><code>-- Define a new GROUPSET Object. This DBObject will contain a reference to all alive GROUPS.
|
||||
DBObject = GROUPSET:New()</code></pre>
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
@ -71,16 +71,28 @@
|
||||
<div id="content">
|
||||
<h1>Module <code>Message</code></h1>
|
||||
|
||||
<p>Message System to display Messages for Clients and Coalitions or All.</p>
|
||||
<p>This module contains the MESSAGE class.</p>
|
||||
|
||||
|
||||
<p>Messages are grouped on the display panel per Category to improve readability for the players.
|
||||
|
||||
<h1>1) <a href="Message.html##(MESSAGE)">Message#MESSAGE</a> class, extends <a href="Base.html##(BASE)">Base#BASE</a></h1>
|
||||
<p>Message System to display Messages to Clients, Coalitions or All.
|
||||
Messages are shown on the display panel for an amount of seconds, and will then disappear.
|
||||
Messages are identified by an ID. The messages with the same ID belonging to the same category will be overwritten if they were still being displayed on the display panel.
|
||||
Messages are created with MESSAGE:<a href="New.html">New</a>().
|
||||
Messages are sent to Clients with MESSAGE:<a href="ToClient.html">ToClient</a>().
|
||||
Messages are sent to Coalitions with MESSAGE:<a href="ToCoalition.html">ToCoalition</a>().
|
||||
Messages are sent to All Players with MESSAGE:<a href="ToAll.html">ToAll</a>().</p>
|
||||
Messages can contain a category which is indicating the category of the message.</p>
|
||||
|
||||
<h2>1.1) MESSAGE construction methods</h2>
|
||||
<p>Messages are created with <a href="Message.html##(MESSAGE).New">Message#MESSAGE.New</a>. Note that when the MESSAGE object is created, no message is sent yet.
|
||||
To send messages, you need to use the To functions.</p>
|
||||
|
||||
<h2>1.2) Send messages with MESSAGE To methods</h2>
|
||||
<p>Messages are sent to:</p>
|
||||
|
||||
<ul>
|
||||
<li>Clients with <a href="Message.html##(MESSAGE).ToClient">Message#MESSAGE.ToClient</a>.</li>
|
||||
<li>Coalitions with <a href="Message.html##(MESSAGE).ToCoalition">Message#MESSAGE.ToCoalition</a>.</li>
|
||||
<li>All Players with <a href="Message.html##(MESSAGE).ToAll">Message#MESSAGE.ToAll</a>.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<h2>Global(s)</h2>
|
||||
<table class="function_list">
|
||||
@ -88,12 +100,6 @@ Messages are sent to All Players with MESSAGE:<a href="ToAll.html">ToAll</a>().<
|
||||
<td class="name" nowrap="nowrap"><a href="#MESSAGE">MESSAGE</a></td>
|
||||
<td class="summary">
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="#MESSAGEQUEUE">MESSAGEQUEUE</a></td>
|
||||
<td class="summary">
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
@ -118,7 +124,7 @@ Messages are sent to All Players with MESSAGE:<a href="ToAll.html">ToAll</a>().<
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(MESSAGE).New">MESSAGE:New(MessageText, MessageCategory, MessageDuration, MessageID)</a></td>
|
||||
<td class="name" nowrap="nowrap"><a href="##(MESSAGE).New">MESSAGE:New(MessageText, MessageDuration, MessageCategory)</a></td>
|
||||
<td class="summary">
|
||||
<p>Creates a new MESSAGE object.</p>
|
||||
</td>
|
||||
@ -151,34 +157,6 @@ Messages are sent to All Players with MESSAGE:<a href="ToAll.html">ToAll</a>().<
|
||||
<td class="name" nowrap="nowrap"><a href="##(MESSAGE).ToRed">MESSAGE:ToRed()</a></td>
|
||||
<td class="summary">
|
||||
<p>Sends a MESSAGE to the Red Coalition. </p>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<h2><a id="#(MESSAGEQUEUE)">Type <code>MESSAGEQUEUE</code></a></h2>
|
||||
<table class="function_list">
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(MESSAGEQUEUE).ClientGroups">MESSAGEQUEUE.ClientGroups</a></td>
|
||||
<td class="summary">
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(MESSAGEQUEUE).CoalitionSides">MESSAGEQUEUE.CoalitionSides</a></td>
|
||||
<td class="summary">
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(MESSAGEQUEUE).New">MESSAGEQUEUE:New(RefreshInterval)</a></td>
|
||||
<td class="summary">
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(MESSAGEQUEUE)._DisplayMessages">MESSAGEQUEUE:_DisplayMessages()</a></td>
|
||||
<td class="summary">
|
||||
<p>This function is called automatically by the MESSAGEQUEUE scheduler.</p>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
@ -196,20 +174,6 @@ Messages are sent to All Players with MESSAGE:<a href="ToAll.html">ToAll</a>().<
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<em><a href="##(MESSAGEQUEUE)">#MESSAGEQUEUE</a></em>
|
||||
<a id="MESSAGEQUEUE" >
|
||||
<strong>MESSAGEQUEUE</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<h2><a id="#(Message)" >Type <code>Message</code></a></h2>
|
||||
@ -265,7 +229,7 @@ Messages are sent to All Players with MESSAGE:<a href="ToAll.html">ToAll</a>().<
|
||||
<dt>
|
||||
|
||||
<a id="#(MESSAGE).New" >
|
||||
<strong>MESSAGE:New(MessageText, MessageCategory, MessageDuration, MessageID)</strong>
|
||||
<strong>MESSAGE:New(MessageText, MessageDuration, MessageCategory)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
@ -285,20 +249,14 @@ is the text of the Message.</p>
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string MessageCategory </em></code>:
|
||||
is a string expressing the Category of the Message. Messages are grouped on the display panel per Category to improve readability.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em>#number MessageDuration </em></code>:
|
||||
is a number in seconds of how long the MESSAGE should be shown on the display panel.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string MessageID </em></code>:
|
||||
is a string expressing the ID of the Message.</p>
|
||||
<p><code><em>#string MessageCategory </em></code>:
|
||||
(optional) is a string expressing the "category" of the Message. The category will be shown as the first text in the message followed by a ": ".</p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
@ -313,10 +271,10 @@ is a string expressing the ID of the Message.</p>
|
||||
-- MessageRED is meant to be sent to the RED players only, for 10 seconds, and is classified as "End of Mission", with ID "Win".
|
||||
-- MessageClient1 is meant to be sent to a Client, for 25 seconds, and is classified as "Score", with ID "Score".
|
||||
-- MessageClient1 is meant to be sent to a Client, for 25 seconds, and is classified as "Score", with ID "Score".
|
||||
MessageAll = MESSAGE:New( "To all Players: BLUE has won! Each player of BLUE wins 50 points!", "End of Mission", 25, "Win" )
|
||||
MessageRED = MESSAGE:New( "To the RED Players: You receive a penalty because you've killed one of your own units", "Penalty", 25, "Score" )
|
||||
MessageClient1 = MESSAGE:New( "Congratulations, you've just hit a target", "Score", 25, "Score" )
|
||||
MessageClient2 = MESSAGE:New( "Congratulations, you've just killed a target", "Score", 25, "Score" )</code></pre>
|
||||
MessageAll = MESSAGE:New( "To all Players: BLUE has won! Each player of BLUE wins 50 points!", 25, "End of Mission" )
|
||||
MessageRED = MESSAGE:New( "To the RED Players: You receive a penalty because you've killed one of your own units", 25, "Penalty" )
|
||||
MessageClient1 = MESSAGE:New( "Congratulations, you've just hit a target", 25, "Score" )
|
||||
MessageClient2 = MESSAGE:New( "Congratulations, you've just killed a target", 25, "Score")</code></pre>
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
@ -481,74 +439,6 @@ or
|
||||
MessageRED = MESSAGE:New( "To the RED Players: You receive a penalty because you've killed one of your own units", "Penalty", 25, "Score" )
|
||||
MessageRED:ToRed()</code></pre>
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
|
||||
<h2><a id="#(MESSAGEQUEUE)" >Type <code>MESSAGEQUEUE</code></a></h2>
|
||||
|
||||
<p>The MESSAGEQUEUE class</p>
|
||||
|
||||
<h3>Field(s)</h3>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<em></em>
|
||||
<a id="#(MESSAGEQUEUE).ClientGroups" >
|
||||
<strong>MESSAGEQUEUE.ClientGroups</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<em></em>
|
||||
<a id="#(MESSAGEQUEUE).CoalitionSides" >
|
||||
<strong>MESSAGEQUEUE.CoalitionSides</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(MESSAGEQUEUE).New" >
|
||||
<strong>MESSAGEQUEUE:New(RefreshInterval)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
|
||||
|
||||
<h3>Parameter</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em> RefreshInterval </em></code>: </p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(MESSAGEQUEUE)._DisplayMessages" >
|
||||
<strong>MESSAGEQUEUE:_DisplayMessages()</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>This function is called automatically by the MESSAGEQUEUE scheduler.</p>
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
|
||||
|
||||
@ -777,8 +777,8 @@ The index of the group to return.</p>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="Group.html##(GROUP)">Group#GROUP</a>:</em></p>
|
||||
|
||||
<p><em><a href="Group.html##(GROUP)">Group#GROUP</a>:</em>
|
||||
self</p>
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
|
||||
@ -1,685 +0,0 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html>
|
||||
<head>
|
||||
<link rel="stylesheet" href="stylesheet.css" type="text/css"/>
|
||||
</head>
|
||||
<body>
|
||||
<div id="container">
|
||||
<div id="product">
|
||||
<div id="product_logo"></div>
|
||||
<div id="product_name"><big><b></b></big></div>
|
||||
<div id="product_description"></div>
|
||||
</div>
|
||||
<div id="main">
|
||||
<div id="navigation">
|
||||
<h2>Modules</h2>
|
||||
<ul><li>
|
||||
<a href="index.html">index</a>
|
||||
</li></ul>
|
||||
<ul>
|
||||
<li><a href="Airbase.html">Airbase</a></li>
|
||||
<li><a href="Base.html">Base</a></li>
|
||||
<li><a href="CARGO.html">CARGO</a></li>
|
||||
<li><a href="CleanUp.html">CleanUp</a></li>
|
||||
<li><a href="Client.html">Client</a></li>
|
||||
<li><a href="DCSAirbase.html">DCSAirbase</a></li>
|
||||
<li><a href="DCSCoalitionObject.html">DCSCoalitionObject</a></li>
|
||||
<li><a href="DCSCommand.html">DCSCommand</a></li>
|
||||
<li><a href="DCSController.html">DCSController</a></li>
|
||||
<li><a href="DCSGroup.html">DCSGroup</a></li>
|
||||
<li><a href="DCSObject.html">DCSObject</a></li>
|
||||
<li><a href="DCSTask.html">DCSTask</a></li>
|
||||
<li><a href="DCSTypes.html">DCSTypes</a></li>
|
||||
<li><a href="DCSUnit.html">DCSUnit</a></li>
|
||||
<li><a href="DCSWorld.html">DCSWorld</a></li>
|
||||
<li><a href="DCStimer.html">DCStimer</a></li>
|
||||
<li><a href="DEPLOYTASK.html">DEPLOYTASK</a></li>
|
||||
<li><a href="DESTROYBASETASK.html">DESTROYBASETASK</a></li>
|
||||
<li><a href="DESTROYGROUPSTASK.html">DESTROYGROUPSTASK</a></li>
|
||||
<li><a href="DESTROYRADARSTASK.html">DESTROYRADARSTASK</a></li>
|
||||
<li><a href="DESTROYUNITTYPESTASK.html">DESTROYUNITTYPESTASK</a></li>
|
||||
<li><a href="Database.html">Database</a></li>
|
||||
<li><a href="Escort.html">Escort</a></li>
|
||||
<li><a href="Event.html">Event</a></li>
|
||||
<li><a href="GOHOMETASK.html">GOHOMETASK</a></li>
|
||||
<li><a href="Group.html">Group</a></li>
|
||||
<li><a href="GroupSet.html">GroupSet</a></li>
|
||||
<li><a href="MOVEMENT.html">MOVEMENT</a></li>
|
||||
<li><a href="Menu.html">Menu</a></li>
|
||||
<li><a href="Message.html">Message</a></li>
|
||||
<li><a href="MissileTrainer.html">MissileTrainer</a></li>
|
||||
<li><a href="Mission.html">Mission</a></li>
|
||||
<li><a href="NOTASK.html">NOTASK</a></li>
|
||||
<li><a href="PICKUPTASK.html">PICKUPTASK</a></li>
|
||||
<li><a href="Point.html">Point</a></li>
|
||||
<li><a href="ROUTETASK.html">ROUTETASK</a></li>
|
||||
<li><a href="STAGE.html">STAGE</a></li>
|
||||
<li><a href="Scheduler.html">Scheduler</a></li>
|
||||
<li><a href="Scoring.html">Scoring</a></li>
|
||||
<li><a href="Sead.html">Sead</a></li>
|
||||
<li><a href="Set.html">Set</a></li>
|
||||
<li><a href="Spawn.html">Spawn</a></li>
|
||||
<li><a href="Static.html">Static</a></li>
|
||||
<li><a href="StaticObject.html">StaticObject</a></li>
|
||||
<li><a href="TASK.html">TASK</a></li>
|
||||
<li><a href="Unit.html">Unit</a></li>
|
||||
<li>UnitSet</li>
|
||||
<li><a href="Zone.html">Zone</a></li>
|
||||
<li><a href="env.html">env</a></li>
|
||||
<li><a href="land.html">land</a></li>
|
||||
<li><a href="routines.html">routines</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
<div id="content">
|
||||
<h1>Module <code>UnitSet</code></h1>
|
||||
|
||||
<p>Create and manage a set of units.</p>
|
||||
|
||||
|
||||
|
||||
<h1><a href="##(UNITSET)">#UNITSET</a> class</h1>
|
||||
<p>Mission designers can use the UNITSET class to build sets of units belonging to certain:</p>
|
||||
|
||||
<ul>
|
||||
<li>Coalitions</li>
|
||||
<li>Categories</li>
|
||||
<li>Countries</li>
|
||||
<li>Unit types</li>
|
||||
<li>Starting with certain prefix strings.</li>
|
||||
</ul>
|
||||
|
||||
<h1>UNITSET construction methods:</h1>
|
||||
<p>Create a new UNITSET object with the <a href="##(UNITSET).New">UNITSET.New</a> method:</p>
|
||||
|
||||
<ul>
|
||||
<li><a href="##(UNITSET).New">UNITSET.New</a>: Creates a new UNITSET object.</li>
|
||||
</ul>
|
||||
|
||||
|
||||
<h1>UNITSET filter criteria: </h1>
|
||||
<p>You can set filter criteria to define the set of units within the UNITSET.
|
||||
Filter criteria are defined by:</p>
|
||||
|
||||
<ul>
|
||||
<li><a href="##(UNITSET).FilterCoalitions">UNITSET.FilterCoalitions</a>: Builds the UNITSET with the units belonging to the coalition(s).</li>
|
||||
<li><a href="##(UNITSET).FilterCategories">UNITSET.FilterCategories</a>: Builds the UNITSET with the units belonging to the category(ies).</li>
|
||||
<li><a href="##(UNITSET).FilterTypes">UNITSET.FilterTypes</a>: Builds the UNITSET with the units belonging to the unit type(s).</li>
|
||||
<li><a href="##(UNITSET).FilterCountries">UNITSET.FilterCountries</a>: Builds the UNITSET with the units belonging to the country(ies).</li>
|
||||
<li><a href="##(UNITSET).FilterPrefixes">UNITSET.FilterPrefixes</a>: Builds the UNITSET with the units starting with the same prefix string(s).</li>
|
||||
</ul>
|
||||
|
||||
<p>Once the filter criteria have been set for the UNITSET, you can start filtering using:</p>
|
||||
|
||||
<ul>
|
||||
<li><a href="##(UNITSET).FilterStart">UNITSET.FilterStart</a>: Starts the filtering of the units within the UNITSET.</li>
|
||||
</ul>
|
||||
|
||||
<p>Planned filter criteria within development are (so these are not yet available):</p>
|
||||
|
||||
<ul>
|
||||
<li><a href="##(UNITSET).FilterZones">UNITSET.FilterZones</a>: Builds the UNITSET with the units within a <a href="Zone.html##(ZONE)">Zone#ZONE</a>.</li>
|
||||
</ul>
|
||||
|
||||
|
||||
<h1>UNITSET iterators:</h1>
|
||||
<p>Once the filters have been defined and the UNITSET has been built, you can iterate the UNITSET with the available iterator methods.
|
||||
The iterator methods will walk the UNITSET set, and call for each element within the set a function that you provide.
|
||||
The following iterator methods are currently available within the UNITSET:</p>
|
||||
|
||||
<ul>
|
||||
<li><a href="##(UNITSET).ForEachUnit">UNITSET.ForEachUnit</a>: Calls a function for each alive unit it finds within the UNITSET.</li>
|
||||
</ul>
|
||||
|
||||
<p>Planned iterators methods in development are (so these are not yet available):</p>
|
||||
|
||||
<ul>
|
||||
<li><a href="##(UNITSET).ForEachUnitInGroup">UNITSET.ForEachUnitInGroup</a>: Calls a function for each group contained within the UNITSET.</li>
|
||||
<li><a href="##(UNITSET).ForEachUnitInZone">UNITSET.ForEachUnitInZone</a>: Calls a function for each unit within a certain zone contained within the UNITSET.</li>
|
||||
</ul>
|
||||
|
||||
|
||||
<h2>Global(s)</h2>
|
||||
<table class="function_list">
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="#UNITSET">UNITSET</a></td>
|
||||
<td class="summary">
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<h2><a id="#(UNITSET)">Type <code>UNITSET</code></a></h2>
|
||||
<table class="function_list">
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(UNITSET).AddInDatabase">UNITSET:AddInDatabase(Event)</a></td>
|
||||
<td class="summary">
|
||||
<p>Handles the Database to check on an event (birth) that the Object was added in the Database.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(UNITSET).ClassName">UNITSET.ClassName</a></td>
|
||||
<td class="summary">
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(UNITSET).Filter">UNITSET.Filter</a></td>
|
||||
<td class="summary">
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(UNITSET).FilterCategories">UNITSET:FilterCategories(Categories)</a></td>
|
||||
<td class="summary">
|
||||
<p>Builds a set of units out of categories.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(UNITSET).FilterCoalitions">UNITSET:FilterCoalitions(Coalitions)</a></td>
|
||||
<td class="summary">
|
||||
<p>Builds a set of units of coalitions.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(UNITSET).FilterCountries">UNITSET:FilterCountries(Countries)</a></td>
|
||||
<td class="summary">
|
||||
<p>Builds a set of units of defined countries.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(UNITSET).FilterMeta">UNITSET.FilterMeta</a></td>
|
||||
<td class="summary">
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(UNITSET).FilterPrefixes">UNITSET:FilterPrefixes(Prefixes)</a></td>
|
||||
<td class="summary">
|
||||
<p>Builds a set of units of defined unit prefixes.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(UNITSET).FilterStart">UNITSET:FilterStart()</a></td>
|
||||
<td class="summary">
|
||||
<p>Starts the filtering.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(UNITSET).FilterTypes">UNITSET:FilterTypes(Types)</a></td>
|
||||
<td class="summary">
|
||||
<p>Builds a set of units of defined unit types.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(UNITSET).FindInDatabase">UNITSET:FindInDatabase(Event)</a></td>
|
||||
<td class="summary">
|
||||
<p>Handles the Database to check on any event that Object exists in the Database.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(UNITSET).FindUnit">UNITSET:FindUnit(UnitName)</a></td>
|
||||
<td class="summary">
|
||||
<p>Finds a Unit based on the Unit Name.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(UNITSET).ForEachUnit">UNITSET:ForEachUnit(IteratorFunction, ...)</a></td>
|
||||
<td class="summary">
|
||||
<p>Interate the UNITSET and call an interator function for each <strong>alive</strong> UNIT, providing the UNIT and optional parameters.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(UNITSET).IsIncludeObject">UNITSET:IsIncludeObject(MUnit)</a></td>
|
||||
<td class="summary">
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(UNITSET).New">UNITSET:New()</a></td>
|
||||
<td class="summary">
|
||||
<p>Creates a new UNITSET object, building a set of units belonging to a coalitions, categories, countries, types or with defined prefix names.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="##(UNITSET).Units">UNITSET.Units</a></td>
|
||||
<td class="summary">
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<h2>Global(s)</h2>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<em><a href="##(UNITSET)">#UNITSET</a></em>
|
||||
<a id="UNITSET" >
|
||||
<strong>UNITSET</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<h2><a id="#(UnitSet)" >Type <code>UnitSet</code></a></h2>
|
||||
|
||||
<h2><a id="#(UNITSET)" >Type <code>UNITSET</code></a></h2>
|
||||
|
||||
<p>UNITSET class</p>
|
||||
|
||||
<h3>Field(s)</h3>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(UNITSET).AddInDatabase" >
|
||||
<strong>UNITSET:AddInDatabase(Event)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Handles the Database to check on an event (birth) that the Object was added in the Database.</p>
|
||||
|
||||
|
||||
<p>This is required, because sometimes the _DATABASE birth event gets called later than the SET birth event!</p>
|
||||
|
||||
<h3>Parameter</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Event.html##(EVENTDATA)">Event#EVENTDATA</a> Event </em></code>: </p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return values</h3>
|
||||
<ol>
|
||||
<li>
|
||||
|
||||
<p><em>#string:</em>
|
||||
The name of the UNIT</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><em>#table:</em>
|
||||
The UNIT</p>
|
||||
|
||||
</li>
|
||||
</ol>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<em>#string</em>
|
||||
<a id="#(UNITSET).ClassName" >
|
||||
<strong>UNITSET.ClassName</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<em></em>
|
||||
<a id="#(UNITSET).Filter" >
|
||||
<strong>UNITSET.Filter</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(UNITSET).FilterCategories" >
|
||||
<strong>UNITSET:FilterCategories(Categories)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Builds a set of units out of categories.</p>
|
||||
|
||||
|
||||
<p>Possible current categories are plane, helicopter, ground, ship.</p>
|
||||
|
||||
<h3>Parameter</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string Categories </em></code>:
|
||||
Can take the following values: "plane", "helicopter", "ground", "ship".</p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(UNITSET)">#UNITSET</a>:</em>
|
||||
self</p>
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(UNITSET).FilterCoalitions" >
|
||||
<strong>UNITSET:FilterCoalitions(Coalitions)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Builds a set of units of coalitions.</p>
|
||||
|
||||
|
||||
<p>Possible current coalitions are red, blue and neutral.</p>
|
||||
|
||||
<h3>Parameter</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string Coalitions </em></code>:
|
||||
Can take the following values: "red", "blue", "neutral".</p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(UNITSET)">#UNITSET</a>:</em>
|
||||
self</p>
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(UNITSET).FilterCountries" >
|
||||
<strong>UNITSET:FilterCountries(Countries)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Builds a set of units of defined countries.</p>
|
||||
|
||||
|
||||
<p>Possible current countries are those known within DCS world.</p>
|
||||
|
||||
<h3>Parameter</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string Countries </em></code>:
|
||||
Can take those country strings known within DCS world.</p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(UNITSET)">#UNITSET</a>:</em>
|
||||
self</p>
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<em></em>
|
||||
<a id="#(UNITSET).FilterMeta" >
|
||||
<strong>UNITSET.FilterMeta</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(UNITSET).FilterPrefixes" >
|
||||
<strong>UNITSET:FilterPrefixes(Prefixes)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Builds a set of units of defined unit prefixes.</p>
|
||||
|
||||
|
||||
<p>All the units starting with the given prefixes will be included within the set.</p>
|
||||
|
||||
<h3>Parameter</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string Prefixes </em></code>:
|
||||
The prefix of which the unit name starts with.</p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(UNITSET)">#UNITSET</a>:</em>
|
||||
self</p>
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(UNITSET).FilterStart" >
|
||||
<strong>UNITSET:FilterStart()</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Starts the filtering.</p>
|
||||
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(UNITSET)">#UNITSET</a>:</em>
|
||||
self</p>
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(UNITSET).FilterTypes" >
|
||||
<strong>UNITSET:FilterTypes(Types)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Builds a set of units of defined unit types.</p>
|
||||
|
||||
|
||||
<p>Possible current types are those types known within DCS world.</p>
|
||||
|
||||
<h3>Parameter</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string Types </em></code>:
|
||||
Can take those type strings known within DCS world.</p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(UNITSET)">#UNITSET</a>:</em>
|
||||
self</p>
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(UNITSET).FindInDatabase" >
|
||||
<strong>UNITSET:FindInDatabase(Event)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Handles the Database to check on any event that Object exists in the Database.</p>
|
||||
|
||||
|
||||
<p>This is required, because sometimes the _DATABASE event gets called later than the SET event or vise versa!</p>
|
||||
|
||||
<h3>Parameter</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Event.html##(EVENTDATA)">Event#EVENTDATA</a> Event </em></code>: </p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return values</h3>
|
||||
<ol>
|
||||
<li>
|
||||
|
||||
<p><em>#string:</em>
|
||||
The name of the UNIT</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><em>#table:</em>
|
||||
The UNIT</p>
|
||||
|
||||
</li>
|
||||
</ol>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(UNITSET).FindUnit" >
|
||||
<strong>UNITSET:FindUnit(UnitName)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Finds a Unit based on the Unit Name.</p>
|
||||
|
||||
<h3>Parameter</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em>#string UnitName </em></code>: </p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="Unit.html##(UNIT)">Unit#UNIT</a>:</em>
|
||||
The found Unit.</p>
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(UNITSET).ForEachUnit" >
|
||||
<strong>UNITSET:ForEachUnit(IteratorFunction, ...)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Interate the UNITSET and call an interator function for each <strong>alive</strong> UNIT, providing the UNIT and optional parameters.</p>
|
||||
|
||||
<h3>Parameters</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em>#function IteratorFunction </em></code>:
|
||||
The function that will be called when there is an alive UNIT in the UNITSET. The function needs to accept a UNIT parameter.</p>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
|
||||
<p><code><em> ... </em></code>: </p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(UNITSET)">#UNITSET</a>:</em>
|
||||
self</p>
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(UNITSET).IsIncludeObject" >
|
||||
<strong>UNITSET:IsIncludeObject(MUnit)</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
|
||||
|
||||
<h3>Parameter</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
<p><code><em><a href="Unit.html##(UNIT)">Unit#UNIT</a> MUnit </em></code>: </p>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(UNITSET)">#UNITSET</a>:</em>
|
||||
self</p>
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<a id="#(UNITSET).New" >
|
||||
<strong>UNITSET:New()</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Creates a new UNITSET object, building a set of units belonging to a coalitions, categories, countries, types or with defined prefix names.</p>
|
||||
|
||||
<h3>Return value</h3>
|
||||
|
||||
<p><em><a href="##(UNITSET)">#UNITSET</a>:</em></p>
|
||||
|
||||
|
||||
<h3>Usage:</h3>
|
||||
<pre class="example"><code>-- Define a new UNITSET Object. This DBObject will contain a reference to all alive Units.
|
||||
DBObject = UNITSET:New()</code></pre>
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="function">
|
||||
<dt>
|
||||
|
||||
<em></em>
|
||||
<a id="#(UNITSET).Units" >
|
||||
<strong>UNITSET.Units</strong>
|
||||
</a>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
@ -249,7 +249,7 @@
|
||||
<tr>
|
||||
<td class="name" nowrap="nowrap"><a href="Message.html">Message</a></td>
|
||||
<td class="summary">
|
||||
<p>Message System to display Messages for Clients and Coalitions or All.</p>
|
||||
<p>This module contains the MESSAGE class.</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
1035
Moose Training/Stylesheet/stylesheet.css
Normal file
1035
Moose Training/Stylesheet/stylesheet.css
Normal file
File diff suppressed because it is too large
Load Diff
Loading…
x
Reference in New Issue
Block a user