refactor: cleaning
This commit is contained in:
@@ -17,7 +17,6 @@ ItemsController.Player = {}
|
|||||||
---@return number
|
---@return number
|
||||||
---@private
|
---@private
|
||||||
function ItemsController.Player.GetAmputationTexturesIndex(playerObj, isCicatrized)
|
function ItemsController.Player.GetAmputationTexturesIndex(playerObj, isCicatrized)
|
||||||
-- FIX Broken
|
|
||||||
local textureString = playerObj:getHumanVisual():getSkinTexture()
|
local textureString = playerObj:getHumanVisual():getSkinTexture()
|
||||||
local isHairy = textureString:sub(-1) == "a"
|
local isHairy = textureString:sub(-1) == "a"
|
||||||
|
|
||||||
|
|||||||
@@ -143,26 +143,6 @@ function ISHealthPanel:render()
|
|||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
-- local og_ISHealthPanel_update = ISHealthPanel.update
|
|
||||||
-- function ISHealthPanel:update()
|
|
||||||
-- og_ISHealthPanel_update(self)
|
|
||||||
-- -- TODO Listen for changes on other player side instead of looping this
|
|
||||||
|
|
||||||
|
|
||||||
-- -- FIX Re-enable it, just for test
|
|
||||||
-- if self.character then
|
|
||||||
-- local locPlUsername = getPlayer():getUsername()
|
|
||||||
-- local remPlUsername = self.character:getUsername()
|
|
||||||
-- if locPlUsername ~= remPlUsername and self:isReallyVisible() then
|
|
||||||
-- -- Request update for TOC DATA
|
|
||||||
-- local key = CommandsData.GetKey(remPlUsername)
|
|
||||||
-- --ModData.request(key)
|
|
||||||
-- end
|
|
||||||
-- end
|
|
||||||
-- end
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
-- We need to override this to force the alpha to 1
|
-- We need to override this to force the alpha to 1
|
||||||
local og_ISCharacterInfoWindow_render = ISCharacterInfoWindow.prerender
|
local og_ISCharacterInfoWindow_render = ISCharacterInfoWindow.prerender
|
||||||
function ISCharacterInfoWindow:prerender()
|
function ISCharacterInfoWindow:prerender()
|
||||||
|
|||||||
@@ -33,7 +33,8 @@ function BaseHandler:checkItems()
|
|||||||
local containers = ISInventoryPaneContextMenu.getContainers(self:getDoctor())
|
local containers = ISInventoryPaneContextMenu.getContainers(self:getDoctor())
|
||||||
local done = {}
|
local done = {}
|
||||||
local childContainers = {}
|
local childContainers = {}
|
||||||
for i=1,containers:size() do
|
if containers ~= nil then
|
||||||
|
for i=1, containers:size() do
|
||||||
local container = containers:get(i-1)
|
local container = containers:get(i-1)
|
||||||
done[container] = true
|
done[container] = true
|
||||||
table.wipe(childContainers)
|
table.wipe(childContainers)
|
||||||
@@ -45,6 +46,7 @@ function BaseHandler:checkItems()
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
function BaseHandler:checkContainerItems(container, childContainers)
|
function BaseHandler:checkContainerItems(container, childContainers)
|
||||||
@@ -101,7 +103,7 @@ function BaseHandler:getItemOfTag(items, type)
|
|||||||
end
|
end
|
||||||
|
|
||||||
function BaseHandler:getAllItemsOfType(items, type)
|
function BaseHandler:getAllItemsOfType(items, type)
|
||||||
local items = {}
|
items = {}
|
||||||
for _,item in ipairs(items) do
|
for _,item in ipairs(items) do
|
||||||
if item:getFullType() == type then
|
if item:getFullType() == type then
|
||||||
table.insert(items, item)
|
table.insert(items, item)
|
||||||
|
|||||||
@@ -13,10 +13,12 @@ end
|
|||||||
---Print debug
|
---Print debug
|
||||||
---@param string string
|
---@param string string
|
||||||
function TOC_DEBUG.print(string)
|
function TOC_DEBUG.print(string)
|
||||||
--if isDebugEnabled() then
|
if isDebugEnabled() then
|
||||||
local runningFile = TOC_DEBUG.getRunningFile()
|
local runningFile = TOC_DEBUG.getRunningFile()
|
||||||
print("[TOC]" .. "[" .. runningFile .. "] " .. tostring(string))
|
print("[TOC]" .. "[" .. runningFile .. "] " .. tostring(string))
|
||||||
--end
|
else
|
||||||
|
print(string)
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
---Horrendous but I don't really care about performance for this
|
---Horrendous but I don't really care about performance for this
|
||||||
|
|||||||
Reference in New Issue
Block a user