game = $game; $this->db = $game->getDBAccess(); $this->players = $game->getLib('beta5/player'); } public function getSender() { return 'Peacekeeper Headquarters'; } public function getSLink() { return ''; } public function getRecipient() { $name = $this->players->call('getName', $this->player); return utf8entities($name); } public function getRLink() { return ''; } public function getSubject() { switch ($this->data['msg_type']) { case 'W': return 'Your fleets have entered protected territory'; case 'D': return 'Your fleets will be destroyed'; case 'E': return 'You have been declared an ennemy of the Peacekeepers'; } return 'Huh? wrong message type'; } public function getReplyLink() { return ''; } public function getContents() { $planets = ""; ob_start(); switch ($this->data['msg_type']) { case 'W': ?> This is a warning from Peacekeeper Headquarters. Your fleets have entered Peacekeeper-protected territories. If you do not retreat before data['delay'])?>, we will be forced to take action.
This warning applies to the following planets:

Best regards,
Peacekeeper Commander Dapkor Your hostile actions will not go unpunished! The Peacekeepers will see to it that your fleets are destroyed on the following planets:

Regards,
Peacekeeper Commander Multair Your continued hostile behaviour has forced us to declare you an enemy of the Peacekeepers. Your fleets will be destroyed on sight whenever you enter protected territory, and we will not protect you if you need it.
In addition, your fleets will be destroyed on the following planets:

Sanctions against you will end at on %d/%m/%Y", $this->data['delay'])?>.
Peacekeeper Commander Hestaks db->query("SELECT planet, p_name FROM pkwarning_planet WHERE id = {$this->data['id']}"); $planets = array(); while ($r = dbFetchArray($q)) { array_push($planets, "" . utf8entities($r[1]) . ""); } return $planets; } } ?>