26    use GetTypeIdFromConstTrait;
 
   28    public const ID = ItemStackRequestActionType::BEACON_PAYMENT;
 
   30    public function __construct(
 
   31        private int $primaryEffectId,
 
   32        private int $secondaryEffectId
 
   35    public function getPrimaryEffectId() : 
int{ 
return $this->primaryEffectId; }
 
   37    public function getSecondaryEffectId() : 
int{ 
return $this->secondaryEffectId; }
 
   39    public static function read(ByteBufferReader $in) : 
self{
 
   40        $primary = VarInt::readSignedInt($in);
 
   41        $secondary = VarInt::readSignedInt($in);
 
   42        return new self($primary, $secondary);
 
   45    public function write(ByteBufferWriter $out) : 
void{
 
   46        VarInt::writeSignedInt($out, $this->primaryEffectId);
 
   47        VarInt::writeSignedInt($out, $this->secondaryEffectId);