mirror of
https://github.com/FlightControl-Master/MOOSE.git
synced 2025-10-29 16:58:06 +00:00
OPS
UNIT and POSITIONABLE - Removed pcall for GetVec3 and GetAmmo CHIEF - Deploy resources if zone is empty and owned by itself
This commit is contained in:
@@ -239,18 +239,19 @@ end
|
||||
function POSITIONABLE:GetVec3()
|
||||
local DCSPositionable = self:GetDCSObject()
|
||||
if DCSPositionable then
|
||||
local status, vec3 = pcall(
|
||||
function()
|
||||
local vec3 = DCSPositionable:getPoint()
|
||||
return vec3
|
||||
end
|
||||
)
|
||||
--local vec3 = DCSPositionable:getPoint()
|
||||
if status then
|
||||
return vec3
|
||||
else
|
||||
self:E( { "Cannot get Vec3 from DCS Object", Positionable = self, Alive = self:IsAlive() } )
|
||||
end
|
||||
-- local status, vec3 = pcall(
|
||||
-- function()
|
||||
-- local vec3 = DCSPositionable:getPoint()
|
||||
-- return vec3
|
||||
-- end
|
||||
-- )
|
||||
local vec3 = DCSPositionable:getPoint()
|
||||
return vec3
|
||||
-- if status then
|
||||
-- return vec3
|
||||
-- else
|
||||
-- self:E( { "Cannot get Vec3 from DCS Object", Positionable = self, Alive = self:IsAlive() } )
|
||||
-- end
|
||||
end
|
||||
-- ERROR!
|
||||
self:E( { "Cannot get the Positionable DCS Object for GetVec3", Positionable = self, Alive = self:IsAlive() } )
|
||||
|
||||
Reference in New Issue
Block a user