Conditions | 1 |
Paths | 1 |
Total Lines | 25 |
Code Lines | 16 |
Lines | 0 |
Ratio | 0 % |
Tests | 0 |
CRAP Score | 2 |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
24 | public function setTemplateVariables( |
||
25 | PlanetFieldHostInterface $host, |
||
26 | GameControllerInterface $game |
||
27 | ): void { |
||
28 | $user = $game->getUser(); |
||
29 | |||
30 | $game->setTemplateVar( |
||
31 | 'CREW_COUNT_DEBRIS_AND_TRADE_POSTS', |
||
32 | $this->crewCountRetriever->getDebrisAndTradePostsCount($user) |
||
33 | ); |
||
34 | $game->setTemplateVar( |
||
35 | 'CREW_COUNT_SHIPS', |
||
36 | $this->crewCountRetriever->getAssignedToShipsCount($user) |
||
37 | ); |
||
38 | $game->setTemplateVar( |
||
39 | 'CREW_COUNT_TRAINING', |
||
40 | $this->crewCountRetriever->getInTrainingCount($user) |
||
41 | ); |
||
42 | $game->setTemplateVar( |
||
43 | 'CREW_COUNT_REMAINING', |
||
44 | $this->crewCountRetriever->getRemainingCount($user) |
||
45 | ); |
||
46 | $game->setTemplateVar( |
||
47 | 'GLOBAL_CREW_LIMIT', |
||
48 | $this->crewLimitCalculator->getGlobalCrewLimit($user) |
||
49 | ); |
||
52 |