@@ -76,12+70,12 @@ class Shipyard extends BaseConstruction {
}
// Create a shipyard, first we need to create a harbor
}
// Create a shipyard, first we need to create a harbor
- public final static function createShipyard (Harbor $harborInstance, $shipyardName) {
+ public static final function createShipyard (Harbor $harborInstance, $shipyardName) {
// Instanz temporaer holen
$shipyardInstance = new Shipyard();
// Debug message
// Instanz temporaer holen
$shipyardInstance = new Shipyard();
// Debug message
- if ((defined('DEBUG_SHIPYARD')) || (defined('DEBUG_ALL'))) $shipyardInstance->getDebugInstance()->output(sprintf("[%s:%d] Eine Werft mit dem Namen <strong>%s</strong> wird im Hafen <strong>%s</strong> konstruiert.<br />\n",
+ if ((defined('DEBUG_SHIPYARD')) || (defined('DEBUG_ALL'))) $shipyardInstance->debugOutput(sprintf("[%s:%d] Eine Werft mit dem Namen <strong>%s</strong> wird im Hafen <strong>%s</strong> konstruiert.",
__CLASS__,
__LINE__,
$shipyardName,
__CLASS__,
__LINE__,
$shipyardName,
@@ -101,10+95,9 @@ class Shipyard extends BaseConstruction {
// Clean up a little
$shipyardInstance->removeDraught();
// Clean up a little
$shipyardInstance->removeDraught();
- $shipyardInstance->removeSystemArray();
// Debug-Meldung
// Debug-Meldung
- if ((defined('DEBUG_SHIPYARD')) || (defined('DEBUG_ALL'))) $shipyardInstance->getDebugInstance()->output(sprintf("[%s:%d] Die Werft <strong>%s</strong> wurde gebaut.<br />\n",
+ if ((defined('DEBUG_SHIPYARD')) || (defined('DEBUG_ALL'))) $shipyardInstance->debugOutput(sprintf("[%s:%d] Die Werft <strong>%s</strong> wurde gebaut.",
__CLASS__,
__LINE__,
$shipyardName
__CLASS__,
__LINE__,
$shipyardName
@@ -116,21+109,11 @@ class Shipyard extends BaseConstruction {
// Create staff list
private function createStaffList () {
// Create staff list
private function createStaffList () {
- if ((defined('DEBUG_SHIPYARD')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:%d] Die Werft <strong>%s</strong> erhält eine Arbeiterliste.<br />\n",
- __CLASS__,
- __LINE__,
- $this->getShipyardName()
- ));
$this->staffList = new FrameworkArrayObject("FakedStaffList");
}
// Create ship type list
private function createShipTypeList () {
$this->staffList = new FrameworkArrayObject("FakedStaffList");
}
// Create ship type list
private function createShipTypeList () {
- if ((defined('DEBUG_SHIPYARD')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:%d] Die Werft <strong>%s</strong> erhält eine Typenliste.<br />\n",
- __CLASS__,
- __LINE__,
- $this->getShipyardName()
- ));
$this->shipTypeList = new FrameworkArrayObject("FakedShipTypeList");
}
$this->shipTypeList = new FrameworkArrayObject("FakedShipTypeList");
}
@@ -176,7+159,7 @@ class Shipyard extends BaseConstruction {
$shipType = (string) $shipType;
// Debug message
$shipType = (string) $shipType;
// Debug message
- if ((defined('DEBUG_SHIPYARD')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:%d] Die Werft <strong>%s</strong> kann bald Schiffe vom Typ <strong>%s</strong> bauen.<br />\n",
+ if ((defined('DEBUG_SHIPYARD')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Werft <strong>%s</strong> kann bald Schiffe vom Typ <strong>%s</strong> bauen.",
__CLASS__,
__LINE__,
$this->getShipyardName(),
__CLASS__,
__LINE__,
$this->getShipyardName(),
@@ -196,7+179,7 @@ class Shipyard extends BaseConstruction {
$shipType = (string) $shipType;
// Debug message
$shipType = (string) $shipType;
// Debug message
- if ((defined('DEBUG_SHIPYARD')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:%d] Die Werft <strong>%s</strong> prüft, ob Schiffe vom Typ <strong>%s</strong> baubar sind.<br />\n",
+ if ((defined('DEBUG_SHIPYARD')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Werft <strong>%s</strong> prüft, ob Schiffe vom Typ <strong>%s</strong> baubar sind.",
__CLASS__,
__LINE__,
$this->getShipyardName(),
__CLASS__,
__LINE__,
$this->getShipyardName(),
@@ -216,7+199,7 @@ class Shipyard extends BaseConstruction {
}
// Debug message
}
// Debug message
- if ((defined('DEBUG_SHIPYARD')) || (defined('DEBUG_ALL'))) $this->getDebugInstance()->output(sprintf("[%s:%d] Die Werft <strong>%s</strong> hat die Suche nach dem Schiffstyp <strong>%s</strong> abgeschlossen.<br />\n",
+ if ((defined('DEBUG_SHIPYARD')) || (defined('DEBUG_ALL'))) $this->debugOutput(sprintf("[%s:%d] Die Werft <strong>%s</strong> hat die Suche nach dem Schiffstyp <strong>%s</strong> abgeschlossen.",