• Welcome to the Kancolle Wiki!
  • If you have any questions regarding site content, account registration, etc., please visit the KanColle Wiki Discord

Changes

Jump to navigation Jump to search
Fix more bugssss
Line 62: Line 62:  
if products then
 
if products then
 
if self._single_item then
 
if self._single_item then
self._title_row = format{[[|+ ${icon}{$name}]], icon = Formatting:format_image{Formatting:format_equipment_icon(item:icon())}, name = Formatting:format_link(item:link())}
+
self._title_row = format{[[|+ ${icon}${name}]], icon = Formatting:format_image{Formatting:format_equipment_icon(item:icon())}, name = Formatting:format_link(item:link())}
 
else
 
else
 
self._custom_rows[item:name()] = format{[[| colspan="12" style="text-align: center; padding:5px 5px 5px 5px;" | ${icon}${name}]], icon = Formatting:format_image{Formatting:format_equipment_icon(item:icon())}, name = Formatting:format_link(item:link())}
 
self._custom_rows[item:name()] = format{[[| colspan="12" style="text-align: center; padding:5px 5px 5px 5px;" | ${icon}${name}]], icon = Formatting:format_image{Formatting:format_equipment_icon(item:icon())}, name = Formatting:format_link(item:link())}
Line 90: Line 90:  
for equip, count in pairs(consumed_equipment_table) do
 
for equip, count in pairs(consumed_equipment_table) do
 
local equipment = equip ~= true and Equipment(equip) or row_data.item
 
local equipment = equip ~= true and Equipment(equip) or row_data.item
table.insert(consumed_equipment, format{self._equipment_item, count = count, icon = Formatting:format_equipment_icon_simple(equipment:icon()), name = Formatting:format_link(equipment:link())})
+
table.insert(consumed_equipment, format{self._equipment_item, count = count, icon = Formatting:format_image{Formatting:format_equipment_icon_simple(equipment:icon())}, name = Formatting:format_link(equipment:link())})
 
end
 
end
 
table.insert(result, format{self._consumed_equipment_label, list = table.concat(consumed_equipment, "<br />")})
 
table.insert(result, format{self._consumed_equipment_label, list = table.concat(consumed_equipment, "<br />")})
 
if row_data.stars == self._improvement_brackets[#self._improvement_brackets] and row_data.product then
 
if row_data.stars == self._improvement_brackets[#self._improvement_brackets] and row_data.product then
 
local product = Equipment(row_data.product)
 
local product = Equipment(row_data.product)
table.insert(result, format{self._produced_equipment_label, icon = Formatting:format_equipment_icon_simple(product:icon()), name = Formatting:format_link(product:link())})
+
table.insert(result, format{self._produced_equipment_label, icon = Formatting:format_image{Formatting:format_equipment_icon_simple(product:icon())}, name = Formatting:format_link(product:link())})
 
end
 
end
 
value = table.concat(result, "<br />")
 
value = table.concat(result, "<br />")
Line 107: Line 107:     
function ImprovementTableKai:development_material(row_data)
 
function ImprovementTableKai:development_material(row_data)
return {values = {value = format{self._material_cell_content, normal = row_data.resources.development_material, slider = row_data.resources_x.development_material}}, bg_color = self._transparent, text_align = self._center_align}
+
return {values = {value = format{self._material_cell_content, normal = row_data.resources.devmat, slider = row_data.resources_x.devmat}}, bg_color = self._transparent, text_align = self._center_align}
 
end
 
end
    
function ImprovementTableKai:improvement_material(row_data)
 
function ImprovementTableKai:improvement_material(row_data)
return {values = {value = format{self._material_cell_content, normal = row_data.resources.improvement_material, slider = row_data.resources_x.improvement_material}}, bg_color = self._transparent, text_align = self._center_align}
+
return {values = {value = format{self._material_cell_content, normal = row_data.resources.screw, slider = row_data.resources_x.screw}}, bg_color = self._transparent, text_align = self._center_align}
 
end
 
end
   Line 182: Line 182:  
self._rows = {self._table_start, self._title_row, self._header}
 
self._rows = {self._table_start, self._title_row, self._header}
 
else
 
else
self._rows = {self._table_start, self._header}
+
self._rows = {self._table_start}
 
end
 
end
 
end
 
end
Line 188: Line 188:  
function ImprovementTableKai:create_header()
 
function ImprovementTableKai:create_header()
 
local header_icons = {
 
local header_icons = {
fuel = ResourceIcons.fuel,
  −
ammo = ResourceIcons.ammo,
  −
steel = ResourceIcons.steel,
  −
bauxite = ResourceIcons.bauxite,
   
devmat = ResourceIcons.devmat,
 
devmat = ResourceIcons.devmat,
 
screw = ResourceIcons.screw,
 
screw = ResourceIcons.screw,
Line 198: Line 194:  
header_icons[key] = Formatting:format_image{value, caption = Formatting:format_stat_name(key)}
 
header_icons[key] = Formatting:format_image{value, caption = Formatting:format_stat_name(key)}
 
end
 
end
self._header = format{self._header_template, stat_columns = format{self._column_header_cell_template, value = self._stats_column_label}}
+
if self._single_item then
 +
header_icons.resources = Formatting:format_resources(self._items[1].item:improvement_resources())
 +
end
 +
self._header = format(self._header_template, header_icons)
 
end
 
end
    
return ImprovementTableKai
 
return ImprovementTableKai
Anonymous user

Navigation menu