We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.
@@ -105,7 +105,7 @@ discard block |
||
105 | 105 | foreach($gameGoods as $goodId => &$value) { |
106 | 106 | if ($goods[$goodId]===true) { |
107 | 107 | if ($sectors[$currentSectorId]->getPort()->getGoodTransaction($goodId) === self::GOOD_SELLS && |
108 | - $sectors[$targetSectorId]->getPort()->getGoodTransaction($goodId) === self::GOOD_BUYS) { |
|
108 | + $sectors[$targetSectorId]->getPort()->getGoodTransaction($goodId) === self::GOOD_BUYS) { |
|
109 | 109 | $rl[] = new OneWayRoute($currentSectorId, $targetSectorId, $races[$raceID], $sectors[$targetSectorId]->getPort()->getRaceID(), $sectors[$currentSectorId]->getPort()->getGoodDistance($goodId), $sectors[$targetSectorId]->getPort()->getGoodDistance($goodId), $distance, $goodId); |
110 | 110 | } |
111 | 111 | } |
@@ -132,7 +132,7 @@ discard block |
||
132 | 132 | foreach($gameGoods as $goodId => &$value) { |
133 | 133 | if ($goods[$goodId]===true) { |
134 | 134 | if ($sectors[$currentSectorId]->getPort()->getGoodTransaction($goodId) === self::GOOD_SELLS && |
135 | - $sectors[$targetSectorId]->getPort()->getGoodTransaction($goodId) === self::GOOD_BUYS) { |
|
135 | + $sectors[$targetSectorId]->getPort()->getGoodTransaction($goodId) === self::GOOD_BUYS) { |
|
136 | 136 | $owr = new OneWayRoute($currentSectorId, $targetSectorId, $sectors[$currentSectorId]->getPort()->getRaceID(), $sectors[$targetSectorId]->getPort()->getRaceID(), $sectors[$currentSectorId]->getPort()->getGoodDistance($goodId), $sectors[$targetSectorId]->getPort()->getGoodDistance($goodId), $distance, $goodId); |
137 | 137 | $fakeReturn = new OneWayRoute($targetSectorId, $currentSectorId, $sectors[$targetSectorId]->getPort()->getRaceID(), $sectors[$currentSectorId]->getPort()->getRaceID(), 0, 0, $distance, GOOD_NOTHING); |
138 | 138 | $mpr = new MultiplePortRoute($owr, $fakeReturn); |
@@ -6,6 +6,6 @@ |
||
6 | 6 | use SmrMySqlSecrets; |
7 | 7 | public function __construct() { |
8 | 8 | parent::__construct(self::$host, self::$user, self::$password, self::$databaseName, |
9 | - self::$port, self::$socket); |
|
9 | + self::$port, self::$socket); |
|
10 | 10 | } |
11 | 11 | } |
@@ -24,7 +24,7 @@ |
||
24 | 24 | // Delete all tickets and re-insert the winning ticket |
25 | 25 | $db->query('DELETE FROM player_has_ticket WHERE game_id = '.$db->escapeNumber($gameID)); |
26 | 26 | $db->query('INSERT INTO player_has_ticket (game_id, account_id, time, prize) ' |
27 | - .'VALUES ('.$db->escapeNumber($gameID).','.$db->escapeNumber($winner_id).',\'0\','.$db->escapeNumber($lottoInfo['Prize']).')'); |
|
27 | + .'VALUES ('.$db->escapeNumber($gameID).','.$db->escapeNumber($winner_id).',\'0\','.$db->escapeNumber($lottoInfo['Prize']).')'); |
|
28 | 28 | |
29 | 29 | //get around locked table problem |
30 | 30 | $lottoWon = true; |
@@ -6,6 +6,6 @@ |
||
6 | 6 | use SmrMySqlSecrets; |
7 | 7 | public function __construct() { |
8 | 8 | parent::__construct(self::$host, self::$user, self::$password, self::$dbName_SmrClassicHistory, |
9 | - self::$port, self::$socket); |
|
9 | + self::$port, self::$socket); |
|
10 | 10 | } |
11 | 11 | } |
@@ -110,7 +110,7 @@ |
||
110 | 110 | } |
111 | 111 | $helper = self::getTwitterObj($_SESSION['TwitterToken']); |
112 | 112 | $accessToken = $helper->oauth('oauth/access_token', |
113 | - ['oauth_verifier' => $_REQUEST['oauth_verifier']]); |
|
113 | + ['oauth_verifier' => $_REQUEST['oauth_verifier']]); |
|
114 | 114 | $auth = self::getTwitterObj($accessToken); |
115 | 115 | $userInfo = $auth->get('account/verify_credentials', ['include_email' => 'true']); |
116 | 116 | if ($auth->getLastHttpCode() == 200) { |
@@ -197,7 +197,7 @@ |
||
197 | 197 | while ($this->db->nextRecord()) { |
198 | 198 | try { |
199 | 199 | $otherPlayer = SmrPlayer::getPlayer($this->db->getInt('from_account_id'), |
200 | - $this->getGameID(), $forceUpdate); |
|
200 | + $this->getGameID(), $forceUpdate); |
|
201 | 201 | } catch (PlayerNotFoundException $e) { |
202 | 202 | // Skip players that have not joined this game |
203 | 203 | continue; |
@@ -6,6 +6,6 @@ |
||
6 | 6 | use SmrMySqlSecrets; |
7 | 7 | public function __construct() { |
8 | 8 | parent::__construct(self::$host, self::$user, self::$password, self::$dbName_Smr12History, |
9 | - self::$port, self::$socket); |
|
9 | + self::$port, self::$socket); |
|
10 | 10 | } |
11 | 11 | } |
@@ -242,9 +242,9 @@ |
||
242 | 242 | */ |
243 | 243 | public function canFight() { |
244 | 244 | return !($this->hasNewbieTurns() || |
245 | - $this->isDead() || |
|
246 | - $this->isLandedOnPlanet() || |
|
247 | - $this->hasFederalProtection()); |
|
245 | + $this->isDead() || |
|
246 | + $this->isLandedOnPlanet() || |
|
247 | + $this->hasFederalProtection()); |
|
248 | 248 | } |
249 | 249 | |
250 | 250 | public function setDead($bool) { |
@@ -77,7 +77,7 @@ discard block |
||
77 | 77 | public static function &createPlanet($gameID,$sectorID,$type=1) { |
78 | 78 | if(!self::getPlanet($gameID,$sectorID)->exists()) { |
79 | 79 | $minTime = max(SmrGame::getGame($gameID)->getStartDate(), |
80 | - SmrGame::getGame($gameID)->getStartTurnsDate()); |
|
80 | + SmrGame::getGame($gameID)->getStartTurnsDate()); |
|
81 | 81 | $inhabitableTime = $minTime + pow(mt_rand(45, 85), 3); |
82 | 82 | |
83 | 83 | // insert planet into db |
@@ -704,7 +704,7 @@ discard block |
||
704 | 704 | if($buildingTypeID===false) { |
705 | 705 | $structs = $this->typeInfo::STRUCTURES; |
706 | 706 | return array_combine(array_keys($structs), |
707 | - array_column($structs, 'max_amount')); |
|
707 | + array_column($structs, 'max_amount')); |
|
708 | 708 | } |
709 | 709 | return $this->getStructureTypes($buildingTypeID)->maxAmount(); |
710 | 710 | } |