@@ -19,12 +19,20 @@ discard block |
||
19 | 19 | const TEMPLATE_INACTIVE_PLAYER = 51; |
20 | 20 | const TEMPLATE_SPONSORSHIP = 52; |
21 | 21 | |
22 | + /** |
|
23 | + * @param string $path |
|
24 | + * @param integer $server |
|
25 | + * @param string $key |
|
26 | + */ |
|
22 | 27 | public function __construct($path, $server, $key) { |
23 | 28 | $this->path = $path; |
24 | 29 | $this->server = $server; |
25 | 30 | $this->key = $key; |
26 | 31 | } |
27 | 32 | |
33 | + /** |
|
34 | + * @param string $api |
|
35 | + */ |
|
28 | 36 | private function query($api, $args) { |
29 | 37 | $targ = ''; |
30 | 38 | $ch = curl_init(); |
@@ -84,6 +92,9 @@ discard block |
||
84 | 92 | } |
85 | 93 | } |
86 | 94 | |
95 | + /** |
|
96 | + * @param integer $serverId |
|
97 | + */ |
|
87 | 98 | public function playerIsDead($bindkey, $serverId) { |
88 | 99 | if ($this->query('playerisdead', array('bindkey' => $bindkey, 'serverid' => $serverId))) { |
89 | 100 | if ($this->data['statement'] == 'success') { |
@@ -294,6 +294,9 @@ |
||
294 | 294 | $this->newSession(FALSE); |
295 | 295 | } |
296 | 296 | |
297 | + /** |
|
298 | + * @param Report $newReport |
|
299 | + */ |
|
297 | 300 | public function add($newReport) { |
298 | 301 | $db = Database::getInstance(); |
299 | 302 |
@@ -16,7 +16,6 @@ discard block |
||
16 | 16 | use Asylamba\Classes\Library\Game; |
17 | 17 | use Asylamba\Classes\Library\Utils; |
18 | 18 | use Asylamba\Classes\Library\Format; |
19 | - |
|
20 | 19 | use Asylamba\Modules\Ares\FightController; |
21 | 20 | use Asylamba\Modules\Zeus\Model\PlayerBonus; |
22 | 21 | use Asylamba\Modules\Ares\Model\Commander; |
@@ -25,7 +24,6 @@ discard block |
||
25 | 24 | use Asylamba\Modules\Ares\Model\Report; |
26 | 25 | use Asylamba\Modules\Hermes\Model\Notification; |
27 | 26 | use Asylamba\Modules\Demeter\Model\Color; |
28 | - |
|
29 | 27 | use Asylamba\Modules\Gaia\Resource\SquadronResource; |
30 | 28 | |
31 | 29 | class Place { |
@@ -199,6 +199,9 @@ |
||
199 | 199 | } |
200 | 200 | } |
201 | 201 | |
202 | + /** |
|
203 | + * @param integer $i |
|
204 | + */ |
|
202 | 205 | public function getSquadron($i) { |
203 | 206 | $this->setArmy(); |
204 | 207 | if (!empty($this->army[$i])) { |
@@ -14,12 +14,9 @@ |
||
14 | 14 | |
15 | 15 | use Asylamba\Classes\Worker\CTR; |
16 | 16 | use Asylamba\Classes\Worker\ASM; |
17 | - |
|
18 | 17 | use Asylamba\Classes\Container\StackList; |
19 | - |
|
20 | 18 | use Asylamba\Modules\Promethee\Model\Technology; |
21 | 19 | use Asylamba\Modules\Demeter\Model\Law\Law; |
22 | - |
|
23 | 20 | use Asylamba\Modules\Demeter\Resource\ColorResource; |
24 | 21 | use Asylamba\Modules\Promethee\Resource\TechnologyResource; |
25 | 22 | use Asylamba\Modules\Demeter\Resource\LawResources; |
@@ -29,6 +29,9 @@ discard block |
||
29 | 29 | public $pev = 0; |
30 | 30 | public $isAttacker; |
31 | 31 | |
32 | + /** |
|
33 | + * @param integer $nbrName |
|
34 | + */ |
|
32 | 35 | public function __construct($nbrName, $isAttacker) { |
33 | 36 | $this->nbrName = $nbrName; |
34 | 37 | $this->isAttacker = $isAttacker; |
@@ -106,6 +109,10 @@ discard block |
||
106 | 109 | return $aleaNbr; |
107 | 110 | } |
108 | 111 | |
112 | + /** |
|
113 | + * @param integer $key |
|
114 | + * @param integer $i |
|
115 | + */ |
|
109 | 116 | protected function attack($key, $i, $enemySquadron) { |
110 | 117 | $damages = ceil(log(($this->attack[$i] / $enemySquadron->getShip($key)->getDefense()) + 1) * 4 * $this->attack[$i]); |
111 | 118 | $enemySquadron->getShip($key)->receiveDamages($damages, $enemySquadron, $key); |
@@ -128,6 +135,9 @@ discard block |
||
128 | 135 | } |
129 | 136 | } |
130 | 137 | |
138 | + /** |
|
139 | + * @param integer $id |
|
140 | + */ |
|
131 | 141 | public function affectId ($id) { |
132 | 142 | $this->id = $id + 1; |
133 | 143 | } |
@@ -77,6 +77,10 @@ |
||
77 | 77 | |
78 | 78 | public function setRelId($id) { $this->relId = $id; } |
79 | 79 | |
80 | + /** |
|
81 | + * @param integer $position |
|
82 | + * @param integer $rCommander |
|
83 | + */ |
|
80 | 84 | public function __construct($vector, $id, $lineCoord, $position, $rCommander, $isAttacker = NULL) { |
81 | 85 | for($i = 0; $i < 12; $i++) { |
82 | 86 | $this->arrayOfShips[] = $vector[$i]; |
@@ -14,7 +14,6 @@ |
||
14 | 14 | use Asylamba\Classes\Worker\Manager; |
15 | 15 | use Asylamba\Classes\Library\Utils; |
16 | 16 | use Asylamba\Classes\Database\Database; |
17 | - |
|
18 | 17 | use Asylamba\Modules\Zeus\Model\CreditTransaction; |
19 | 18 | |
20 | 19 | class CreditTransactionManager extends Manager { |
@@ -195,6 +195,9 @@ |
||
195 | 195 | return TRUE; |
196 | 196 | } |
197 | 197 | |
198 | + /** |
|
199 | + * @param Color $color1 |
|
200 | + */ |
|
198 | 201 | public static function freezeRoute($color1, $color2) { |
199 | 202 | $freeze = TRUE; |
200 | 203 | if (!($color1->colorLink[$color2->id] == Color::ENEMY || $color2->colorLink[$color1->id] == Color::ENEMY)) { |
@@ -108,6 +108,10 @@ discard block |
||
108 | 108 | public function getId() { return $this->rPlace; } |
109 | 109 | public function getRPlace() { return $this->rPlace; } |
110 | 110 | public function getRPlayer() { return $this->rPlayer; } |
111 | + |
|
112 | + /** |
|
113 | + * @return string |
|
114 | + */ |
|
111 | 115 | public function getName() { return $this->name; } |
112 | 116 | public function getLevelGenerator() { return $this->levelGenerator; } |
113 | 117 | public function getLevelRefinery() { return $this->levelRefinery; } |
@@ -205,9 +209,24 @@ discard block |
||
205 | 209 | public function setPlanetResources($var) { $this->planetResources = $var; } |
206 | 210 | public function setPlanetHistory($var) { $this->planetHistory = $var; } |
207 | 211 | |
212 | + /** |
|
213 | + * @param double $var |
|
214 | + */ |
|
208 | 215 | public function setRemainingTimeGenerator($var) { $this->remainingTimeGenerator = $var; } |
216 | + |
|
217 | + /** |
|
218 | + * @param double $var |
|
219 | + */ |
|
209 | 220 | public function setRemainingTimeDock1($var) { $this->remainingTimeDock1 = $var; } |
221 | + |
|
222 | + /** |
|
223 | + * @param double $var |
|
224 | + */ |
|
210 | 225 | public function setRemainingTimeDock2($var) { $this->remainingTimeDock2 = $var; } |
226 | + |
|
227 | + /** |
|
228 | + * @param double $var |
|
229 | + */ |
|
211 | 230 | public function setRemainingTimeDock3($var) { $this->remainingTimeDock3 = $var; } |
212 | 231 | public function setRoutesNumber($var) { $this->routesNumber = $var; } |
213 | 232 | |
@@ -768,6 +787,9 @@ discard block |
||
768 | 787 | } |
769 | 788 | } |
770 | 789 | |
790 | + /** |
|
791 | + * @param integer $shipId |
|
792 | + */ |
|
771 | 793 | public function addShipToDock($shipId, $quantity) { |
772 | 794 | if (OrbitalBaseResource::isAShipFromDock1($shipId) OR OrbitalBaseResource::isAShipFromDock2($shipId)) { |
773 | 795 | self::setShipStorage($shipId, self::getShipStorage($shipId) + $quantity); |
@@ -14,12 +14,9 @@ |
||
14 | 14 | |
15 | 15 | use Asylamba\Classes\Worker\CTR; |
16 | 16 | use Asylamba\Classes\Worker\ASM; |
17 | - |
|
18 | 17 | use Asylamba\Classes\Container\StackList; |
19 | - |
|
20 | 18 | use Asylamba\Modules\Promethee\Model\Technology; |
21 | 19 | use Asylamba\Modules\Demeter\Model\Law\Law; |
22 | - |
|
23 | 20 | use Asylamba\Modules\Demeter\Resource\ColorResource; |
24 | 21 | use Asylamba\Modules\Promethee\Resource\TechnologyResource; |
25 | 22 | use Asylamba\Modules\Demeter\Resource\LawResources; |
@@ -81,6 +81,9 @@ |
||
81 | 81 | } |
82 | 82 | } |
83 | 83 | |
84 | + /** |
|
85 | + * @param Election $newElection |
|
86 | + */ |
|
84 | 87 | public function add($newElection) { |
85 | 88 | $db = Database::getInstance(); |
86 | 89 |
@@ -210,6 +210,9 @@ |
||
210 | 210 | ASM::$pam->changeSession($_PAM1); |
211 | 211 | } |
212 | 212 | |
213 | + /** |
|
214 | + * @param string $date |
|
215 | + */ |
|
213 | 216 | private function ballot($date, $election) { |
214 | 217 | $_PAM_1 = ASM::$pam->getCurrentsession(); |
215 | 218 | ASM::$pam->newSession(FALSE); |