• 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
Should be fine now with ShipData changes to prevent nil arithmetic...
Line 150: Line 150:     
function EliteShipsKai:asw(ship)
 
function EliteShipsKai:asw(ship)
local asw, asw_max = ship:asw(), ship:asw_max()
+
local asw_max = ship:asw_max()
return {values = {value = asw_max and Formatting:tooltip(Formatting:format_stat(asw_max), format{self._kekkon_max_template, value = Formatting:format_stat(ship:asw_leveled(155))}) or Formatting:format_stat(asw)}, bg_color = self:get_bg_color(self._cell_color.asw, asw_max, self._args.asw_operator, self._args.asw_outstanding, self._args.asw_good, self._args.asw_bad), text_align = self._center_align}
+
if asw_max == false then
 +
asw_max = ship:asw()
 +
end
 +
return {values = {value = Formatting:tooltip(Formatting:format_stat(asw_max), format{self._kekkon_max_template, value = Formatting:format_stat(ship:asw_leveled(155))})}, bg_color = self:get_bg_color(self._cell_color.asw, asw_max, self._args.asw_operator, self._args.asw_outstanding, self._args.asw_good, self._args.asw_bad), text_align = self._center_align}
 
end
 
end
  
Anonymous user

Navigation menu