crafting checking reworked

This commit is contained in:
GameHerobrine 2025-05-12 23:10:14 +03:00
parent cba572ece6
commit 8b77b88e84
4 changed files with 129 additions and 202 deletions

View file

@ -341,6 +341,16 @@ class BlockAPI{
return $output;
}
public static function blockIDFromString($str){
if(defined(strtoupper($str))){
$ida = explode(":", constant(strtoupper($str)));
if(count($ida) === 2){}
return (int) $ida[0];
}else if(is_numeric($str)){
return (int) $str;
}
}
public static function fromString($str, $multiple = false){
if($multiple === true){
$blocks = [];