20 use GetTypeIdFromConstTrait;
22 public const ID = GameRuleType::BOOL;
26 public function __construct(
bool $value,
bool $isPlayerModifiable){
27 parent::__construct($isPlayerModifiable);
28 $this->value = $value;
31 public function getValue() :
bool{
36 $out->putBool($this->value);
39 public static function decode(
PacketSerializer $in,
bool $isPlayerModifiable) :
self{
40 return new self($in->
getBool(), $isPlayerModifiable);