/** * Event "Hook" function * return false will stop any further action * @param self $self * @param $pkeys */ public function afterUpdateEvent($self, $pkeys) { // check if rally point mail should be send if ($self->newRallyPointSet && $self->rallyPoke) { $self->sendRallyPointMail(); } }
/** * save a system to this map * @param SystemModel $system * @param int $posX * @param int $posY * @param null|CharacterModel $character * @return mixed */ public function saveSystem(SystemModel $system, $posX = 10, $posY = 0, $character = null) { $system->setActive(true); $system->mapId = $this->id; $system->posX = $posX; $system->posY = $posY; $system->createdCharacterId = $character; $system->updatedCharacterId = $character; return $system->save(); }