mirror of
https://github.com/FlightControl-Master/MOOSE.git
synced 2025-10-29 16:58:06 +00:00
Fixed key problem in TaskFunction()
This commit is contained in:
@@ -1592,7 +1592,7 @@ function CONTROLLABLE:TaskFunction( FunctionString, ... )
|
|||||||
DCSScript[#DCSScript+1] = "local MissionControllable = GROUP:Find( ... ) "
|
DCSScript[#DCSScript+1] = "local MissionControllable = GROUP:Find( ... ) "
|
||||||
|
|
||||||
if arg and arg.n > 0 then
|
if arg and arg.n > 0 then
|
||||||
local ArgumentKey = tostring( arg )
|
local ArgumentKey = tostring( arg ):match("table: (.*)")
|
||||||
self:SetState( self, ArgumentKey, arg )
|
self:SetState( self, ArgumentKey, arg )
|
||||||
DCSScript[#DCSScript+1] = "local Arguments = MissionControllable:GetState( MissionControllable, '" .. ArgumentKey .. "' ) "
|
DCSScript[#DCSScript+1] = "local Arguments = MissionControllable:GetState( MissionControllable, '" .. ArgumentKey .. "' ) "
|
||||||
DCSScript[#DCSScript+1] = "MissionControllable:ClearState( MissionControllable, '" .. ArgumentKey .. "' ) "
|
DCSScript[#DCSScript+1] = "MissionControllable:ClearState( MissionControllable, '" .. ArgumentKey .. "' ) "
|
||||||
|
|||||||
Reference in New Issue
Block a user