Exemplo n.º 1
0
 function __construct($prerequisites, \DnDEngine\Character $char)
 {
     parent::__construct(L::singleton()->t('Prerequisites not met for %s, requires %s.', array($char->getName(), $prerequisites)));
 }
Exemplo n.º 2
0
Arquivo: Base.php Projeto: Berdir/dnd
 /**
  * Short description for function
  *
  * Long description (if any) ...
  *
  * @return unknown Return description (if any) ...
  * @access public
  */
 public function getName()
 {
     return L::singleton()->t($this->name);
 }
Exemplo n.º 3
0
Arquivo: Base.php Projeto: Berdir/dnd
 /**
  * Short description for function
  *
  * Long description (if any) ...
  *
  * @return unknown Return description (if any) ...
  * @access public
  */
 public function getName()
 {
     return L::singleton()->t(static::Name);
 }
Exemplo n.º 4
0
 /**
  * Short description for function
  *
  * Long description (if any) ...
  *
  * @return string Return description (if any) ...
  * @access public
  */
 public function getPrerequisites()
 {
     return L::singleton()->t('15 Strength');
 }
Exemplo n.º 5
0
    /**
     * Short description for function
     *
     * Long description (if any) ...
     *
     * @return mixed  Return description (if any) ...
     * @access public
     */
    public function dump()
    {
        return Language::singleton()->t(' ==== Dumping Character Information: ===
     	
Name : %s
Race : %s
Class: %s

Hitpoints: %s/%s

Speed   : %s
Vision  : %s
Size    : %s
     
Ability Score: 
%s', array($this->getName(), $this->getRace()->getName(), $this->getClass()->getName(), $this->getHitPoints(), $this->getMaxHitPoints(), $this->getSpeed(), $this->getVision(), $this->getSize(), $this->getAbilities()));
    }
Exemplo n.º 6
0
 /**
  * Short description for function
  *
  * Long description (if any) ...
  *
  * @return string Return description (if any) ...
  * @access public
  */
 public function getPrerequisites()
 {
     return Language::singleton()->t('Human');
 }
Exemplo n.º 7
0
 /**
  * Short description for function
  *
  * Long description (if any) ...
  *
  * @param  unknown $message Parameter description (if any) ...
  * @param  unknown $level   Parameter description (if any) ...
  * @return boolean Return description (if any) ...
  * @access public
  */
 public function log($message, $level)
 {
     if (!$this->isEnabled($level)) {
         return false;
     }
     $levelText = Language::singleton()->t(Logger::getText($level));
     foreach (explode("\n", $message) as $line) {
         echo date('d.m.Y H:i:s:' . (int) (round(microtime(), 4) * 1000) . ' : ') . $levelText . ' : ' . trim($line) . "\n";
     }
 }
Exemplo n.º 8
0
 /**
  * Short description for function
  *
  * Long description (if any) ...
  *
  * @param  unknown $message    Parameter description (if any) ...
  * @param  integer $level      Parameter description (if any) ...
  * @param  array   $paramaters Parameter description (if any) ...
  * @return void
  * @access public
  * @static
  */
 public static function log($message, $level = self::INFO, $paramaters = array())
 {
     $message = Language::singleton()->t($message, $paramaters);
     foreach (self::$listeners as $listener) {
         $listener->log($message, $level);
     }
 }