Fleets
extends BaseController
in package
Fleets Class
Table of Contents
- $objects : Objects
- Contains the whole set of objects by request
- $page : Page
- Contains the Page object
- $planet : array<string|int, mixed>
- Contains the current planet data
- $template : Template
- Contains the Template object
- $user : array<string|int, mixed>
- Contains the current user data
- $userLibrary : User
- Contains the User object
- __construct() : mixed
- Constructor
- index() : void
- Users land here
- loadLang() : void
- Load a language file using CI Library
- loadModel() : void
- Load the provided model, support a dir path
- getObjects() : array<string|int, mixed>
- Will be removed
- getPlanetData() : array<string|int, mixed>
- Will be removed
- getTemplate() : array<string|int, mixed>
- Will be removed
- getUserData() : array<string|int, mixed>
- Will be removed
- buildActionsBlock() : array<string|int, mixed>
- Build the actions block
- buildAmountBlock() : array<string|int, mixed>
- Build the amount of ships block including the ship type popup
- buildArrivalBlock() : array<string|int, mixed>
- Build the arrival time to the objective block
- buildBeginningBlock() : array<string|int, mixed>
- Build the fleet beginning coords block
- buildDepartureBlock() : array<string|int, mixed>
- Build the departure time from the beginning block
- buildFleetMovementsBlock() : array<string|int, mixed>
- Build the list of fleet movements currently taking place
- buildMissionBlock() : array<string|int, mixed>
- Build the mission block including the resources
- buildObjectiveBlock() : void
- Build the fleet objective coords block
- buildPage() : void
- Build the page
- buildReturnBlock() : array<string|int, mixed>
- Build the return time to the departure block
- doDeleteAction() : void
- Delete the fleet from the DB
- doEndAction() : void
- Update the fleet to simulate a mission completion
- doRestartAction() : void
- * Update the fleet to simulate a mission restart
- doReturnAction() : void
- Update the fleet to simulate a return
- runAction() : void
- Run an action
Properties
$objects
Contains the whole set of objects by request
protected
Objects
$objects
$page
Contains the Page object
protected
Page
$page
= null
$planet
Contains the current planet data
protected
array<string|int, mixed>
$planet
= []
$template
Contains the Template object
protected
Template
$template
= null
$user
Contains the current user data
protected
array<string|int, mixed>
$user
= []
$userLibrary
Contains the User object
protected
User
$userLibrary
= null
Methods
__construct()
Constructor
public
__construct() : mixed
Return values
mixed —index()
Users land here
public
index() : void
Return values
void —loadLang()
Load a language file using CI Library
public
loadLang(string|array<string|int, mixed> $language_file) : void
Parameters
- $language_file : string|array<string|int, mixed>
Return values
void —loadModel()
Load the provided model, support a dir path
public
loadModel(string $class) : void
Parameters
- $class : string
-
Mandatory field, if not will throw an exception
Tags
Return values
void —getObjects()
Will be removed
protected
getObjects() : array<string|int, mixed>
Tags
Return values
array<string|int, mixed> —getPlanetData()
Will be removed
protected
getPlanetData() : array<string|int, mixed>
Tags
Return values
array<string|int, mixed> —getTemplate()
Will be removed
protected
getTemplate() : array<string|int, mixed>
Tags
Return values
array<string|int, mixed> —getUserData()
Will be removed
protected
getUserData() : array<string|int, mixed>
Tags
Return values
array<string|int, mixed> —buildActionsBlock()
Build the actions block
private
buildActionsBlock(array<string|int, mixed> $fleet) : array<string|int, mixed>
Parameters
- $fleet : array<string|int, mixed>
Return values
array<string|int, mixed> —buildAmountBlock()
Build the amount of ships block including the ship type popup
private
buildAmountBlock(array<string|int, mixed> $fleet) : array<string|int, mixed>
Parameters
- $fleet : array<string|int, mixed>
Return values
array<string|int, mixed> —buildArrivalBlock()
Build the arrival time to the objective block
private
buildArrivalBlock(array<string|int, mixed> $fleet) : array<string|int, mixed>
Parameters
- $fleet : array<string|int, mixed>
Return values
array<string|int, mixed> —buildBeginningBlock()
Build the fleet beginning coords block
private
buildBeginningBlock(array<string|int, mixed> $fleet) : array<string|int, mixed>
Parameters
- $fleet : array<string|int, mixed>
Return values
array<string|int, mixed> —buildDepartureBlock()
Build the departure time from the beginning block
private
buildDepartureBlock(array<string|int, mixed> $fleet) : array<string|int, mixed>
Parameters
- $fleet : array<string|int, mixed>
Return values
array<string|int, mixed> —buildFleetMovementsBlock()
Build the list of fleet movements currently taking place
private
buildFleetMovementsBlock() : array<string|int, mixed>
Return values
array<string|int, mixed> —buildMissionBlock()
Build the mission block including the resources
private
buildMissionBlock(array<string|int, mixed> $fleet) : array<string|int, mixed>
Parameters
- $fleet : array<string|int, mixed>
Return values
array<string|int, mixed> —buildObjectiveBlock()
Build the fleet objective coords block
private
buildObjectiveBlock(array<string|int, mixed> $fleet) : void
Parameters
- $fleet : array<string|int, mixed>
Return values
void —buildPage()
Build the page
private
buildPage() : void
Return values
void —buildReturnBlock()
Build the return time to the departure block
private
buildReturnBlock(array<string|int, mixed> $fleet) : array<string|int, mixed>
Parameters
- $fleet : array<string|int, mixed>
Return values
array<string|int, mixed> —doDeleteAction()
Delete the fleet from the DB
private
doDeleteAction(int $fleet_id) : void
Parameters
- $fleet_id : int
Return values
void —doEndAction()
Update the fleet to simulate a mission completion
private
doEndAction(int $fleet_id) : void
Parameters
- $fleet_id : int
Return values
void —doRestartAction()
* Update the fleet to simulate a mission restart
private
doRestartAction(int $fleet_id) : void
Parameters
- $fleet_id : int
Return values
void —doReturnAction()
Update the fleet to simulate a return
private
doReturnAction(int $fleet_id) : void
Parameters
- $fleet_id : int
Return values
void —runAction()
Run an action
private
runAction() : void