21 public const NETWORK_ID = ProtocolInfo::GAME_TEST_REQUEST_PACKET;
23 public const ROTATION_0 = 0;
24 public const ROTATION_90 = 1;
25 public const ROTATION_180 = 2;
26 public const ROTATION_270 = 3;
28 private int $maxTestsPerBatch;
29 private int $repeatCount;
30 private int $rotation;
31 private bool $stopOnFailure;
33 private int $testsPerRow;
34 private string $testName;
40 int $maxTestsPerBatch,
49 $result->maxTestsPerBatch = $maxTestsPerBatch;
50 $result->repeatCount = $repeatCount;
51 $result->rotation = $rotation;
52 $result->stopOnFailure = $stopOnFailure;
53 $result->testPosition = $testPosition;
54 $result->testsPerRow = $testsPerRow;
55 $result->testName = $testName;
59 public function getMaxTestsPerBatch() : int{ return $this->maxTestsPerBatch; }
61 public function getRepeatCount() : int{ return $this->repeatCount; }
66 public function getRotation() : int{ return $this->rotation; }
68 public function isStopOnFailure() : bool{ return $this->stopOnFailure; }
70 public function getTestPosition() :
BlockPosition{ return $this->testPosition; }
72 public function getTestsPerRow() : int{ return $this->testsPerRow; }
74 public function getTestName() : string{ return $this->testName; }
77 $this->maxTestsPerBatch = $in->getVarInt();
79 $this->rotation = $in->
getByte();
80 $this->stopOnFailure = $in->
getBool();
87 $out->putVarInt($this->maxTestsPerBatch);
89 $out->putByte($this->rotation);
90 $out->putBool($this->stopOnFailure);
93 $out->putString($this->testName);
97 return $handler->handleGameTestRequest($this);
static create(int $maxTestsPerBatch, int $repeatCount, int $rotation, bool $stopOnFailure, BlockPosition $testPosition, int $testsPerRow, string $testName,)