mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-07-01 07:39:57 +00:00
Removed Vanilla*::fromString()
these were misbegotten and should never have existed. If someone really needs these for some reason, they can use getAll()[name].
This commit is contained in:
parent
f93b5be789
commit
a1ecdc27e5
@ -581,12 +581,6 @@ final class VanillaBlocks{
|
|||||||
self::_registryRegister($name, $block);
|
self::_registryRegister($name, $block);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static function fromString(string $name) : Block{
|
|
||||||
$result = self::_registryFromString($name);
|
|
||||||
assert($result instanceof Block);
|
|
||||||
return $result;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return Block[]
|
* @return Block[]
|
||||||
*/
|
*/
|
||||||
|
@ -109,10 +109,4 @@ final class VanillaEffects{
|
|||||||
$result = self::_registryGetAll();
|
$result = self::_registryGetAll();
|
||||||
return $result;
|
return $result;
|
||||||
}
|
}
|
||||||
|
|
||||||
public static function fromString(string $name) : Effect{
|
|
||||||
$result = self::_registryFromString($name);
|
|
||||||
assert($result instanceof Effect);
|
|
||||||
return $result;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
@ -381,12 +381,6 @@ final class VanillaItems{
|
|||||||
self::_registryRegister($name, $item);
|
self::_registryRegister($name, $item);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static function fromString(string $name) : Item{
|
|
||||||
$result = self::_registryFromString($name);
|
|
||||||
assert($result instanceof Item);
|
|
||||||
return $result;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return Item[]
|
* @return Item[]
|
||||||
*/
|
*/
|
||||||
|
@ -113,10 +113,4 @@ final class VanillaEnchantments{
|
|||||||
$result = self::_registryGetAll();
|
$result = self::_registryGetAll();
|
||||||
return $result;
|
return $result;
|
||||||
}
|
}
|
||||||
|
|
||||||
public static function fromString(string $name) : Enchantment{
|
|
||||||
/** @var Enchantment $result */
|
|
||||||
$result = self::_registryFromString($name);
|
|
||||||
return $result;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user