And now we need only one thing to make an icons and number visible.
We had
Code: Select all
local L = {
egoCreatePropertyRow = nil,
}
Code: Select all
local L = {
egoCreateObjectList = nil,
egoCreatePropertyOwned = nil,
egoCreatePropertyRow = nil,
}
Code: Select all
local function init()
menu = Lib.Get_Egosoft_Menu("MapMenu")
if not menu then
DebugError("Thin columns - Could not find MapMenu, aborting UI modifications.")
return
end
-- Functions that creates the Property Owned table row
L.egoCreatePropertyRow = menu.createPropertyRow
menu.createPropertyRow = L.createPropertyRow
DebugError("Thin columns - MapMenu modifications applied.")
end
Code: Select all
local function init()
menu = Lib.Get_Egosoft_Menu("MapMenu")
if not menu then
DebugError("Thin columns - Could not find MapMenu, aborting UI modifications.")
return
end
-- Functions that creates the Object List table row
L.egoCreateObjectList = menu.createObjectList
menu.createObjectList = L.createObjectList
-- Functions that creates the Property Owned table
L.egoCreatePropertyOwned = menu.createPropertyOwned
menu.createPropertyOwned = L.createPropertyOwned
-- Functions that creates the Property Owned table row
L.egoCreatePropertyRow = menu.createPropertyRow
menu.createPropertyRow = L.createPropertyRow
DebugError("Thin columns - MapMenu modifications applied.")
end
Put in our file, and replace inside our file menu with L
I.e. to have
Code: Select all
--
-- place for code from map_menu.lua - begin
--
local config = {
...
}
function L.createObjectList(frame, instance)
...
end
function L.createPropertyOwned(frame, instance)
...
end
function L.createPropertyRow(instance, ftable, component, iteration, commanderlocation, showmodules, hidesubordinates, numdisplayed, sorter)
...
end
--
-- place for code from map_menu.lua - end
--
Code: Select all
for i = 1, maxicons do
ftable:setColWidth(5 + i - 1, infoTableData.shipIconWidth, false)
end
and last one - to find in both new function a code
Code: Select all
for i = 1, maxicons do
ftable:setColWidth(5 + i - 1, infoTableData.shipIconWidth * 2, false)
end

