Skip to content

Commit

Permalink
Fix for getCategory
Browse files Browse the repository at this point in the history
- Fix for DCS API change to getCategory()
  • Loading branch information
Penecruz committed Nov 18, 2023
1 parent e91b906 commit 71a0ca5
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions lua/DCS-gRPC/methods/mission.lua
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ local function exporter(object)
return nil
end

local category = object:getCategory()
local category = Object.getCategory(object) -- change for DCS API fixes in getcategory()

if category == Object.Category.BASE or object.className_ == 'Airbase' then
-- carriers are of category unit, but are a Airbase class
Expand Down Expand Up @@ -35,7 +35,7 @@ local function typed_exporter(object)
end

local grpcTable = {}
local category = object:getCategory()
local category = Object.getCategory(object)

if category == Object.Category.BASE or object.className_ == 'Airbase' then
grpcTable.airbase = exporter(object)
Expand Down
2 changes: 1 addition & 1 deletion lua/DCS-gRPC/methods/unit.lua
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ GRPC.methods.getRadar = function(params)
})
end

local category = object:getCategory()
local category = Object.getCategory(object)-- change for DCS API fixes in getcategory()
local grpcTable = {}

if(category == Object.Category.UNIT) then
Expand Down

0 comments on commit 71a0ca5

Please sign in to comment.