Ejemplo n.º 1
0
 function __construct()
 {
     self::$main_timer = new \HRTime\StopWatch();
     self::$main_timer->start();
     // Activate to test what your system's HPET is actually using.
     // For now, we assume 1ns timing
     echo self::$main_timer->getFrequency() . "</br>";
     $baseplayer = new BasePlayer();
     $baseplayer->test_inventory();
 }
Ejemplo n.º 2
0
 public function save(Doctrine_Connection $conn = null)
 {
     if (!$this->getToken()) {
         $this->setToken(sha1($this->getEmail() . rand(11111, 99999)));
     }
     return parent::save($conn);
 }
Ejemplo n.º 3
0
 /**
  * Returns a peer instance associated with this om.
  *
  * Since Peer classes are not to have any instance attributes, this method returns the
  * same instance for all member of this class. The method could therefore
  * be static, but this would prevent one from overriding the behavior.
  *
  * @return PlayerPeer
  */
 public function getPeer()
 {
     if (self::$peer === null) {
         self::$peer = new PlayerPeer();
     }
     return self::$peer;
 }
Ejemplo n.º 4
0
 public static function model($className = __CLASS__)
 {
     return parent::model($className);
 }
Ejemplo n.º 5
0
 function Player($object = null)
 {
     parent::__construct($object);
 }