mirror of
https://github.com/FlightControl-Master/MOOSE.git
synced 2025-10-29 16:58:06 +00:00
Reworking cargo
This commit is contained in:
@@ -90,17 +90,20 @@ function AI_CARGO_APC:New( APC, CargoSet, CombatRadius )
|
||||
self.CargoSet = CargoSet -- Core.Set#SET_CARGO
|
||||
self.CombatRadius = CombatRadius
|
||||
|
||||
self:SetStartState( "Unloaded" )
|
||||
self:SetStartState( "Unloaded" )
|
||||
|
||||
self:AddTransition( "Unloaded", "Pickup", "*" )
|
||||
self:AddTransition( "Loaded", "Deploy", "*" )
|
||||
|
||||
self:AddTransition( "*", "Load", "Boarding" )
|
||||
self:AddTransition( { "Boarding", "Loaded" }, "Board", "Boarding" )
|
||||
self:AddTransition( "Boarding", "Loaded", "Loaded" )
|
||||
self:AddTransition( "Boarding", "Loaded", "Boarding" )
|
||||
self:AddTransition( "Boarding", "PickedUp", "Loaded" )
|
||||
|
||||
self:AddTransition( "Loaded", "Unload", "Unboarding" )
|
||||
self:AddTransition( "Unboarding", "Unboard", "Unboarding" )
|
||||
self:AddTransition( { "Unboarding", "Unloaded" }, "Unloaded", "Unloaded" )
|
||||
self:AddTransition( "Unboarding", "Unloaded", "Unboarding" )
|
||||
self:AddTransition( "Unboarding", "Deployed", "Unloaded" )
|
||||
|
||||
self:AddTransition( "*", "Monitor", "*" )
|
||||
self:AddTransition( "*", "Follow", "Following" )
|
||||
@@ -369,13 +372,13 @@ function AI_CARGO_APC:onafterMonitor( APC, From, Event, To )
|
||||
else
|
||||
if self:Is( "Loaded" ) then
|
||||
-- There are enemies within combat range. Unload the CargoCarrier.
|
||||
self:__Unload( 1, false )
|
||||
self:__Unload( 1 )
|
||||
else
|
||||
if self:Is( "Unloaded" ) then
|
||||
self:Follow()
|
||||
end
|
||||
if self:Is( "Following" ) then
|
||||
for APCUnit, Cargo in pairs( self.APC_Cargo ) do
|
||||
for Cargo, APCUnit in pairs( self.APC_Cargo ) do
|
||||
local Cargo = Cargo -- Cargo.Cargo#CARGO
|
||||
if Cargo:IsAlive() then
|
||||
if not Cargo:IsNear( APCUnit, 40 ) then
|
||||
@@ -411,11 +414,17 @@ end
|
||||
-- @param #string From From state.
|
||||
-- @param #string Event Event.
|
||||
-- @param #string To To state.
|
||||
function AI_CARGO_APC:onbeforeLoad( APC, From, Event, To )
|
||||
-- @param Core.Zone#ZONE PickupZone (optional) The zone where the cargo will be picked up. The PickupZone can be nil, if there wasn't any PickupZoneSet provided.
|
||||
function AI_CARGO_APC:onbeforeLoad( APC, From, Event, To, PickupZone )
|
||||
self:F( { APC, From, Event, To } )
|
||||
|
||||
local Boarding = false
|
||||
|
||||
local LoadInterval = 10
|
||||
local LoadDelay = 10
|
||||
local APC_List = {}
|
||||
local APC_Weight = {}
|
||||
|
||||
if APC and APC:IsAlive() then
|
||||
self.APC_Cargo = {}
|
||||
for _, APCUnit in pairs( APC:GetUnits() ) do
|
||||
@@ -424,32 +433,65 @@ function AI_CARGO_APC:onbeforeLoad( APC, From, Event, To )
|
||||
local CargoBayFreeWeight = APCUnit:GetCargoBayFreeWeight()
|
||||
self:F({CargoBayFreeWeight=CargoBayFreeWeight})
|
||||
|
||||
--for _, Cargo in pairs( self.CargoSet:GetSet() ) do
|
||||
for _, Cargo in UTILS.spairs( self.CargoSet:GetSet(), function( t, a, b ) return t[a]:GetWeight() > t[b]:GetWeight() end ) do
|
||||
local Cargo = Cargo -- Cargo.Cargo#CARGO
|
||||
self:F( { IsUnLoaded = Cargo:IsUnLoaded(), IsDeployed = Cargo:IsDeployed(), Cargo:GetName(), APC:GetName() } )
|
||||
APC_List[#APC_List+1] = APCUnit
|
||||
APC_Weight[APCUnit] = CargoBayFreeWeight
|
||||
end
|
||||
|
||||
local APC_Count = #APC_List
|
||||
local APC_Index = 1
|
||||
|
||||
for _, Cargo in UTILS.spairs( self.CargoSet:GetSet(), function( t, a, b ) return t[a]:GetWeight() > t[b]:GetWeight() end ) do
|
||||
local Cargo = Cargo -- Cargo.Cargo#CARGO
|
||||
|
||||
self:F( { IsUnLoaded = Cargo:IsUnLoaded(), IsDeployed = Cargo:IsDeployed(), Cargo:GetName(), APC:GetName() } )
|
||||
|
||||
local Loaded = false
|
||||
|
||||
-- Try all APCs, but start from the one according the APC_Index
|
||||
for APC_Loop = 1, #APC_List do
|
||||
|
||||
local APCUnit = APC_List[APC_Index] -- Wrapper.Unit#UNIT
|
||||
|
||||
-- This counters loop through the available APCs.
|
||||
APC_Index = APC_Index + 1
|
||||
if APC_Index > APC_Count then
|
||||
APC_Index = 1
|
||||
end
|
||||
|
||||
if Cargo:IsUnLoaded() then -- and not Cargo:IsDeployed() then
|
||||
if Cargo:IsInLoadRadius( APCUnit:GetCoordinate() ) then
|
||||
self:F( { "In radius", APCUnit:GetName() } )
|
||||
|
||||
local CargoWeight = Cargo:GetWeight()
|
||||
|
||||
|
||||
-- Only when there is space within the bay to load the next cargo item!
|
||||
if CargoBayFreeWeight > CargoWeight then --and CargoBayFreeVolume > CargoVolume then
|
||||
if APC_Weight[APCUnit] > CargoWeight then --and CargoBayFreeVolume > CargoVolume then
|
||||
APC:RouteStop()
|
||||
--Cargo:Ungroup()
|
||||
Cargo:Board( APCUnit, 25 )
|
||||
self:__Board( 1, Cargo, APCUnit )
|
||||
Cargo:__Board( LoadDelay, APCUnit, 25 )
|
||||
LoadDelay = LoadDelay + LoadInterval
|
||||
self:__Board( LoadDelay, Cargo, APCUnit, PickupZone )
|
||||
|
||||
-- So now this APCUnit has Cargo that is being loaded.
|
||||
-- This will be used further in the logic to follow and to check cargo status.
|
||||
self.APC_Cargo[APCUnit] = Cargo
|
||||
self.APC_Cargo[Cargo] = APCUnit
|
||||
Boarding = true
|
||||
APC_Weight[APCUnit] = APC_Weight[APCUnit] - CargoWeight
|
||||
Loaded = true
|
||||
|
||||
-- Ok, we loaded a cargo, now we can stop the loop.
|
||||
break
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
if not Loaded then
|
||||
-- If the cargo wasn't loaded in one of the carriers, then we need to stop the loading.
|
||||
break
|
||||
end
|
||||
|
||||
end
|
||||
end
|
||||
|
||||
@@ -465,54 +507,37 @@ end
|
||||
-- @param #string To To state.
|
||||
-- @param Cargo.Cargo#CARGO Cargo Cargo object.
|
||||
-- @param Wrapper.Unit#UNIT APCUnit
|
||||
function AI_CARGO_APC:onafterBoard( APC, From, Event, To, Cargo, APCUnit )
|
||||
-- @param Core.Zone#ZONE PickupZone (optional) The zone where the cargo will be picked up. The PickupZone can be nil, if there wasn't any PickupZoneSet provided.
|
||||
function AI_CARGO_APC:onafterBoard( APC, From, Event, To, Cargo, APCUnit, PickupZone )
|
||||
self:F( { APC, From, Event, To, Cargo, APCUnit:GetName() } )
|
||||
|
||||
if APC and APC:IsAlive() then
|
||||
self:F({ IsLoaded = Cargo:IsLoaded(), Cargo:GetName(), APC:GetName() } )
|
||||
if not Cargo:IsLoaded() then
|
||||
self:__Board( 10, Cargo, APCUnit )
|
||||
else
|
||||
local CargoBayFreeWeight = APCUnit:GetCargoBayFreeWeight()
|
||||
self:F({CargoBayFreeWeight=CargoBayFreeWeight})
|
||||
for _, Cargo in UTILS.spairs( self.CargoSet:GetSet(), function( t, a, b ) return t[a]:GetWeight() > t[b]:GetWeight() end ) do
|
||||
local Cargo = Cargo -- Cargo.Cargo#CARGO
|
||||
if Cargo:IsUnLoaded() then
|
||||
if Cargo:IsInLoadRadius( APCUnit:GetCoordinate() ) then
|
||||
local CargoWeight = Cargo:GetWeight()
|
||||
|
||||
-- Only when there is space within the bay to load the next cargo item!
|
||||
if CargoBayFreeWeight > CargoWeight then --and CargoBayFreeVolume > CargoVolume then
|
||||
Cargo:Board( APCUnit, 25 )
|
||||
self:__Board( 10, Cargo, APCUnit )
|
||||
-- So now this APCUnit has Cargo that is being loaded.
|
||||
-- This will be used further in the logic to follow and to check cargo status.
|
||||
self.APC_Cargo[APCUnit] = Cargo
|
||||
return
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
self:__Loaded( 5, Cargo )
|
||||
self:__Board( 10, Cargo, APCUnit, PickupZone )
|
||||
return
|
||||
end
|
||||
end
|
||||
|
||||
self:__Loaded( 10, Cargo, APCUnit, PickupZone )
|
||||
|
||||
end
|
||||
|
||||
--- On before Loaded event.
|
||||
--- On after Loaded event.
|
||||
-- @param #AI_CARGO_APC self
|
||||
-- @param Wrapper.Group#GROUP APC
|
||||
-- @param #string From From state.
|
||||
-- @param #string Event Event.
|
||||
-- @param #string To To state.
|
||||
-- @return #boolean Cargo loaded.
|
||||
function AI_CARGO_APC:onbeforeLoaded( APC, From, Event, To, Cargo )
|
||||
-- @param Core.Zone#ZONE PickupZone (optional) The zone where the cargo will be picked up. The PickupZone can be nil, if there wasn't any PickupZoneSet provided.
|
||||
function AI_CARGO_APC:onafterLoaded( APC, From, Event, To, Cargo, PickupZone )
|
||||
self:F( { APC, From, Event, To } )
|
||||
|
||||
local Loaded = true
|
||||
|
||||
if APC and APC:IsAlive() then
|
||||
for APCUnit, Cargo in pairs( self.APC_Cargo ) do
|
||||
for Cargo, APCUnit in pairs( self.APC_Cargo ) do
|
||||
local Cargo = Cargo -- Cargo.Cargo#CARGO
|
||||
self:F( { IsLoaded = Cargo:IsLoaded(), IsDestroyed = Cargo:IsDestroyed(), Cargo:GetName(), APC:GetName() } )
|
||||
if not Cargo:IsLoaded() and not Cargo:IsDestroyed() then
|
||||
@@ -521,14 +546,26 @@ function AI_CARGO_APC:onbeforeLoaded( APC, From, Event, To, Cargo )
|
||||
end
|
||||
end
|
||||
|
||||
if Loaded == true then
|
||||
APC:RouteResume()
|
||||
if Loaded then
|
||||
self:PickedUp( PickupZone )
|
||||
end
|
||||
|
||||
return Loaded
|
||||
|
||||
end
|
||||
|
||||
--- On after PickedUp event.
|
||||
-- @param #AI_CARGO_APC self
|
||||
-- @param Wrapper.Group#GROUP APC
|
||||
-- @param #string From From state.
|
||||
-- @param #string Event Event.
|
||||
-- @param #string To To state.
|
||||
-- @param Core.Zone#ZONE PickupZone (optional) The zone where the cargo will be picked up. The PickupZone can be nil, if there wasn't any PickupZoneSet provided.
|
||||
function AI_CARGO_APC:onafterPickedUp( APC, From, Event, To, PickupZone )
|
||||
self:F( { APC, From, Event, To } )
|
||||
|
||||
self.Transporting = true
|
||||
APC:RouteResume()
|
||||
|
||||
end
|
||||
|
||||
|
||||
|
||||
@@ -539,9 +576,12 @@ end
|
||||
-- @param #string From From state.
|
||||
-- @param #string Event Event.
|
||||
-- @param #string To To state.
|
||||
-- @param #boolean Deployed Cargo is deployed.
|
||||
function AI_CARGO_APC:onafterUnload( APC, From, Event, To, Deployed )
|
||||
self:F( { APC, From, Event, To, Deployed } )
|
||||
-- @param Core.Zone#ZONE DeployZone The zone wherein the cargo is deployed. This can be any zone type, like a ZONE, ZONE_GROUP, ZONE_AIRBASE.
|
||||
function AI_CARGO_APC:onafterUnload( APC, From, Event, To, DeployZone )
|
||||
self:F( { APC, From, Event, To, DeployZone } )
|
||||
|
||||
local UnboardInterval = 10
|
||||
local UnboardDelay = 10
|
||||
|
||||
if APC and APC:IsAlive() then
|
||||
for _, APCUnit in pairs( APC:GetUnits() ) do
|
||||
@@ -549,9 +589,10 @@ function AI_CARGO_APC:onafterUnload( APC, From, Event, To, Deployed )
|
||||
APC:RouteStop()
|
||||
for _, Cargo in pairs( APCUnit:GetCargo() ) do
|
||||
if Cargo:IsLoaded() then
|
||||
Cargo:UnBoard()
|
||||
Cargo:__UnBoard( UnboardDelay )
|
||||
UnboardDelay = UnboardDelay + UnboardInterval
|
||||
Cargo:SetDeployed( true )
|
||||
self:__Unboard( 10, Cargo, Deployed )
|
||||
self:__Unboard( UnboardDelay, Cargo, APCUnit, DeployZone )
|
||||
end
|
||||
end
|
||||
end
|
||||
@@ -566,32 +607,22 @@ end
|
||||
-- @param #string Event Event.
|
||||
-- @param #string To To state.
|
||||
-- @param #string Cargo.Cargo#CARGO Cargo Cargo object.
|
||||
-- @param #boolean Deployed Cargo is deployed.
|
||||
function AI_CARGO_APC:onafterUnboard( APC, From, Event, To, Cargo, Deployed )
|
||||
-- @param Core.Zone#ZONE DeployZone The zone wherein the cargo is deployed. This can be any zone type, like a ZONE, ZONE_GROUP, ZONE_AIRBASE.
|
||||
function AI_CARGO_APC:onafterUnboard( APC, From, Event, To, Cargo, APCUnit, DeployZone )
|
||||
self:F( { APC, From, Event, To, Cargo:GetName() } )
|
||||
|
||||
if APC and APC:IsAlive() then
|
||||
if not Cargo:IsUnLoaded() then
|
||||
self:__Unboard( 10, Cargo, Deployed )
|
||||
else
|
||||
for _, APCUnit in pairs( APC:GetUnits() ) do
|
||||
local APCUnit = APCUnit -- Wrapper.Unit#UNIT
|
||||
for _, Cargo in pairs( APCUnit:GetCargo() ) do
|
||||
if Cargo:IsLoaded() then
|
||||
Cargo:UnBoard()
|
||||
Cargo:SetDeployed( true )
|
||||
self:__Unboard( 10, Cargo, Deployed )
|
||||
return
|
||||
end
|
||||
end
|
||||
end
|
||||
self:__Unloaded( 1, Cargo, Deployed )
|
||||
self:__Unboard( 10, Cargo, APCUnit, DeployZone )
|
||||
return
|
||||
end
|
||||
end
|
||||
|
||||
self:Unloaded( Cargo, APCUnit, DeployZone )
|
||||
|
||||
end
|
||||
|
||||
--- On before Unloaded event.
|
||||
--- On after Unloaded event.
|
||||
-- @param #AI_CARGO_APC self
|
||||
-- @param Wrapper.Group#GROUP APC
|
||||
-- @param #string From From state.
|
||||
@@ -599,9 +630,9 @@ end
|
||||
-- @param #string To To state.
|
||||
-- @param #string Cargo.Cargo#CARGO Cargo Cargo object.
|
||||
-- @param #boolean Deployed Cargo is deployed.
|
||||
-- @return #boolean All cargo unloaded.
|
||||
function AI_CARGO_APC:onbeforeUnloaded( APC, From, Event, To, Cargo, Deployed )
|
||||
self:F( { APC, From, Event, To, Cargo:GetName(), Deployed = Deployed } )
|
||||
-- @param Core.Zone#ZONE DeployZone The zone wherein the cargo is deployed. This can be any zone type, like a ZONE, ZONE_GROUP, ZONE_AIRBASE.
|
||||
function AI_CARGO_APC:onafterUnloaded( APC, From, Event, To, Cargo, APCUnit, DeployZone )
|
||||
self:F( { APC, From, Event, To, Cargo:GetName(), DeployZone = DeployZone } )
|
||||
|
||||
local AllUnloaded = true
|
||||
|
||||
@@ -619,32 +650,31 @@ function AI_CARGO_APC:onbeforeUnloaded( APC, From, Event, To, Cargo, Deployed )
|
||||
end
|
||||
|
||||
if AllUnloaded == true then
|
||||
if Deployed == true then
|
||||
if DeployZone == true then
|
||||
self.APC_Cargo = {}
|
||||
end
|
||||
self:Guard()
|
||||
self.CargoCarrier = APC
|
||||
end
|
||||
end
|
||||
|
||||
self:F( { AllUnloaded = AllUnloaded } )
|
||||
return AllUnloaded
|
||||
|
||||
if AllUnloaded == true then
|
||||
self:Deployed( DeployZone )
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
--- On after Unloaded event.
|
||||
--- On after Deployed event.
|
||||
-- @param #AI_CARGO_APC self
|
||||
-- @param Wrapper.Group#GROUP APC
|
||||
-- @param #string From From state.
|
||||
-- @param #string Event Event.
|
||||
-- @param #string To To state.
|
||||
-- @param #string Cargo.Cargo#CARGO Cargo Cargo object.
|
||||
-- @param #boolean Deployed Cargo is deployed.
|
||||
-- @return #boolean All cargo unloaded.
|
||||
function AI_CARGO_APC:onafterUnloaded( APC, From, Event, To, Cargo, Deployed )
|
||||
self:F( { APC, From, Event, To, Cargo:GetName(), Deployed = Deployed } )
|
||||
-- @param Core.Zone#ZONE DeployZone The zone wherein the cargo is deployed. This can be any zone type, like a ZONE, ZONE_GROUP, ZONE_AIRBASE.
|
||||
function AI_CARGO_APC:onafterDeployed( APC, From, Event, To, DeployZone )
|
||||
self:F( { APC, From, Event, To, DeployZone = DeployZone } )
|
||||
|
||||
self.Transporting = false
|
||||
self:__Guard( 0.1 )
|
||||
|
||||
end
|
||||
|
||||
@@ -659,7 +689,7 @@ function AI_CARGO_APC:onafterFollow( APC, From, Event, To )
|
||||
|
||||
self:F( "Follow" )
|
||||
if APC and APC:IsAlive() then
|
||||
for APCUnit, Cargo in pairs( self.APC_Cargo ) do
|
||||
for Cargo, APCUnit in pairs( self.APC_Cargo ) do
|
||||
local Cargo = Cargo -- Cargo.Cargo#CARGO
|
||||
if Cargo:IsUnLoaded() then
|
||||
self:FollowToCarrier( self, APCUnit, Cargo )
|
||||
@@ -673,26 +703,22 @@ end
|
||||
|
||||
--- @param #AI_CARGO_APC
|
||||
-- @param Wrapper.Group#GROUP APC
|
||||
function AI_CARGO_APC._Pickup( APC, self )
|
||||
function AI_CARGO_APC._Pickup( APC, self, PickupZone )
|
||||
|
||||
APC:F( { "AI_CARGO_APC._Pickup:", APC:GetName() } )
|
||||
|
||||
if APC:IsAlive() then
|
||||
self:Load()
|
||||
self.Relocating = true
|
||||
self:Load( PickupZone)
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
--- @param #AI_CARGO_APC
|
||||
-- @param Wrapper.Group#GROUP APC
|
||||
function AI_CARGO_APC._Deploy( APC, self )
|
||||
function AI_CARGO_APC._Deploy( APC, self, Coordinate, DeployZone )
|
||||
|
||||
APC:F( { "AI_CARGO_APC._Deploy:", APC } )
|
||||
|
||||
if APC:IsAlive() then
|
||||
self:Unload( true )
|
||||
self.Relocating = false
|
||||
self:Unload( DeployZone )
|
||||
end
|
||||
end
|
||||
|
||||
@@ -706,7 +732,8 @@ end
|
||||
-- @param To
|
||||
-- @param Core.Point#COORDINATE Coordinate of the pickup point.
|
||||
-- @param #number Speed Speed in km/h to drive to the pickup coordinate. Default is 50% of max possible speed the unit can go.
|
||||
function AI_CARGO_APC:onafterPickup( APC, From, Event, To, Coordinate, Speed )
|
||||
-- @param Core.Zone#ZONE PickupZone (optional) The zone where the cargo will be picked up. The PickupZone can be nil, if there wasn't any PickupZoneSet provided.
|
||||
function AI_CARGO_APC:onafterPickup( APC, From, Event, To, Coordinate, Speed, PickupZone )
|
||||
|
||||
if APC and APC:IsAlive() then
|
||||
|
||||
@@ -717,7 +744,7 @@ function AI_CARGO_APC:onafterPickup( APC, From, Event, To, Coordinate, Speed )
|
||||
|
||||
local Waypoints = APC:TaskGroundOnRoad( Coordinate, _speed, "Line abreast", true )
|
||||
|
||||
local TaskFunction = APC:TaskFunction( "AI_CARGO_APC._Pickup", self )
|
||||
local TaskFunction = APC:TaskFunction( "AI_CARGO_APC._Pickup", self, PickupZone )
|
||||
|
||||
self:F({Waypoints = Waypoints})
|
||||
local Waypoint = Waypoints[#Waypoints]
|
||||
@@ -725,10 +752,11 @@ function AI_CARGO_APC:onafterPickup( APC, From, Event, To, Coordinate, Speed )
|
||||
|
||||
APC:Route( Waypoints, 1 ) -- Move after a random seconds to the Route. See the Route method for details.
|
||||
else
|
||||
AI_CARGO_APC._Pickup( APC, self )
|
||||
AI_CARGO_APC._Pickup( APC, self, PickupZone )
|
||||
end
|
||||
|
||||
self.Transporting = true
|
||||
|
||||
self.Relocating = true
|
||||
self.Transporting = false
|
||||
end
|
||||
|
||||
end
|
||||
@@ -742,7 +770,7 @@ end
|
||||
-- @param To
|
||||
-- @param Core.Point#COORDINATE Coordinate Deploy place.
|
||||
-- @param #number Speed Speed in km/h to drive to the depoly coordinate. Default is 50% of max possible speed the unit can go.
|
||||
function AI_CARGO_APC:onafterDeploy( APC, From, Event, To, Coordinate, Speed )
|
||||
function AI_CARGO_APC:onafterDeploy( APC, From, Event, To, Coordinate, Speed, DeployZone )
|
||||
|
||||
if APC and APC:IsAlive() then
|
||||
|
||||
@@ -752,13 +780,16 @@ function AI_CARGO_APC:onafterDeploy( APC, From, Event, To, Coordinate, Speed )
|
||||
|
||||
local Waypoints = APC:TaskGroundOnRoad( Coordinate, _speed, "Line abreast", true )
|
||||
|
||||
local TaskFunction = APC:TaskFunction( "AI_CARGO_APC._Deploy", self )
|
||||
local TaskFunction = APC:TaskFunction( "AI_CARGO_APC._Deploy", self, Coordinate, DeployZone )
|
||||
|
||||
self:F({Waypoints = Waypoints})
|
||||
local Waypoint = Waypoints[#Waypoints]
|
||||
APC:SetTaskWaypoint( Waypoint, TaskFunction ) -- Set for the given Route at Waypoint 2 the TaskRouteToZone.
|
||||
|
||||
APC:Route( Waypoints, 1 ) -- Move after a random seconds to the Route. See the Route method for details.
|
||||
|
||||
self.Relocating = false
|
||||
self.Transporting = true
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user