示例#1
0
 public function disambiguate(Metadatable $level, $metadataKey)
 {
     if (!$level instanceof Level) {
         throw new \InvalidArgumentException("Argument must be a Level instance");
     }
     return strtolower($level->getName()) . ":" . $metadataKey;
 }
 public function disambiguate(Metadatable $player, $metadataKey)
 {
     if (!$player instanceof IPlayer) {
         throw new \InvalidArgumentException("Argument must be an IPlayer instance");
     }
     return \strtolower($player->getName()) . ":" . $metadataKey;
 }
 public function disambiguate(Metadatable $entity, $metadataKey)
 {
     if (!$entity instanceof Entity) {
         throw new \InvalidArgumentException("Argument must be an Entity instance");
     }
     return $entity->getID() . ":" . $metadataKey;
 }