- 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
Line 141:
Line 141:
− +
+
+
− +
+
+
+
+
+
+
+
+
+
+
+
+
Line 485:
Line 499:
− +
Line 579:
Line 593:
− +
automatic installation and night bombing
or ship_type == 14
or ship_type == 14
end
end
-- Automatically make units with 0 speed installations
-- todo: the effect of type 3 shell
function ShipCapabilities:_is_installation(ship)
function ShipCapabilities:_is_installation(ship)
if not ship then
if not ship then
ship = self._ship
ship = self._ship
end
end
return ship:is_installation()
return ship:speed() == 0 and not ship:is_pillbox()
end
-- The logic is copied from Kan Colle Kai
-- Automatically make most of enemy carriers night bombing
-- _night_bombing is now used to disable night bombing caused by firepower and torpedo, and not related to night ASW
function ShipCapabilities:_is_night_bombing(ship)
if not ship then
ship = self._ship
end
return ship:night_bombing() ~= false
and self:_is_carrier(ship)
and (ship:firepower() or 0) + (ship:torpedo() or 0) > 0
end
end
end
end
if self:_is_carrier() then
if self:_is_carrier() then
if has_planes and self._ship:night_bombing() then
if has_planes and self:_is_night_bombing() then
return 8, firepower + torpedo
return 8, firepower + torpedo
end
end
elseif self:_is_asw_aviation_ship() then
elseif self:_is_asw_aviation_ship() then
base_asw = 8
base_asw = 8
if not self._ship:night_bombing() or self._ship:asw_leveled() == 0 then
if not self:_is_night_bombing() or self._ship:asw_leveled() == 0 then
night = false
night = false
end
end