public static function getRGB($r, $g, $b) { return new Color((int) $r, (int) $g, (int) $b); }
public function getCustomColor() { // if ($this->isCustomColor()) { $color = $this->namedtag["CustomColor"]; $green = $color >> 8 & 0xff; $red = $color >> 16 & 0xff; $blue = $color & 0xff; return Color::getRGB($red, $green, $blue); } return null; }