- Welcome to the Kancolle Wiki!
- If you have any questions regarding site content, account registration, etc., please visit the KanColle Wiki Discord
Difference between revisions of "Module:ShipBattleCardListKai"
Jump to navigation
Jump to search
com>Ckwng |
m (4 revisions imported) |
||
(2 intermediate revisions by one other user not shown) | |||
Line 1: | Line 1: | ||
local Formatting = require('Module:Formatting') | local Formatting = require('Module:Formatting') | ||
− | local | + | local ShipBattleCardKai = require('Module:ShipBattleCardKai') |
local ShipCardListKai = require('Module:ShipCardListKai') | local ShipCardListKai = require('Module:ShipCardListKai') | ||
local ShipBattleCardListKai = ShipCardListKai{ | local ShipBattleCardListKai = ShipCardListKai{ | ||
− | _default_size = | + | _default_size = ShipBattleCardKai._battle_card_size, |
− | _blank = " | + | _blank = "Empty ship battle card slot.png", |
} | } | ||
Line 13: | Line 13: | ||
value = Formatting:format_image{self._blank, size = self._size} | value = Formatting:format_image{self._blank, size = self._size} | ||
else | else | ||
− | value = | + | value = ShipBattleCardKai:get{ship = ship, size = self._size, link = ship:link(), caption = ship:name()} |
end | end | ||
return {values = {value = value}, bg_color = self._transparent, text_align = self._center_align} | return {values = {value = value}, bg_color = self._transparent, text_align = self._center_align} |
Latest revision as of 12:29, 12 May 2021
Documentation for this module may be created at Module:ShipBattleCardListKai/doc
local Formatting = require('Module:Formatting')
local ShipBattleCardKai = require('Module:ShipBattleCardKai')
local ShipCardListKai = require('Module:ShipCardListKai')
local ShipBattleCardListKai = ShipCardListKai{
_default_size = ShipBattleCardKai._battle_card_size,
_blank = "Empty ship battle card slot.png",
}
function ShipBattleCardListKai:card(ship)
local value
if ship == false then
value = Formatting:format_image{self._blank, size = self._size}
else
value = ShipBattleCardKai:get{ship = ship, size = self._size, link = ship:link(), caption = ship:name()}
end
return {values = {value = value}, bg_color = self._transparent, text_align = self._center_align}
end
return ShipBattleCardListKai