• 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
373 bytes removed ,  4 years ago
m
no edit summary
Line 1: Line 1:  
local U = require("Module:Core")
 
local U = require("Module:Core")
local format = require("Module:Core").format
+
local format = U.format
 
local Formatting = require("Module:Formatting")
 
local Formatting = require("Module:Formatting")
 
local Equipment = require("Module:Equipment")
 
local Equipment = require("Module:Equipment")
Line 8: Line 8:  
local ShipCardKai = require("Module:ShipCardKai")
 
local ShipCardKai = require("Module:ShipCardKai")
 
local ShipBattleCardKai = require("Module:ShipBattleCardKai")
 
local ShipBattleCardKai = require("Module:ShipBattleCardKai")
local Combat = require("Module:CalcCombat")
+
local Combat2 = require("Module:Combat2")
 
local EquipmentCardKai = require("Module:EquipmentCardKai")
 
local EquipmentCardKai = require("Module:EquipmentCardKai")
 
local EquipmentGraphicKai = require("Module:EquipmentGraphicKai")
 
local EquipmentGraphicKai = require("Module:EquipmentGraphicKai")
Line 97: Line 97:  
     air_power = function(ship)
 
     air_power = function(ship)
 
         return ship:air_power() or -1
 
         return ship:air_power() or -1
    end,
  −
   
  −
    equipment_range = function(ship)
  −
        return U.imax(U.imap(ship._equipment or {}, function (e) return Equipment(e.equipment):range() or 0 end), 0)
  −
    end,
  −
   
  −
    equipment_range_diff = function(ship)
  −
        local equipment_range = U.imax(U.imap(ship._equipment or {}, function (e) return Equipment(e.equipment):range() or 0 end), 0)
  −
        return (ship:range() or 0) - equipment_range
   
     end,
 
     end,
   Line 250: Line 241:     
     hit_rate = function(ship, target)
 
     hit_rate = function(ship, target)
         local r = Combat.hit_rate(ship, target)
+
         local r = Combat2.hit_rate(ship, target)
 
         if r then
 
         if r then
 
             ship.hit_rate = r
 
             ship.hit_rate = r
Line 260: Line 251:     
     critical_hit_rate = function(ship, target)
 
     critical_hit_rate = function(ship, target)
         local r = Combat.critical_hit_rate(ship, target)
+
         local r = Combat2.critical_hit_rate(ship, target)
 
         if r then
 
         if r then
 
             ship.critical_hit_rate = r
 
             ship.critical_hit_rate = r
Line 312: Line 303:  
end
 
end
   −
addFormattingFunctions("FitData", require("Module:CalcFit"))
+
local Plugins = require("Module:Calc/Plugins")
addFormattingFunctions("Assets", require("Module:CalcAsset"))
+
 
 +
for _, name in ipairs(Plugins) do
 +
    local data = require("Module:Calc/Plugins/" .. name)
 +
    addFormattingFunctions(name, data)
 +
end
    
function format_value(key, ship, target)
 
function format_value(key, ship, target)
cssedit, gkautomate
7,064

edits

Navigation menu