Test Failed
Push — trunk ( cc4c01...dc8fe4 )
by SuperNova.WS
13:09
created
metamatter.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -160,7 +160,7 @@  discard block
 block discarded – undo
160 160
     }
161 161
 
162 162
     if (is_array($pay_link) && in_array($pay_link['PAY_LINK_METHOD'], array('POST', 'GET', 'LINK', 'STEP', 'REDIRECT'))) {
163
-      if($pay_link['PAY_LINK_METHOD'] == 'REDIRECT') {
163
+      if ($pay_link['PAY_LINK_METHOD'] == 'REDIRECT') {
164 164
         sys_redirect($pay_link['PAY_LINK_URL']);
165 165
       }
166 166
 
@@ -234,7 +234,7 @@  discard block
 block discarded – undo
234 234
   'PLAYER_CURRENCY'              => $player_currency,
235 235
   'PLAYER_CURRENCY_PRICE_PER_MM' => sn_module_payment::currency_convert(1, $player_currency, 'MM_', 10),
236 236
 
237
-  'UNIT_AMOUNT'                 => (float)$request['metamatter'],
237
+  'UNIT_AMOUNT'                 => (float) $request['metamatter'],
238 238
   'UNIT_AMOUNT_TEXT'            => HelperString::numberFloorAndFormat($request['metamatter']),
239 239
   'UNIT_AMOUNT_BONUS_PERCENT'   => $bonus_percent,
240 240
   'UNIT_AMOUNT_TEXT_DISCOUNTED' => $income_metamatter_text,
Please login to merge, or discard this patch.
classes/Payment/PaymentsMethodsActive.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -160,10 +160,10 @@
 block discarded – undo
160 160
         $paymentMethodId = 0;
161 161
       }
162 162
 
163
-      if(!$paymentMethodId) {
163
+      if (!$paymentMethodId) {
164 164
         $module = $this->modulesInstalled[$moduleName];
165 165
         $methodsOnModule = $module->getMethodList();
166
-        if(count($methodsOnModule) == 1) {
166
+        if (count($methodsOnModule) == 1) {
167 167
           $paymentMethodId = HelperArray::array_key_first($methodsOnModule);
168 168
         }
169 169
       }
Please login to merge, or discard this patch.
classes/Fleet/FleetDispatcher.php 1 patch
Spacing   +5 added lines, -9 removed lines patch added patch discarded remove patch
@@ -170,7 +170,7 @@  discard block
 block discarded – undo
170 170
 //      $this->log_file('Dispatch stopped: lock ' . $runLock->isLocked() .'s' );
171 171
       return self::TASK_ALREADY_LOCKED;
172 172
     }
173
-    register_shutdown_function(function () use ($runLock) {
173
+    register_shutdown_function(function() use ($runLock) {
174 174
 //      $this->log_file('Shutting down');
175 175
       $timeLock = $runLock->isLocked();
176 176
       if ($timeLock > 0 || $timeLock === 0) {
@@ -552,15 +552,11 @@  discard block
 block discarded – undo
552 552
   protected function flt_flyingFleetsSort($a, $b) {
553 553
     return
554 554
       // Сравниваем время флотов - кто раньше, тот и первый обрабатывается
555
-      $a['fleet_time'] > $b['fleet_time'] ? 1 : ($a['fleet_time'] < $b['fleet_time'] ? -1 :
556
-        // Если время - одинаковое, сравниваем события флотов
555
+      $a['fleet_time'] > $b['fleet_time'] ? 1 : ($a['fleet_time'] < $b['fleet_time'] ? -1 : // Если время - одинаковое, сравниваем события флотов
557 556
         // Если события - одинаковые, то флоты равны
558
-        ($a['fleet_event'] == $b['fleet_event'] ? 0 :
559
-          // Если события разные - первыми считаем прибывающие флоты
560
-          ($a['fleet_event'] == EVENT_FLT_ARRIVE ? 1 : ($b['fleet_event'] == EVENT_FLT_ARRIVE ? -1 :
561
-            // Если нет прибывающих флотов - дальше считаем флоты, которые закончили миссию
562
-            ($a['fleet_event'] == EVENT_FLT_ACOMPLISH ? 1 : ($b['fleet_event'] == EVENT_FLT_ACOMPLISH ? -1 :
563
-              // Если нет флотов, закончивших задание - остались возвращающиеся флоты, которые равны между собой
557
+        ($a['fleet_event'] == $b['fleet_event'] ? 0 : // Если события разные - первыми считаем прибывающие флоты
558
+          ($a['fleet_event'] == EVENT_FLT_ARRIVE ? 1 : ($b['fleet_event'] == EVENT_FLT_ARRIVE ? -1 : // Если нет прибывающих флотов - дальше считаем флоты, которые закончили миссию
559
+            ($a['fleet_event'] == EVENT_FLT_ACOMPLISH ? 1 : ($b['fleet_event'] == EVENT_FLT_ACOMPLISH ? -1 : // Если нет флотов, закончивших задание - остались возвращающиеся флоты, которые равны между собой
564 560
               // TODO: Добавить еще проверку по ID флота и/или времени запуска - что бы обсчитывать их в порядке запуска
565 561
               (
566 562
               0 // Вообще сюда доходить не должно - будет отсекаться на равенстве событий
Please login to merge, or discard this patch.
classes/Fleet/TaskDispatchFleets.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -63,7 +63,7 @@
 block discarded – undo
63 63
     $url = HttpUrl::spawn($this->gc)
64 64
       ->parseUrl(SN_ROOT_VIRTUAL)
65 65
       ->addPath('index.php')
66
-      ->addParams(['page' => 'worker', 'mode' => 'dispatchFleets',]);
66
+      ->addParams(['page' => 'worker', 'mode' => 'dispatchFleets', ]);
67 67
 
68 68
     sn_get_url_contents($url->urlSigned());
69 69
 
Please login to merge, or discard this patch.
classes/AjaxController.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -23,7 +23,7 @@  discard block
 block discarded – undo
23 23
 
24 24
     define('IN_AJAX', true);
25 25
 
26
-    if(!is_object($template)) {
26
+    if (!is_object($template)) {
27 27
       $template = SnTemplate::gettemplate('_ajax', true);
28 28
     }
29 29
 
@@ -51,11 +51,11 @@  discard block
 block discarded – undo
51 51
        * @var IPage $page
52 52
        */
53 53
       $page = new $className();
54
-      if(method_exists($page, 'loadParams')) {
54
+      if (method_exists($page, 'loadParams')) {
55 55
         $page->loadParams();
56 56
       }
57 57
 
58
-      if(method_exists($page, $action = sys_get_param_str('action')) && $page->checkAction($action)) {
58
+      if (method_exists($page, $action = sys_get_param_str('action')) && $page->checkAction($action)) {
59 59
         $result = $page->$action();
60 60
         is_array($result) ? HelperArray::merge($template_result['AJAX'], $result) : false;
61 61
       }
Please login to merge, or discard this patch.
classes/classConfig.php 1 patch
Spacing   +25 added lines, -25 removed lines patch added patch discarded remove patch
@@ -201,9 +201,9 @@  discard block
 block discarded – undo
201 201
     'advGoogleLeftMenuCode'        => '(Place here code for banner)',
202 202
 
203 203
     // Alliance bonus calculations
204
-    'ali_bonus_algorithm'          => 0,  // Bonus calculation algorithm
204
+    'ali_bonus_algorithm'          => 0, // Bonus calculation algorithm
205 205
     'ali_bonus_brackets'           => 10, // Brackets count for ALI_BONUS_BY_RANK
206
-    'ali_bonus_brackets_divisor'   => 10,// Bonus divisor for ALI_BONUS_BY_RANK
206
+    'ali_bonus_brackets_divisor'   => 10, // Bonus divisor for ALI_BONUS_BY_RANK
207 207
     'ali_bonus_divisor'            => 10000000, // Rank divisor for ALI_BONUS_BY_POINTS
208 208
     'ali_bonus_members'            => 10, // Minimum alliance size to start using bonus
209 209
 
@@ -245,7 +245,7 @@  discard block
 block discarded – undo
245 245
 
246 246
     'eco_scale_storage'            => 1,
247 247
     'eco_stockman_fleet'           => '', // Black Market - Starting amount of s/h ship merchant to sell
248
-    'eco_stockman_fleet_populate'  => 1,  // Populate empty Stockman fleet with ships or not
248
+    'eco_stockman_fleet_populate'  => 1, // Populate empty Stockman fleet with ships or not
249 249
     'empire_mercenary_base_period' => PERIOD_MONTH, // Base
250 250
     'empire_mercenary_temporary'   => 0, // Temporary empire-wide mercenaries
251 251
 
@@ -256,21 +256,21 @@  discard block
 block discarded – undo
256 256
     'energy_basic_income'          => 0,
257 257
 
258 258
     // Bashing protection settings
259
-    'fleet_bashing_attacks'        => 3,      // Max amount of attack per wave - 3 by default
260
-    'fleet_bashing_interval'       => 1800,   // Maximum interval between attacks when they still count as one wave - 30m by default
261
-    'fleet_bashing_scope'          => 86400,  // Interval on which bashing waves counts - 24h by default
262
-    'fleet_bashing_war_delay'      => 43200,  // Delay before start bashing after declaring war to alliance - 12h by default
263
-    'fleet_bashing_waves'          => 3,      // Max amount of waves per day - 3 by default
259
+    'fleet_bashing_attacks'        => 3, // Max amount of attack per wave - 3 by default
260
+    'fleet_bashing_interval'       => 1800, // Maximum interval between attacks when they still count as one wave - 30m by default
261
+    'fleet_bashing_scope'          => 86400, // Interval on which bashing waves counts - 24h by default
262
+    'fleet_bashing_war_delay'      => 43200, // Delay before start bashing after declaring war to alliance - 12h by default
263
+    'fleet_bashing_waves'          => 3, // Max amount of waves per day - 3 by default
264 264
 
265 265
     'Fleet_Cdr'   => 30,
266 266
     'fleet_speed' => 1,
267 267
 
268
-    self::FLEET_UPDATE_MAX_RUN_TIME => 30,     // Maximum length in seconds for single fleet dispatch run
268
+    self::FLEET_UPDATE_MAX_RUN_TIME => 30, // Maximum length in seconds for single fleet dispatch run
269 269
     'fleet_update_interval'         => 4,
270 270
     'fleet_update_lock'             => '', // SQL time when lock was acquired
271 271
 
272
-    'game_adminEmail'       => 'root@localhost',    // Admin's email to show to users
273
-    'game_counter'          => 0,  // Does built-in page hit counter is on?
272
+    'game_adminEmail'       => 'root@localhost', // Admin's email to show to users
273
+    'game_counter'          => 0, // Does built-in page hit counter is on?
274 274
     // Defaults
275 275
     'game_default_language' => 'ru',
276 276
     'game_default_skin'     => 'skins/EpicBlue/',
@@ -284,14 +284,14 @@  discard block
 block discarded – undo
284 284
     'game_maxSystem'      => 199,
285 285
     'game_maxPlanet'      => 15,
286 286
     // Game global settings
287
-    'game_mode'           => 0,           // 0 - SuperNova, 1 - oGame
287
+    'game_mode'           => 0, // 0 - SuperNova, 1 - oGame
288 288
     'game_name'           => 'SuperNova', // Server name (would be on banners and on top of left menu)
289 289
 
290 290
     'game_news_actual'        => PERIOD_DAY_3, // How long announcement would be marked as "New". In seconds. Default - 3 days
291
-    'game_news_overview'      => 3,    // How much last news to show in Overview page
292
-    'game_news_overview_show' => PERIOD_WEEK_2,    // How long news will be shown in Overview page in seconds. Default - 2 weeks
291
+    'game_news_overview'      => 3, // How much last news to show in Overview page
292
+    'game_news_overview_show' => PERIOD_WEEK_2, // How long news will be shown in Overview page in seconds. Default - 2 weeks
293 293
     // Noob protection
294
-    'game_noob_factor'        => 5,    // Multiplier to divide "stronger" and "weaker" users
294
+    'game_noob_factor'        => 5, // Multiplier to divide "stronger" and "weaker" users
295 295
     'game_noob_points'        => 5000, // Below this point user treated as noob. 0 to disable
296 296
 
297 297
     'game_multiaccount_enabled' => 0, // 1 - allow interactions for players with same IP (multiaccounts)
@@ -346,12 +346,12 @@  discard block
 block discarded – undo
346 346
     'payment_currency_exchange_wmz' => 1,
347 347
     'payment_currency_exchange_pln' => 3.86,
348 348
 
349
-    'payment_lot_price' => 1,     // Lot price in default currency
350
-    'payment_lot_size'  => 2500,  // Lot size. Also service as minimum amount of DM that could be bought with one transaction
349
+    'payment_lot_price' => 1, // Lot price in default currency
350
+    'payment_lot_size'  => 2500, // Lot size. Also service as minimum amount of DM that could be bought with one transaction
351 351
 
352 352
     'planet_capital_cost'          => 25000, // Cost in DM to move Capital to current planet
353
-    'planet_capital_mining_rate'   => 2.0,   // Capital Mining rates
354
-    'planet_capital_building_rate' => 2.0,   // Capital Building rates
353
+    'planet_capital_mining_rate'   => 2.0, // Capital Mining rates
354
+    'planet_capital_building_rate' => 2.0, // Capital Building rates
355 355
     'planet_teleport_cost'         => 50000, // Cost of planet teleportation
356 356
     'planet_teleport_timeout'      => 86400, // Timeout for next teleportation
357 357
 
@@ -373,7 +373,7 @@  discard block
 block discarded – undo
373 373
     'resource_multiplier'     => 1,
374 374
 
375 375
     //Roleplay system
376
-    'rpg_bonus_divisor'       => 10,    // Amount of DM referral shoud get for partner have 1 DM bonus
376
+    'rpg_bonus_divisor'       => 10, // Amount of DM referral shoud get for partner have 1 DM bonus
377 377
     'rpg_bonus_minimum'       => 10000, // Minimum DM ammount for starting paying bonuses to affiliate
378 378
 
379 379
     // Black Market - General
@@ -438,12 +438,12 @@  discard block
 block discarded – undo
438 438
     'url_purchase_metamatter' => '',
439 439
     'url_rules'               => '',
440 440
 
441
-    'users_amount'              => 1,                // Total users count
441
+    'users_amount'              => 1, // Total users count
442 442
     'game_users_online_timeout' => PERIOD_MINUTE_15, // Seconds, How long user should considered ONLINE for online counter
443
-    'game_users_update_online'  => 30,               // How often user online should be refreshed (seconds)
444
-    'var_online_user_time'      => 0,                // When last time user online was refreshed
445
-    'var_online_user_count'     => 0,                // Last calculated online user count
446
-    'server_log_online'         => 0,                // Log online user count
443
+    'game_users_update_online'  => 30, // How often user online should be refreshed (seconds)
444
+    'var_online_user_time'      => 0, // When last time user online was refreshed
445
+    'var_online_user_count'     => 0, // Last calculated online user count
446
+    'server_log_online'         => 0, // Log online user count
447 447
 
448 448
     'user_birthday_celebrate' => 0, // When last time celebrations (i.e. giftgiving) was made
449 449
     'user_birthday_gift'      => 0, // User birthday gift
Please login to merge, or discard this patch.
classes/Core/Scheduler/TaskConditional.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -85,7 +85,7 @@  discard block
 block discarded – undo
85 85
     }
86 86
 
87 87
     // Checking task lock
88
-    if (is_object($this->lock) && !$this->lock->attemptLock(function () {
88
+    if (is_object($this->lock) && !$this->lock->attemptLock(function() {
89 89
         return $this->proceedLockExpiration();
90 90
       }, SN_TIME_NOW)) {
91 91
 
@@ -152,7 +152,7 @@  discard block
 block discarded – undo
152 152
    */
153 153
   protected function updateTaskLastRunTime($time) {
154 154
     $this->db->transactionWrap(
155
-      function () use ($time) {
155
+      function() use ($time) {
156 156
         $this->config->dateWrite($this->configName, $time, classConfig::DATE_TYPE_SQL_STRING);
157 157
       }
158 158
     );
Please login to merge, or discard this patch.
classes/Core/GlobalContainer.php 1 patch
Spacing   +27 added lines, -27 removed lines patch added patch discarded remove patch
@@ -110,123 +110,123 @@
 block discarded – undo
110 110
 
111 111
     // Services --------------------------------------------------------------------------------------------------------
112 112
     // Default db
113
-    $gc->request = function (GlobalContainer $c) {
113
+    $gc->request = function(GlobalContainer $c) {
114 114
       $httpRequest = new HttpRequest($c);
115 115
       $httpRequest->fillCurrent();
116 116
 
117 117
       return $httpRequest;
118 118
     };
119 119
 
120
-    $gc->db = function (GlobalContainer $c) {
120
+    $gc->db = function(GlobalContainer $c) {
121 121
       SN::$db = new db_mysql($c);
122 122
 
123 123
       return SN::$db;
124 124
     };
125 125
 
126
-    $gc->debug = function (/** @noinspection PhpUnusedParameterInspection */
126
+    $gc->debug = function(/** @noinspection PhpUnusedParameterInspection */
127 127
       GlobalContainer $c) {
128 128
       return new debug();
129 129
     };
130 130
 
131
-    $gc->cache = function (GlobalContainer $gc) {
131
+    $gc->cache = function(GlobalContainer $gc) {
132 132
       return new classCache($gc->cachePrefix);
133 133
     };
134 134
 
135
-    $gc->config = function (GlobalContainer $gc) {
135
+    $gc->config = function(GlobalContainer $gc) {
136 136
       return new classConfig($gc->cachePrefix);
137 137
     };
138 138
 
139
-    $gc->crypto = function (GlobalContainer $gc) {
139
+    $gc->crypto = function(GlobalContainer $gc) {
140 140
       return new Crypto($gc);
141 141
     };
142 142
 
143
-    $gc->worker = function (GlobalContainer $gc) {
143
+    $gc->worker = function(GlobalContainer $gc) {
144 144
       return new Worker($gc);
145 145
     };
146 146
 
147
-    $gc->repository = function (GlobalContainer $gc) {
147
+    $gc->repository = function(GlobalContainer $gc) {
148 148
       /** @noinspection PhpDeprecationInspection */
149 149
       return new Repository($gc);
150 150
     };
151 151
 
152
-    $gc->storage = function (GlobalContainer $gc) {
152
+    $gc->storage = function(GlobalContainer $gc) {
153 153
       /** @noinspection PhpDeprecationInspection */
154 154
       return new Storage($gc);
155 155
     };
156 156
 
157
-    $gc->repoV2 = function (GlobalContainer $gc) {
157
+    $gc->repoV2 = function(GlobalContainer $gc) {
158 158
       return new RepoV2($gc);
159 159
     };
160 160
 
161
-    $gc->storageV2 = function (GlobalContainer $gc) {
161
+    $gc->storageV2 = function(GlobalContainer $gc) {
162 162
       return new StorageV2($gc);
163 163
     };
164 164
 
165
-    $gc->storageSqlV2 = function (GlobalContainer $gc) {
165
+    $gc->storageSqlV2 = function(GlobalContainer $gc) {
166 166
       return new StorageSqlV2($gc);
167 167
     };
168 168
 
169
-    $gc->design = function (GlobalContainer $gc) {
169
+    $gc->design = function(GlobalContainer $gc) {
170 170
       return new Design($gc);
171 171
     };
172 172
 
173
-    $gc->bbCodeParser = function (GlobalContainer $gc) {
173
+    $gc->bbCodeParser = function(GlobalContainer $gc) {
174 174
       return new BBCodeParser($gc);
175 175
     };
176 176
 
177
-    $gc->fleetDispatcher = function (GlobalContainer $gc) {
177
+    $gc->fleetDispatcher = function(GlobalContainer $gc) {
178 178
       return new FleetDispatcher($gc);
179 179
     };
180 180
 
181
-    $gc->watchdog = function (GlobalContainer $gc) {
181
+    $gc->watchdog = function(GlobalContainer $gc) {
182 182
       return new Watchdog($gc);
183 183
     };
184 184
 
185
-    $gc->valueStorage = function (/** @noinspection PhpUnusedParameterInspection */ GlobalContainer $gc) {
185
+    $gc->valueStorage = function(/** @noinspection PhpUnusedParameterInspection */ GlobalContainer $gc) {
186 186
       return new ValueStorage([]);
187 187
     };
188 188
 
189
-    $gc->bonusCatalog = function (GlobalContainer $gc) {
189
+    $gc->bonusCatalog = function(GlobalContainer $gc) {
190 190
       return new BonusCatalog($gc);
191 191
     };
192 192
 
193
-    $gc->general = function (GlobalContainer $gc) {
193
+    $gc->general = function(GlobalContainer $gc) {
194 194
       return new General($gc);
195 195
     };
196 196
 
197
-    $gc->economicHelper = function (GlobalContainer $gc) {
197
+    $gc->economicHelper = function(GlobalContainer $gc) {
198 198
       return new EconomicHelper($gc);
199 199
     };
200 200
 
201
-    $gc->playerLevelHelper = function (GlobalContainer $gc) {
201
+    $gc->playerLevelHelper = function(GlobalContainer $gc) {
202 202
       return new PlayerLevelHelper($gc);
203 203
     };
204 204
 
205
-    $gc->pimp = function (GlobalContainer $gc) {
205
+    $gc->pimp = function(GlobalContainer $gc) {
206 206
       return new SnPimp($gc);
207 207
     };
208 208
 
209
-    $gc->modules = function (GlobalContainer $gc) {
209
+    $gc->modules = function(GlobalContainer $gc) {
210 210
       return new ModulesManager($gc);
211 211
     };
212 212
 
213 213
     // Dummy objects ---------------------------------------------------------------------------------------------------
214
-    $gc->theUser = function (GlobalContainer $gc) {
214
+    $gc->theUser = function(GlobalContainer $gc) {
215 215
       return new TheUser($gc);
216 216
     };
217 217
 
218 218
 
219 219
     // Models ----------------------------------------------------------------------------------------------------------
220 220
     $gc->skinEntityClass = SkinV2::class;
221
-    $gc->skinModel       = function (GlobalContainer $gc) {
221
+    $gc->skinModel       = function(GlobalContainer $gc) {
222 222
       return new SkinModel($gc);
223 223
     };
224 224
 
225
-    $gc->textModel = function (GlobalContainer $gc) {
225
+    $gc->textModel = function(GlobalContainer $gc) {
226 226
       return new TextModel($gc);
227 227
     };
228 228
 
229
-    $gc->ignores = function (GlobalContainer $gc) {
229
+    $gc->ignores = function(GlobalContainer $gc) {
230 230
       return new PlayerIgnore($gc);
231 231
     };
232 232
 
Please login to merge, or discard this patch.
includes/vars.php 1 patch
Spacing   +34 added lines, -34 removed lines patch added patch discarded remove patch
@@ -33,8 +33,8 @@  discard block
 block discarded – undo
33 33
 
34 34
 //    'chat'     => ['sn_chat_model'],
35 35
 //    'chat_add' => ['sn_chat_add_model'],
36
-    'chat'     => [Chat::class  . '::' . 'chatModel'],
37
-    'chat_add' => [Chat::class  . '::' . 'chatAddModel'],
36
+    'chat'     => [Chat::class . '::' . 'chatModel'],
37
+    'chat_add' => [Chat::class . '::' . 'chatAddModel'],
38 38
 
39 39
     'imperium' => [PageImperium::class . '::' . 'modelStatic'],
40 40
 
@@ -48,9 +48,9 @@  discard block
 block discarded – undo
48 48
 
49 49
 //    'chat'          => ['sn_chat_view'],
50 50
 //    'chat_msg'      => ['sn_chat_msg_view'],
51
-    'chat'          => [Chat::class  . '::' . 'chatView'],
52
-    'chat_msg'      => [Chat::class  . '::' . 'chatMsgView'],
53
-    'chat_frame'      => [Chat::class  . '::' . 'chatFrameView'],
51
+    'chat'          => [Chat::class . '::' . 'chatView'],
52
+    'chat_msg'      => [Chat::class . '::' . 'chatMsgView'],
53
+    'chat_frame'      => [Chat::class . '::' . 'chatFrameView'],
54 54
 
55 55
     'battle_report' => ['sn_battle_report_view'],
56 56
     'contact'       => ['sn_contact_view'],
@@ -646,29 +646,29 @@  discard block
 block discarded – undo
646 646
         P_MISSION_EXPEDITION_OUTCOME           => FLT_EXPEDITION_OUTCOME_FOUND_FLEET,
647 647
         P_MISSION_EXPEDITION_OUTCOME_TYPE      => FLT_EXPEDITION_OUTCOME_TYPE_GOOD,
648 648
         P_CHANCE                               => 200,
649
-        'percent'                              => [0 => 0.1, 1 => 0.02, 2 => 0.01,],
649
+        'percent'                              => [0 => 0.1, 1 => 0.02, 2 => 0.01, ],
650 650
         P_MISSION_EXPEDITION_OUTCOME_SECONDARY => [
651
-          [P_CHANCE => 90, P_MULTIPLIER => 0.01, P_MESSAGE_ID => 2,],
652
-          [P_CHANCE => 9, P_MULTIPLIER => 0.02, P_MESSAGE_ID => 1,],
653
-          [P_CHANCE => 1, P_MULTIPLIER => 0.10, P_MESSAGE_ID => 0,],
651
+          [P_CHANCE => 90, P_MULTIPLIER => 0.01, P_MESSAGE_ID => 2, ],
652
+          [P_CHANCE => 9, P_MULTIPLIER => 0.02, P_MESSAGE_ID => 1, ],
653
+          [P_CHANCE => 1, P_MULTIPLIER => 0.10, P_MESSAGE_ID => 0, ],
654 654
         ],
655 655
       ],
656 656
       FLT_EXPEDITION_OUTCOME_FOUND_RESOURCES => [
657 657
         P_MISSION_EXPEDITION_OUTCOME           => FLT_EXPEDITION_OUTCOME_FOUND_RESOURCES,
658 658
         P_MISSION_EXPEDITION_OUTCOME_TYPE      => FLT_EXPEDITION_OUTCOME_TYPE_GOOD,
659 659
         P_CHANCE                               => 300,
660
-        'percent'                              => [0 => 0.1, 1 => 0.050, 2 => 0.025,],
660
+        'percent'                              => [0 => 0.1, 1 => 0.050, 2 => 0.025, ],
661 661
         P_MISSION_EXPEDITION_OUTCOME_SECONDARY => [
662
-          [P_CHANCE => 90, P_MULTIPLIER => 0.025, P_MESSAGE_ID => 2,],
663
-          [P_CHANCE => 9, P_MULTIPLIER => 0.050, P_MESSAGE_ID => 1,],
664
-          [P_CHANCE => 1, P_MULTIPLIER => 0.100, P_MESSAGE_ID => 0,],
662
+          [P_CHANCE => 90, P_MULTIPLIER => 0.025, P_MESSAGE_ID => 2, ],
663
+          [P_CHANCE => 9, P_MULTIPLIER => 0.050, P_MESSAGE_ID => 1, ],
664
+          [P_CHANCE => 1, P_MULTIPLIER => 0.100, P_MESSAGE_ID => 0, ],
665 665
         ],
666 666
       ],
667 667
       FLT_EXPEDITION_OUTCOME_FOUND_DM        => [
668 668
         P_MISSION_EXPEDITION_OUTCOME           => FLT_EXPEDITION_OUTCOME_FOUND_DM,
669 669
         P_MISSION_EXPEDITION_OUTCOME_TYPE      => FLT_EXPEDITION_OUTCOME_TYPE_GOOD,
670 670
         P_CHANCE                               => 100,
671
-        'percent'                              => [0 => 0.0100, 1 => 0.0040, 2 => 0.0010,],
671
+        'percent'                              => [0 => 0.0100, 1 => 0.0040, 2 => 0.0010, ],
672 672
         P_MISSION_EXPEDITION_OUTCOME_SECONDARY => [
673 673
           [P_CHANCE => 90, P_MULTIPLIER => 0.0010, /*P_MESSAGE_ID => 2,*/],
674 674
           [P_CHANCE => 9, P_MULTIPLIER => 0.0040, /*P_MESSAGE_ID => 1,*/],
@@ -703,14 +703,14 @@  discard block
 block discarded – undo
703 703
     ],
704 704
 
705 705
     'planet_generator' => [
706
-      0  => [ // HomeWorld
706
+      0  => [// HomeWorld
707 707
         't_max_min'     => 40, // Tmax 40
708 708
         't_max_max'     => 40,
709 709
         't_delta_min'   => 40, // Tmin 0
710 710
         't_delta_max'   => 40,
711 711
         'size_min'      => $config->initial_fields,
712 712
         'size_max'      => $config->initial_fields,
713
-        'core_types'    => [PLANET_DENSITY_STANDARD,],
713
+        'core_types'    => [PLANET_DENSITY_STANDARD, ],
714 714
         'planet_images' => ['normaltemp'],
715 715
       ],
716 716
       1  => [
@@ -940,7 +940,7 @@  discard block
 block discarded – undo
940 940
         ],
941 941
         'planet_images' => ['eis'],
942 942
       ],
943
-      16 => [ // Random planet - stranger; -35 avg
943
+      16 => [// Random planet - stranger; -35 avg
944 944
         't_max_min'     => -90,
945 945
         't_max_max'     => +40,
946 946
         't_delta_min'   => 2,
@@ -960,7 +960,7 @@  discard block
 block discarded – undo
960 960
           PLANET_DENSITY_METAL_PERIDOT,
961 961
           PLANET_DENSITY_METAL_RAW,
962 962
         ],
963
-        'planet_images' => ['trocken', 'dschjungel', 'normaltemp', 'wasser', 'eis',],
963
+        'planet_images' => ['trocken', 'dschjungel', 'normaltemp', 'wasser', 'eis', ],
964 964
       ],
965 965
     ],
966 966
 
@@ -983,7 +983,7 @@  discard block
 block discarded – undo
983 983
         UNIT_PLANET_DENSITY_INDEX         => PLANET_DENSITY_ICE_HYDROGEN,
984 984
         UNIT_PLANET_DENSITY_RARITY        => 30, // 1, // 40.00, // * 1/121 0,82645
985 985
         UNIT_PLANET_DENSITY_RICHNESS      => PLANET_DENSITY_RICHNESS_PERFECT,
986
-        UNIT_RESOURCES                    => [RES_METAL => 0.20, RES_CRYSTAL => 0.60, RES_DEUTERIUM => 7.10,],
986
+        UNIT_RESOURCES                    => [RES_METAL => 0.20, RES_CRYSTAL => 0.60, RES_DEUTERIUM => 7.10, ],
987 987
         UNIT_PLANET_DENSITY_MAX_SECTORS   => 150,
988 988
         UNIT_PLANET_DENSITY_MIN_ASTROTECH => 11,
989 989
       ],
@@ -992,7 +992,7 @@  discard block
 block discarded – undo
992 992
         UNIT_PLANET_DENSITY_INDEX         => PLANET_DENSITY_ICE_METHANE,
993 993
         UNIT_PLANET_DENSITY_RARITY        => 130, // 6, // 6.67, // * 6,0	4,95868
994 994
         UNIT_PLANET_DENSITY_RICHNESS      => PLANET_DENSITY_RICHNESS_GOOD,
995
-        UNIT_RESOURCES                    => [RES_METAL => 0.55, RES_CRYSTAL => 0.85, RES_DEUTERIUM => 4.60,],
995
+        UNIT_RESOURCES                    => [RES_METAL => 0.55, RES_CRYSTAL => 0.85, RES_DEUTERIUM => 4.60, ],
996 996
         UNIT_PLANET_DENSITY_MAX_SECTORS   => 200,
997 997
         UNIT_PLANET_DENSITY_MIN_ASTROTECH => 6,
998 998
       ],
@@ -1001,7 +1001,7 @@  discard block
 block discarded – undo
1001 1001
         UNIT_PLANET_DENSITY_INDEX         => PLANET_DENSITY_ICE_WATER,
1002 1002
         UNIT_PLANET_DENSITY_RARITY        => 450, //20, // 2.00, // * 20,0	16,52893
1003 1003
         UNIT_PLANET_DENSITY_RICHNESS      => PLANET_DENSITY_RICHNESS_AVERAGE,
1004
-        UNIT_RESOURCES                    => [RES_METAL => 0.86, RES_CRYSTAL => 0.95, RES_DEUTERIUM => 2.20,],
1004
+        UNIT_RESOURCES                    => [RES_METAL => 0.86, RES_CRYSTAL => 0.95, RES_DEUTERIUM => 2.20, ],
1005 1005
         UNIT_PLANET_DENSITY_MAX_SECTORS   => 999,
1006 1006
         UNIT_PLANET_DENSITY_MIN_ASTROTECH => 0,
1007 1007
       ],
@@ -1011,7 +1011,7 @@  discard block
 block discarded – undo
1011 1011
         UNIT_PLANET_DENSITY_INDEX         => PLANET_DENSITY_CRYSTAL_RAW,
1012 1012
         UNIT_PLANET_DENSITY_RARITY        => 20, // 1, // 40.00, // *1,0	0,82645
1013 1013
         UNIT_PLANET_DENSITY_RICHNESS      => PLANET_DENSITY_RICHNESS_PERFECT,
1014
-        UNIT_RESOURCES                    => [RES_METAL => 0.40, RES_CRYSTAL => 12.37, RES_DEUTERIUM => 0.50,],
1014
+        UNIT_RESOURCES                    => [RES_METAL => 0.40, RES_CRYSTAL => 12.37, RES_DEUTERIUM => 0.50, ],
1015 1015
         UNIT_PLANET_DENSITY_MAX_SECTORS   => 150,
1016 1016
         UNIT_PLANET_DENSITY_MIN_ASTROTECH => 11,
1017 1017
       ],
@@ -1020,7 +1020,7 @@  discard block
 block discarded – undo
1020 1020
         UNIT_PLANET_DENSITY_INDEX         => PLANET_DENSITY_CRYSTAL_SILICATE,
1021 1021
         UNIT_PLANET_DENSITY_RARITY        => 140, // 5.71, // * 7,0	5,78512
1022 1022
         UNIT_PLANET_DENSITY_RICHNESS      => PLANET_DENSITY_RICHNESS_GOOD,
1023
-        UNIT_RESOURCES                    => [RES_METAL => 0.67, RES_CRYSTAL => 4.50, RES_DEUTERIUM => 0.85,],
1023
+        UNIT_RESOURCES                    => [RES_METAL => 0.67, RES_CRYSTAL => 4.50, RES_DEUTERIUM => 0.85, ],
1024 1024
         UNIT_PLANET_DENSITY_MAX_SECTORS   => 200,
1025 1025
         UNIT_PLANET_DENSITY_MIN_ASTROTECH => 6,
1026 1026
       ],
@@ -1029,7 +1029,7 @@  discard block
 block discarded – undo
1029 1029
         UNIT_PLANET_DENSITY_INDEX         => PLANET_DENSITY_CRYSTAL_STONE,
1030 1030
         UNIT_PLANET_DENSITY_RARITY        => 500, // 1.90, // * 21,0	17,35537
1031 1031
         UNIT_PLANET_DENSITY_RICHNESS      => PLANET_DENSITY_RICHNESS_AVERAGE,
1032
-        UNIT_RESOURCES                    => [RES_METAL => 0.80, RES_CRYSTAL => 2.00, RES_DEUTERIUM => 0.95,],
1032
+        UNIT_RESOURCES                    => [RES_METAL => 0.80, RES_CRYSTAL => 2.00, RES_DEUTERIUM => 0.95, ],
1033 1033
         UNIT_PLANET_DENSITY_MAX_SECTORS   => 999,
1034 1034
         UNIT_PLANET_DENSITY_MIN_ASTROTECH => 0,
1035 1035
       ],
@@ -1039,7 +1039,7 @@  discard block
 block discarded – undo
1039 1039
         UNIT_PLANET_DENSITY_INDEX         => PLANET_DENSITY_STANDARD,
1040 1040
         UNIT_PLANET_DENSITY_RARITY        => 1000, // 1.0, // * 40,0	33,05785
1041 1041
         UNIT_PLANET_DENSITY_RICHNESS      => PLANET_DENSITY_RICHNESS_NORMAL,
1042
-        UNIT_RESOURCES                    => [RES_METAL => 1.00, RES_CRYSTAL => 1.00, RES_DEUTERIUM => 1.00,],
1042
+        UNIT_RESOURCES                    => [RES_METAL => 1.00, RES_CRYSTAL => 1.00, RES_DEUTERIUM => 1.00, ],
1043 1043
         UNIT_PLANET_DENSITY_MAX_SECTORS   => 999,
1044 1044
         UNIT_PLANET_DENSITY_MIN_ASTROTECH => 0,
1045 1045
       ],
@@ -1049,7 +1049,7 @@  discard block
 block discarded – undo
1049 1049
         UNIT_PLANET_DENSITY_INDEX         => PLANET_DENSITY_METAL_ORE,
1050 1050
         UNIT_PLANET_DENSITY_RARITY        => 550, // 2.11, // * 19,0	15,70248
1051 1051
         UNIT_PLANET_DENSITY_RICHNESS      => PLANET_DENSITY_RICHNESS_AVERAGE,
1052
-        UNIT_RESOURCES                    => [RES_METAL => 1.60, RES_CRYSTAL => 0.90, RES_DEUTERIUM => 0.80,],
1052
+        UNIT_RESOURCES                    => [RES_METAL => 1.60, RES_CRYSTAL => 0.90, RES_DEUTERIUM => 0.80, ],
1053 1053
         UNIT_PLANET_DENSITY_MAX_SECTORS   => 999,
1054 1054
         UNIT_PLANET_DENSITY_MIN_ASTROTECH => 0,
1055 1055
       ],
@@ -1058,7 +1058,7 @@  discard block
 block discarded – undo
1058 1058
         UNIT_PLANET_DENSITY_INDEX         => PLANET_DENSITY_METAL_PERIDOT,
1059 1059
         UNIT_PLANET_DENSITY_RARITY        => 120, // 8.00, // * 5,0	4,13223
1060 1060
         UNIT_PLANET_DENSITY_RICHNESS      => PLANET_DENSITY_RICHNESS_GOOD,
1061
-        UNIT_RESOURCES                    => [RES_METAL => 4.71, RES_CRYSTAL => 0.80, RES_DEUTERIUM => 0.55,],
1061
+        UNIT_RESOURCES                    => [RES_METAL => 4.71, RES_CRYSTAL => 0.80, RES_DEUTERIUM => 0.55, ],
1062 1062
         UNIT_PLANET_DENSITY_MAX_SECTORS   => 200,
1063 1063
         UNIT_PLANET_DENSITY_MIN_ASTROTECH => 6,
1064 1064
       ],
@@ -1067,7 +1067,7 @@  discard block
 block discarded – undo
1067 1067
         UNIT_PLANET_DENSITY_INDEX         => PLANET_DENSITY_METAL_RAW,
1068 1068
         UNIT_PLANET_DENSITY_RARITY        => 25, // 40.00, // * 1,0	0,82645
1069 1069
         UNIT_PLANET_DENSITY_RICHNESS      => PLANET_DENSITY_RICHNESS_PERFECT,
1070
-        UNIT_RESOURCES                    => [RES_METAL => 8.00, RES_CRYSTAL => 0.40, RES_DEUTERIUM => 0.25,],
1070
+        UNIT_RESOURCES                    => [RES_METAL => 8.00, RES_CRYSTAL => 0.40, RES_DEUTERIUM => 0.25, ],
1071 1071
         UNIT_PLANET_DENSITY_MAX_SECTORS   => 150,
1072 1072
         UNIT_PLANET_DENSITY_MIN_ASTROTECH => 11,
1073 1073
       ],
@@ -1244,7 +1244,7 @@  discard block
 block discarded – undo
1244 1244
     ],
1245 1245
 
1246 1246
     // Missiles list
1247
-    UNIT_DEF_MISSILES_STR => [UNIT_DEF_MISSILE_INTERCEPTOR => UNIT_DEF_MISSILE_INTERCEPTOR, UNIT_DEF_MISSILE_INTERPLANET => UNIT_DEF_MISSILE_INTERPLANET,],
1247
+    UNIT_DEF_MISSILES_STR => [UNIT_DEF_MISSILE_INTERCEPTOR => UNIT_DEF_MISSILE_INTERCEPTOR, UNIT_DEF_MISSILE_INTERPLANET => UNIT_DEF_MISSILE_INTERPLANET, ],
1248 1248
 
1249 1249
     // Combat units list
1250 1250
     'combat'             => [
@@ -1293,7 +1293,7 @@  discard block
 block discarded – undo
1293 1293
     // Resource list
1294 1294
     UNIT_RESOURCES_STR      => [0 => 'metal', 1 => 'crystal', 2 => 'deuterium', 3 => 'dark_matter'],
1295 1295
     // Resources all
1296
-    'resources_all'         => [RES_METAL => RES_METAL, RES_CRYSTAL => RES_CRYSTAL, RES_DEUTERIUM => RES_DEUTERIUM, RES_ENERGY => RES_ENERGY, RES_DARK_MATTER => RES_DARK_MATTER, RES_METAMATTER => RES_METAMATTER,],
1296
+    'resources_all'         => [RES_METAL => RES_METAL, RES_CRYSTAL => RES_CRYSTAL, RES_DEUTERIUM => RES_DEUTERIUM, RES_ENERGY => RES_ENERGY, RES_DARK_MATTER => RES_DARK_MATTER, RES_METAMATTER => RES_METAMATTER, ],
1297 1297
     // Resources can be produced on planet
1298 1298
     'resources_planet'      => [RES_METAL => RES_METAL, RES_CRYSTAL => RES_CRYSTAL, RES_DEUTERIUM => RES_DEUTERIUM, RES_ENERGY => RES_ENERGY],
1299 1299
     // Resources can be looted from planet
@@ -1312,13 +1312,13 @@  discard block
 block discarded – undo
1312 1312
     ],
1313 1313
 
1314 1314
     // Resources that can be tradeable in market trader AND be a quest_rewards
1315
-    'quest_rewards'      => [RES_METAL => RES_METAL, RES_CRYSTAL => RES_CRYSTAL, RES_DEUTERIUM => RES_DEUTERIUM, RES_DARK_MATTER => RES_DARK_MATTER,],
1315
+    'quest_rewards'      => [RES_METAL => RES_METAL, RES_CRYSTAL => RES_CRYSTAL, RES_DEUTERIUM => RES_DEUTERIUM, RES_DARK_MATTER => RES_DARK_MATTER, ],
1316 1316
 
1317 1317
 //      // Ques list
1318 1318
 //      'ques' => array(QUE_STRUCTURES, QUE_HANGAR, QUE_RESEARCH),
1319 1319
 
1320
-    'STAT_COMMON' => [STAT_TOTAL => STAT_TOTAL, STAT_FLEET => STAT_FLEET, STAT_TECH => STAT_TECH, STAT_BUILDING => STAT_BUILDING, STAT_DEFENSE => STAT_DEFENSE, STAT_RESOURCE => STAT_RESOURCE,],
1321
-    'STAT_PLAYER' => [STAT_RAID_TOTAL => STAT_RAID_TOTAL, STAT_RAID_WON => STAT_RAID_WON, STAT_RAID_LOST => STAT_RAID_LOST, STAT_LVL_BUILDING => STAT_LVL_BUILDING, STAT_LVL_TECH => STAT_LVL_TECH, STAT_LVL_RAID => STAT_LVL_RAID,],
1320
+    'STAT_COMMON' => [STAT_TOTAL => STAT_TOTAL, STAT_FLEET => STAT_FLEET, STAT_TECH => STAT_TECH, STAT_BUILDING => STAT_BUILDING, STAT_DEFENSE => STAT_DEFENSE, STAT_RESOURCE => STAT_RESOURCE, ],
1321
+    'STAT_PLAYER' => [STAT_RAID_TOTAL => STAT_RAID_TOTAL, STAT_RAID_WON => STAT_RAID_WON, STAT_RAID_LOST => STAT_RAID_LOST, STAT_LVL_BUILDING => STAT_LVL_BUILDING, STAT_LVL_TECH => STAT_LVL_TECH, STAT_LVL_RAID => STAT_LVL_RAID, ],
1322 1322
 
1323 1323
     GROUP_GROUP_ID_TO_NAMES => [
1324 1324
       UNIT_STRUCTURES   => 'structures',
@@ -1332,7 +1332,7 @@  discard block
 block discarded – undo
1332 1332
       UNIT_PLANS        => 'plans',
1333 1333
     ],
1334 1334
 
1335
-    GROUP_CAPITAL_BUILDING_BONUS_GROUPS => ['structures', 'defense', 'fleet',],
1335
+    GROUP_CAPITAL_BUILDING_BONUS_GROUPS => ['structures', 'defense', 'fleet', ],
1336 1336
 
1337 1337
     GROUP_UNIT_COMBAT_SORT_ORDER => [
1338 1338
       SHIP_SPY,
Please login to merge, or discard this patch.