Progress, a lot is working already.

This commit is contained in:
FlightControl
2017-02-28 14:01:38 +01:00
parent e0254308d3
commit 8edbb5ca23
65 changed files with 1672 additions and 65421 deletions

View File

@@ -182,6 +182,20 @@ function MESSAGE:ToCoalition( CoalitionSide )
return self
end
--- Sends a MESSAGE to a Coalition if the given Condition is true.
-- @param #MESSAGE self
-- @param CoalitionSide needs to be filled out by the defined structure of the standard scripting engine @{coalition.side}.
-- @return #MESSAGE
function MESSAGE:ToCoalitionIf( CoalitionSide, Condition )
self:F( CoalitionSide )
if CoalitionSide then
self:ToCoalition( CoalitionSide )
end
return self
end
--- Sends a MESSAGE to all players.
-- @param #MESSAGE self
-- @return #MESSAGE
@@ -194,10 +208,24 @@ end
-- MessageAll = MESSAGE:New( "To all Players: BLUE has won! Each player of BLUE wins 50 points!", "End of Mission", 25, "Win" )
-- MessageAll:ToAll()
function MESSAGE:ToAll()
self:F()
self:F()
self:ToCoalition( coalition.side.RED )
self:ToCoalition( coalition.side.BLUE )
self:ToCoalition( coalition.side.RED )
self:ToCoalition( coalition.side.BLUE )
return self
end
--- Sends a MESSAGE to all players if the given Condition is true.
-- @param #MESSAGE self
-- @return #MESSAGE
function MESSAGE:ToAllIf( Condition )
if Condition then
self:ToCoalition( coalition.side.RED )
self:ToCoalition( coalition.side.BLUE )
end
return self
end