• 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
m
no edit summary
Line 192: Line 192:  
     for suffix, data in pairs(ship_data) do
 
     for suffix, data in pairs(ship_data) do
 
         if data._seasonal == true and data._name and data._suffix then
 
         if data._seasonal == true and data._name and data._suffix then
             table.insert(seasonal_forms, { name = data._name .. "/" .. data._suffix, seasonal = true })
+
            local normal = data._cg ~= false
 +
            local damaged = data._cg_damaged ~= false
 +
             table.insert(seasonal_forms, { name = data._name .. "/" .. data._suffix, seasonal = true, normal = normal, damaged = damaged })
 
         end
 
         end
 
     end
 
     end
Line 222: Line 224:  
     local result = { "{{#tag:tabber|" }
 
     local result = { "{{#tag:tabber|" }
 
     for _, form in ipairs(forms) do
 
     for _, form in ipairs(forms) do
         if form.seasonal then
+
         if form.normal or form.damaged then
            local name, suffix = Ship:process_ship_key(form.name)
  −
            local image = ShipGraphicKai:Asset({ form.name, link = "nil", size = "300px" })
  −
            local image_damaged = ShipGraphicKai:Asset({ form.name, link = "nil", damaged = true, size = "300px" })
  −
            table.insert(result, "{{!}}-{{!}}" .. suffix .. "=")
  −
            table.insert(result, format{
  −
                ShipPage._gallery_tabber,
  −
                image = image,
  −
                image_damaged = image_damaged
  −
            })
  −
        elseif form.normal or form.damaged then
   
             local name, suffix = Ship:process_ship_key(form.name)
 
             local name, suffix = Ship:process_ship_key(form.name)
 
             suffix = suffix or ""
 
             suffix = suffix or ""
             table.insert(result, "{{!}}-{{!}}" .. (suffix == "" and form.name or suffix) .. "=")
+
            local title = form.seasonal and suffix or suffix == "" and form.name or suffix
 +
             table.insert(result, "{{!}}-{{!}}" .. title .. "=")
 
             if form.normal and form.damaged then
 
             if form.normal and form.damaged then
 
                 local image = ShipGraphicKai:Asset({ form.name, link = "nil", size = "300px" })
 
                 local image = ShipGraphicKai:Asset({ form.name, link = "nil", size = "300px" })
Line 263: Line 256:  
end
 
end
   −
--[[
   
function ShipPage.TestGalleryTabber(ship)
 
function ShipPage.TestGalleryTabber(ship)
 
     return ShipPage.GalleryTabber(nil, {
 
     return ShipPage.GalleryTabber(nil, {
Line 274: Line 266:  
-- print(p.TestGalleryTabber("Iowa"))
 
-- print(p.TestGalleryTabber("Iowa"))
 
-- print(p.TestGalleryTabber("Kasuga Maru"))
 
-- print(p.TestGalleryTabber("Kasuga Maru"))
]]--
+
-- print(p.TestGalleryTabber("Murakumo"))
    
function ShipPage.FooterSections(frame, args)
 
function ShipPage.FooterSections(frame, args)
cssedit, gkautomate
7,064

edits

Navigation menu