diff --git a/classes/CheckDefenses.php b/classes/CheckDefenses.php
index 3e22c180b..bf9556dce 100644
--- a/classes/CheckDefenses.php
+++ b/classes/CheckDefenses.php
@@ -26,8 +26,10 @@
class CheckDefenses
{
- public static function sectorFighters(\PDO $pdo_db, string $lang, int $sector, string $calledfrom, int $energyscooped): void
+ public static function sectorFighters(\PDO $pdo_db, string $lang, int $sector, string $calledfrom, int $energyscooped, array $playerinfo, Reg $tkireg, string $title): void
{
+ $total_sec_fighters = 0;
+
$langvars = \Tki\Translate::load($pdo_db, $lang, array('sector_fighters', 'common', 'global_includes', 'global_funcs', 'footer', 'news'));
echo $langvars['l_sf_attacking'] . "
";
$targetfighters = $total_sec_fighters;
@@ -125,7 +127,7 @@ public static function sectorFighters(\PDO $pdo_db, string $lang, int $sector, s
}
else
{
- $langvars['l_sf_lostfight2'] = str_replace("[lost]", (string) $targetfighters, $langvars['l_sf_lostfight2']);
+ $langvars['l_sf_lostfight2'] = str_replace("[lost]", $targetfighters, $langvars['l_sf_lostfight2']);
echo $langvars['l_sf_lostfight2'] . "
";
$tempplayfighters = $playerfighters - $targetfighters;
}
@@ -144,7 +146,7 @@ public static function sectorFighters(\PDO $pdo_db, string $lang, int $sector, s
else
{
$playerarmor = $playerarmor - $targetfighters;
- $langvars['l_sf_armorbreach2'] = str_replace("[lost]", (string) $targetfighters, $langvars['l_sf_armorbreach2']);
+ $langvars['l_sf_armorbreach2'] = str_replace("[lost]", $targetfighters, $langvars['l_sf_armorbreach2']);
echo $langvars['l_sf_armorbreach2'] . "
";
}
}
@@ -234,7 +236,7 @@ public static function sectorFighters(\PDO $pdo_db, string $lang, int $sector, s
}
}
- public static function fighters(\PDO $pdo_db, $db, string $lang, int $sector): void
+ public static function fighters(\PDO $pdo_db, $db, string $lang, int $sector, $playerinfo, $tkireg, $title, $calledfrom): void
{
// Database driven language entries
$langvars = \Tki\Translate::load($pdo_db, $lang, array('check_defenses', 'common', 'global_includes', 'global_funcs', 'combat', 'footer', 'news', 'regional'));
@@ -305,7 +307,7 @@ public static function fighters(\PDO $pdo_db, $db, string $lang, int $sector): v
$resx = $db->Execute("UPDATE {$db->prefix}ships SET cleared_defenses = ' ' WHERE ship_id = ?;", array($playerinfo['ship_id']));
\Tki\Db::logDbErrors($pdo_db, $resx, __LINE__, __FILE__);
echo "