1 /* 2 * This file was automatically generated by sel-utils and 3 * released under the MIT License. 4 * 5 * License: https://github.com/sel-project/sel-utils/blob/master/LICENSE 6 * Repository: https://github.com/sel-project/sel-utils 7 * Generated from https://github.com/sel-project/sel-utils/blob/master/xml/metadata/minecraft210.xml 8 */ 9 module sul.metadata.minecraft210; 10 11 import std.typecons : Tuple, tuple; 12 13 import sul.utils.buffer : Buffer; 14 import sul.utils.var; 15 16 static import sul.protocol.minecraft210.types; 17 18 alias Changed(T) = Tuple!(T, "value", bool, "changed"); 19 20 class Metadata { 21 22 private bool _cached = false; 23 private ubyte[] _cache; 24 25 private void delegate(Buffer) pure nothrow @safe[] _changed; 26 27 private byte _entityFlags; 28 private Changed!(uint) _air = tuple(cast(uint)300, false); 29 private Changed!(string) _nametag; 30 private Changed!(bool) _showNametag; 31 private Changed!(bool) _silent; 32 private Changed!(bool) _noGravity; 33 private Changed!(sul.protocol.minecraft210.types.Slot) _potion; 34 private Changed!(ulong) _spawnPosition; 35 private Changed!(float) _radius = tuple(cast(float)0.5, false); 36 private Changed!(uint) _color; 37 private Changed!(bool) _isSinglePoint; 38 private Changed!(uint) _particleId; 39 private Changed!(uint) _particleParameter1; 40 private Changed!(uint) _particleParameter2; 41 private Changed!(uint) _hookedEntity; 42 private Changed!(byte) _arrowFlags; 43 private Changed!(uint) _timeSinceLastHit; 44 private Changed!(uint) _forwardDirection = tuple(cast(uint)1, false); 45 private Changed!(float) _damageTaken = tuple(cast(float)0, false); 46 private Changed!(uint) _boatVariant; 47 private Changed!(bool) _rightPaddleTurning; 48 private Changed!(bool) _leftPaddleTurning; 49 private Changed!(sul.protocol.minecraft210.types.OptionalPosition) _beamTarget; 50 private Changed!(bool) _showBottom; 51 private Changed!(sul.protocol.minecraft210.types.Slot) _firework; 52 private Changed!(sul.protocol.minecraft210.types.Slot) _item; 53 private Changed!(uint) _rotation; 54 private Changed!(byte) _livingFlags; 55 private Changed!(float) _health = tuple(cast(float)1, false); 56 private Changed!(uint) _potionColor; 57 private Changed!(bool) _potionAmbient; 58 private Changed!(uint) _arrows; 59 private Changed!(float) _additionalHearts = tuple(cast(float)0, false); 60 private Changed!(uint) _score; 61 private Changed!(byte) _skinParts = tuple(cast(byte)0, false); 62 private Changed!(byte) _mainHand = tuple(cast(byte)1, false); 63 private Changed!(byte) _armorStandFlags; 64 private Changed!(Tuple!(float, "x", float, "y", float, "z")) _headRotation; 65 private Changed!(Tuple!(float, "x", float, "y", float, "z")) _bodyRotation; 66 private Changed!(Tuple!(float, "x", float, "y", float, "z")) _leftArmRotation; 67 private Changed!(Tuple!(float, "x", float, "y", float, "z")) _rightArmRotation; 68 private Changed!(Tuple!(float, "x", float, "y", float, "z")) _leftLegRotation; 69 private Changed!(Tuple!(float, "x", float, "y", float, "z")) _rightLegRotation; 70 private Changed!(byte) _instentientFlags; 71 private Changed!(byte) _hanging; 72 private Changed!(bool) _baby; 73 private Changed!(byte) _horseFlags; 74 private Changed!(uint) _horseType; 75 private Changed!(uint) _horseVariant; 76 private Changed!(sul.protocol.minecraft210.types.OptionalUuid) _ownerUuid; 77 private Changed!(uint) _horseArmor; 78 private Changed!(bool) _pigSaddled; 79 private Changed!(uint) _rabbitVariant; 80 private Changed!(bool) _standingUp; 81 private Changed!(byte) _sheepFlagsAndColor; 82 private Changed!(byte) _tameableFlags; 83 private Changed!(uint) _ocelotVariant; 84 private Changed!(float) _wolfHealth; 85 private Changed!(bool) _begging; 86 private Changed!(uint) _collarColor = tuple(cast(uint)14, false); 87 private Changed!(uint) _profession; 88 private Changed!(byte) _createdByPlayer; 89 private Changed!(byte) _snowmanFlags; 90 private Changed!(uint) _shulkerDirection; 91 private Changed!(sul.protocol.minecraft210.types.OptionalPosition) _shulkerAttachment; 92 private Changed!(byte) _shulkerShieldHeight; 93 private Changed!(byte) _blazeOnFire; 94 private Changed!(uint) _creeperState = tuple(cast(uint)-1, false); 95 private Changed!(bool) _charged; 96 private Changed!(bool) _ignited; 97 private Changed!(byte) _guardianFlags; 98 private Changed!(uint) _guardianTarget; 99 private Changed!(uint) _skeletonType; 100 private Changed!(bool) _swingingArms; 101 private Changed!(byte) _climbing; 102 private Changed!(uint) _centerHeadTarget; 103 private Changed!(uint) _leftHeadTarget; 104 private Changed!(uint) _rightHeadTarget; 105 private Changed!(uint) _invulnerableTime; 106 private Changed!(uint) _zombieType; 107 private Changed!(bool) _converting; 108 private Changed!(bool) _handsHeldUp; 109 private Changed!(uint) _carriedBlock; 110 private Changed!(bool) _screaming; 111 private Changed!(uint) _dragonPhase; 112 private Changed!(bool) _ghastAttacking; 113 private Changed!(uint) _slimeSize = tuple(cast(uint)1, false); 114 private Changed!(uint) _shakingPower; 115 private Changed!(uint) _shakingDirection; 116 private Changed!(float) _shakingMultiplier = tuple(cast(float)0, false); 117 private Changed!(uint) _minecartBlock; 118 private Changed!(uint) _minecartBlockPosition = tuple(cast(uint)6, false); 119 private Changed!(bool) _minecartCustomBlock; 120 private Changed!(bool) _furnacePowered; 121 private Changed!(string) _command; 122 private Changed!(string) _lastOutput; 123 private Changed!(uint) _fuseTime; 124 125 public pure nothrow @safe this() { 126 this.reset(); 127 } 128 129 public pure nothrow @safe void reset() { 130 this._changed = [ 131 &this.encodeEntityFlags, 132 ]; 133 } 134 135 public pure nothrow @property @safe @nogc byte entityFlags() { 136 return _entityFlags; 137 } 138 139 public pure nothrow @property @safe byte entityFlags(byte value) { 140 this._cached = false; 141 this._entityFlags = value; 142 return value; 143 } 144 145 public pure nothrow @safe encodeEntityFlags(Buffer buffer) { 146 with(buffer) { 147 writeBigEndianUbyte(0); 148 writeBigEndianUbyte(0); 149 writeBigEndianByte(this._entityFlags); 150 } 151 } 152 153 public pure nothrow @property @safe bool onFire() { 154 return (_entityFlags >>> 0) & 1; 155 } 156 157 public pure nothrow @property @safe bool onFire(bool value) { 158 if(value) entityFlags = cast(byte)(_entityFlags | (cast(byte)true << 0)); 159 else entityFlags = cast(byte)(_entityFlags & ~(cast(byte)true << 0)); 160 return value; 161 } 162 163 public pure nothrow @property @safe bool sneaking() { 164 return (_entityFlags >>> 1) & 1; 165 } 166 167 public pure nothrow @property @safe bool sneaking(bool value) { 168 if(value) entityFlags = cast(byte)(_entityFlags | (cast(byte)true << 1)); 169 else entityFlags = cast(byte)(_entityFlags & ~(cast(byte)true << 1)); 170 return value; 171 } 172 173 public pure nothrow @property @safe bool sprinting() { 174 return (_entityFlags >>> 3) & 1; 175 } 176 177 public pure nothrow @property @safe bool sprinting(bool value) { 178 if(value) entityFlags = cast(byte)(_entityFlags | (cast(byte)true << 3)); 179 else entityFlags = cast(byte)(_entityFlags & ~(cast(byte)true << 3)); 180 return value; 181 } 182 183 public pure nothrow @property @safe bool invisible() { 184 return (_entityFlags >>> 5) & 1; 185 } 186 187 public pure nothrow @property @safe bool invisible(bool value) { 188 if(value) entityFlags = cast(byte)(_entityFlags | (cast(byte)true << 5)); 189 else entityFlags = cast(byte)(_entityFlags & ~(cast(byte)true << 5)); 190 return value; 191 } 192 193 public pure nothrow @property @safe bool glowing() { 194 return (_entityFlags >>> 6) & 1; 195 } 196 197 public pure nothrow @property @safe bool glowing(bool value) { 198 if(value) entityFlags = cast(byte)(_entityFlags | (cast(byte)true << 6)); 199 else entityFlags = cast(byte)(_entityFlags & ~(cast(byte)true << 6)); 200 return value; 201 } 202 203 public pure nothrow @property @safe bool gliding() { 204 return (_entityFlags >>> 7) & 1; 205 } 206 207 public pure nothrow @property @safe bool gliding(bool value) { 208 if(value) entityFlags = cast(byte)(_entityFlags | (cast(byte)true << 7)); 209 else entityFlags = cast(byte)(_entityFlags & ~(cast(byte)true << 7)); 210 return value; 211 } 212 213 public pure nothrow @property @safe @nogc uint air() { 214 return _air.value; 215 } 216 217 public pure nothrow @property @safe uint air(uint value) { 218 this._cached = false; 219 this._air.value = value; 220 if(!this._air.changed) { 221 this._air.changed = true; 222 this._changed ~= &this.encodeAir; 223 } 224 return value; 225 } 226 227 public pure nothrow @safe encodeAir(Buffer buffer) { 228 with(buffer) { 229 writeBigEndianUbyte(1); 230 writeBigEndianUbyte(1); 231 writeBytes(varuint.encode(this._air.value)); 232 } 233 } 234 235 public pure nothrow @property @safe @nogc string nametag() { 236 return _nametag.value; 237 } 238 239 public pure nothrow @property @safe string nametag(string value) { 240 this._cached = false; 241 this._nametag.value = value; 242 if(!this._nametag.changed) { 243 this._nametag.changed = true; 244 this._changed ~= &this.encodeNametag; 245 } 246 return value; 247 } 248 249 public pure nothrow @safe encodeNametag(Buffer buffer) { 250 with(buffer) { 251 writeBigEndianUbyte(2); 252 writeBigEndianUbyte(3); 253 writeBytes(varuint.encode(cast(uint)this._nametag.value.length)); writeString(this._nametag.value); 254 } 255 } 256 257 public pure nothrow @property @safe @nogc bool showNametag() { 258 return _showNametag.value; 259 } 260 261 public pure nothrow @property @safe bool showNametag(bool value) { 262 this._cached = false; 263 this._showNametag.value = value; 264 if(!this._showNametag.changed) { 265 this._showNametag.changed = true; 266 this._changed ~= &this.encodeShowNametag; 267 } 268 return value; 269 } 270 271 public pure nothrow @safe encodeShowNametag(Buffer buffer) { 272 with(buffer) { 273 writeBigEndianUbyte(3); 274 writeBigEndianUbyte(6); 275 writeBigEndianBool(this._showNametag.value); 276 } 277 } 278 279 public pure nothrow @property @safe @nogc bool silent() { 280 return _silent.value; 281 } 282 283 public pure nothrow @property @safe bool silent(bool value) { 284 this._cached = false; 285 this._silent.value = value; 286 if(!this._silent.changed) { 287 this._silent.changed = true; 288 this._changed ~= &this.encodeSilent; 289 } 290 return value; 291 } 292 293 public pure nothrow @safe encodeSilent(Buffer buffer) { 294 with(buffer) { 295 writeBigEndianUbyte(4); 296 writeBigEndianUbyte(6); 297 writeBigEndianBool(this._silent.value); 298 } 299 } 300 301 public pure nothrow @property @safe @nogc bool noGravity() { 302 return _noGravity.value; 303 } 304 305 public pure nothrow @property @safe bool noGravity(bool value) { 306 this._cached = false; 307 this._noGravity.value = value; 308 if(!this._noGravity.changed) { 309 this._noGravity.changed = true; 310 this._changed ~= &this.encodeNoGravity; 311 } 312 return value; 313 } 314 315 public pure nothrow @safe encodeNoGravity(Buffer buffer) { 316 with(buffer) { 317 writeBigEndianUbyte(5); 318 writeBigEndianUbyte(6); 319 writeBigEndianBool(this._noGravity.value); 320 } 321 } 322 323 public pure nothrow @property @safe @nogc sul.protocol.minecraft210.types.Slot potion() { 324 return _potion.value; 325 } 326 327 public pure nothrow @property @safe sul.protocol.minecraft210.types.Slot potion(sul.protocol.minecraft210.types.Slot value) { 328 this._cached = false; 329 this._potion.value = value; 330 if(!this._potion.changed) { 331 this._potion.changed = true; 332 this._changed ~= &this.encodePotion; 333 } 334 return value; 335 } 336 337 public pure nothrow @safe encodePotion(Buffer buffer) { 338 with(buffer) { 339 writeBigEndianUbyte(6); 340 writeBigEndianUbyte(5); 341 this._potion.value.encode(bufferInstance); 342 } 343 } 344 345 public pure nothrow @property @safe @nogc ulong spawnPosition() { 346 return _spawnPosition.value; 347 } 348 349 public pure nothrow @property @safe ulong spawnPosition(ulong value) { 350 this._cached = false; 351 this._spawnPosition.value = value; 352 if(!this._spawnPosition.changed) { 353 this._spawnPosition.changed = true; 354 this._changed ~= &this.encodeSpawnPosition; 355 } 356 return value; 357 } 358 359 public pure nothrow @safe encodeSpawnPosition(Buffer buffer) { 360 with(buffer) { 361 writeBigEndianUbyte(6); 362 writeBigEndianUbyte(8); 363 writeBigEndianUlong(this._spawnPosition.value); 364 } 365 } 366 367 public pure nothrow @property @safe @nogc float radius() { 368 return _radius.value; 369 } 370 371 public pure nothrow @property @safe float radius(float value) { 372 this._cached = false; 373 this._radius.value = value; 374 if(!this._radius.changed) { 375 this._radius.changed = true; 376 this._changed ~= &this.encodeRadius; 377 } 378 return value; 379 } 380 381 public pure nothrow @safe encodeRadius(Buffer buffer) { 382 with(buffer) { 383 writeBigEndianUbyte(6); 384 writeBigEndianUbyte(2); 385 writeBigEndianFloat(this._radius.value); 386 } 387 } 388 389 public pure nothrow @property @safe @nogc uint color() { 390 return _color.value; 391 } 392 393 public pure nothrow @property @safe uint color(uint value) { 394 this._cached = false; 395 this._color.value = value; 396 if(!this._color.changed) { 397 this._color.changed = true; 398 this._changed ~= &this.encodeColor; 399 } 400 return value; 401 } 402 403 public pure nothrow @safe encodeColor(Buffer buffer) { 404 with(buffer) { 405 writeBigEndianUbyte(7); 406 writeBigEndianUbyte(1); 407 writeBytes(varuint.encode(this._color.value)); 408 } 409 } 410 411 public pure nothrow @property @safe @nogc bool isSinglePoint() { 412 return _isSinglePoint.value; 413 } 414 415 public pure nothrow @property @safe bool isSinglePoint(bool value) { 416 this._cached = false; 417 this._isSinglePoint.value = value; 418 if(!this._isSinglePoint.changed) { 419 this._isSinglePoint.changed = true; 420 this._changed ~= &this.encodeIsSinglePoint; 421 } 422 return value; 423 } 424 425 public pure nothrow @safe encodeIsSinglePoint(Buffer buffer) { 426 with(buffer) { 427 writeBigEndianUbyte(8); 428 writeBigEndianUbyte(6); 429 writeBigEndianBool(this._isSinglePoint.value); 430 } 431 } 432 433 public pure nothrow @property @safe @nogc uint particleId() { 434 return _particleId.value; 435 } 436 437 public pure nothrow @property @safe uint particleId(uint value) { 438 this._cached = false; 439 this._particleId.value = value; 440 if(!this._particleId.changed) { 441 this._particleId.changed = true; 442 this._changed ~= &this.encodeParticleId; 443 } 444 return value; 445 } 446 447 public pure nothrow @safe encodeParticleId(Buffer buffer) { 448 with(buffer) { 449 writeBigEndianUbyte(9); 450 writeBigEndianUbyte(1); 451 writeBytes(varuint.encode(this._particleId.value)); 452 } 453 } 454 455 public pure nothrow @property @safe @nogc uint particleParameter1() { 456 return _particleParameter1.value; 457 } 458 459 public pure nothrow @property @safe uint particleParameter1(uint value) { 460 this._cached = false; 461 this._particleParameter1.value = value; 462 if(!this._particleParameter1.changed) { 463 this._particleParameter1.changed = true; 464 this._changed ~= &this.encodeParticleParameter1; 465 } 466 return value; 467 } 468 469 public pure nothrow @safe encodeParticleParameter1(Buffer buffer) { 470 with(buffer) { 471 writeBigEndianUbyte(10); 472 writeBigEndianUbyte(1); 473 writeBytes(varuint.encode(this._particleParameter1.value)); 474 } 475 } 476 477 public pure nothrow @property @safe @nogc uint particleParameter2() { 478 return _particleParameter2.value; 479 } 480 481 public pure nothrow @property @safe uint particleParameter2(uint value) { 482 this._cached = false; 483 this._particleParameter2.value = value; 484 if(!this._particleParameter2.changed) { 485 this._particleParameter2.changed = true; 486 this._changed ~= &this.encodeParticleParameter2; 487 } 488 return value; 489 } 490 491 public pure nothrow @safe encodeParticleParameter2(Buffer buffer) { 492 with(buffer) { 493 writeBigEndianUbyte(11); 494 writeBigEndianUbyte(1); 495 writeBytes(varuint.encode(this._particleParameter2.value)); 496 } 497 } 498 499 public pure nothrow @property @safe @nogc uint hookedEntity() { 500 return _hookedEntity.value; 501 } 502 503 public pure nothrow @property @safe uint hookedEntity(uint value) { 504 this._cached = false; 505 this._hookedEntity.value = value; 506 if(!this._hookedEntity.changed) { 507 this._hookedEntity.changed = true; 508 this._changed ~= &this.encodeHookedEntity; 509 } 510 return value; 511 } 512 513 public pure nothrow @safe encodeHookedEntity(Buffer buffer) { 514 with(buffer) { 515 writeBigEndianUbyte(6); 516 writeBigEndianUbyte(1); 517 writeBytes(varuint.encode(this._hookedEntity.value)); 518 } 519 } 520 521 public pure nothrow @property @safe @nogc byte arrowFlags() { 522 return _arrowFlags.value; 523 } 524 525 public pure nothrow @property @safe byte arrowFlags(byte value) { 526 this._cached = false; 527 this._arrowFlags.value = value; 528 if(!this._arrowFlags.changed) { 529 this._arrowFlags.changed = true; 530 this._changed ~= &this.encodeArrowFlags; 531 } 532 return value; 533 } 534 535 public pure nothrow @safe encodeArrowFlags(Buffer buffer) { 536 with(buffer) { 537 writeBigEndianUbyte(6); 538 writeBigEndianUbyte(0); 539 writeBigEndianByte(this._arrowFlags.value); 540 } 541 } 542 543 public pure nothrow @property @safe bool critical() { 544 return (_arrowFlags.value >>> 0) & 1; 545 } 546 547 public pure nothrow @property @safe bool critical(bool value) { 548 if(value) arrowFlags = cast(byte)(_arrowFlags.value | (cast(byte)true << 0)); 549 else arrowFlags = cast(byte)(_arrowFlags.value & ~(cast(byte)true << 0)); 550 return value; 551 } 552 553 public pure nothrow @property @safe @nogc uint timeSinceLastHit() { 554 return _timeSinceLastHit.value; 555 } 556 557 public pure nothrow @property @safe uint timeSinceLastHit(uint value) { 558 this._cached = false; 559 this._timeSinceLastHit.value = value; 560 if(!this._timeSinceLastHit.changed) { 561 this._timeSinceLastHit.changed = true; 562 this._changed ~= &this.encodeTimeSinceLastHit; 563 } 564 return value; 565 } 566 567 public pure nothrow @safe encodeTimeSinceLastHit(Buffer buffer) { 568 with(buffer) { 569 writeBigEndianUbyte(6); 570 writeBigEndianUbyte(1); 571 writeBytes(varuint.encode(this._timeSinceLastHit.value)); 572 } 573 } 574 575 public pure nothrow @property @safe @nogc uint forwardDirection() { 576 return _forwardDirection.value; 577 } 578 579 public pure nothrow @property @safe uint forwardDirection(uint value) { 580 this._cached = false; 581 this._forwardDirection.value = value; 582 if(!this._forwardDirection.changed) { 583 this._forwardDirection.changed = true; 584 this._changed ~= &this.encodeForwardDirection; 585 } 586 return value; 587 } 588 589 public pure nothrow @safe encodeForwardDirection(Buffer buffer) { 590 with(buffer) { 591 writeBigEndianUbyte(7); 592 writeBigEndianUbyte(1); 593 writeBytes(varuint.encode(this._forwardDirection.value)); 594 } 595 } 596 597 public pure nothrow @property @safe @nogc float damageTaken() { 598 return _damageTaken.value; 599 } 600 601 public pure nothrow @property @safe float damageTaken(float value) { 602 this._cached = false; 603 this._damageTaken.value = value; 604 if(!this._damageTaken.changed) { 605 this._damageTaken.changed = true; 606 this._changed ~= &this.encodeDamageTaken; 607 } 608 return value; 609 } 610 611 public pure nothrow @safe encodeDamageTaken(Buffer buffer) { 612 with(buffer) { 613 writeBigEndianUbyte(8); 614 writeBigEndianUbyte(2); 615 writeBigEndianFloat(this._damageTaken.value); 616 } 617 } 618 619 public pure nothrow @property @safe @nogc uint boatVariant() { 620 return _boatVariant.value; 621 } 622 623 public pure nothrow @property @safe uint boatVariant(uint value) { 624 this._cached = false; 625 this._boatVariant.value = value; 626 if(!this._boatVariant.changed) { 627 this._boatVariant.changed = true; 628 this._changed ~= &this.encodeBoatVariant; 629 } 630 return value; 631 } 632 633 public pure nothrow @safe encodeBoatVariant(Buffer buffer) { 634 with(buffer) { 635 writeBigEndianUbyte(9); 636 writeBigEndianUbyte(1); 637 writeBytes(varuint.encode(this._boatVariant.value)); 638 } 639 } 640 641 public pure nothrow @property @safe @nogc bool rightPaddleTurning() { 642 return _rightPaddleTurning.value; 643 } 644 645 public pure nothrow @property @safe bool rightPaddleTurning(bool value) { 646 this._cached = false; 647 this._rightPaddleTurning.value = value; 648 if(!this._rightPaddleTurning.changed) { 649 this._rightPaddleTurning.changed = true; 650 this._changed ~= &this.encodeRightPaddleTurning; 651 } 652 return value; 653 } 654 655 public pure nothrow @safe encodeRightPaddleTurning(Buffer buffer) { 656 with(buffer) { 657 writeBigEndianUbyte(10); 658 writeBigEndianUbyte(6); 659 writeBigEndianBool(this._rightPaddleTurning.value); 660 } 661 } 662 663 public pure nothrow @property @safe @nogc bool leftPaddleTurning() { 664 return _leftPaddleTurning.value; 665 } 666 667 public pure nothrow @property @safe bool leftPaddleTurning(bool value) { 668 this._cached = false; 669 this._leftPaddleTurning.value = value; 670 if(!this._leftPaddleTurning.changed) { 671 this._leftPaddleTurning.changed = true; 672 this._changed ~= &this.encodeLeftPaddleTurning; 673 } 674 return value; 675 } 676 677 public pure nothrow @safe encodeLeftPaddleTurning(Buffer buffer) { 678 with(buffer) { 679 writeBigEndianUbyte(11); 680 writeBigEndianUbyte(6); 681 writeBigEndianBool(this._leftPaddleTurning.value); 682 } 683 } 684 685 public pure nothrow @property @safe @nogc sul.protocol.minecraft210.types.OptionalPosition beamTarget() { 686 return _beamTarget.value; 687 } 688 689 public pure nothrow @property @safe sul.protocol.minecraft210.types.OptionalPosition beamTarget(sul.protocol.minecraft210.types.OptionalPosition value) { 690 this._cached = false; 691 this._beamTarget.value = value; 692 if(!this._beamTarget.changed) { 693 this._beamTarget.changed = true; 694 this._changed ~= &this.encodeBeamTarget; 695 } 696 return value; 697 } 698 699 public pure nothrow @safe encodeBeamTarget(Buffer buffer) { 700 with(buffer) { 701 writeBigEndianUbyte(6); 702 writeBigEndianUbyte(9); 703 this._beamTarget.value.encode(bufferInstance); 704 } 705 } 706 707 public pure nothrow @property @safe @nogc bool showBottom() { 708 return _showBottom.value; 709 } 710 711 public pure nothrow @property @safe bool showBottom(bool value) { 712 this._cached = false; 713 this._showBottom.value = value; 714 if(!this._showBottom.changed) { 715 this._showBottom.changed = true; 716 this._changed ~= &this.encodeShowBottom; 717 } 718 return value; 719 } 720 721 public pure nothrow @safe encodeShowBottom(Buffer buffer) { 722 with(buffer) { 723 writeBigEndianUbyte(7); 724 writeBigEndianUbyte(6); 725 writeBigEndianBool(this._showBottom.value); 726 } 727 } 728 729 public pure nothrow @property @safe @nogc sul.protocol.minecraft210.types.Slot firework() { 730 return _firework.value; 731 } 732 733 public pure nothrow @property @safe sul.protocol.minecraft210.types.Slot firework(sul.protocol.minecraft210.types.Slot value) { 734 this._cached = false; 735 this._firework.value = value; 736 if(!this._firework.changed) { 737 this._firework.changed = true; 738 this._changed ~= &this.encodeFirework; 739 } 740 return value; 741 } 742 743 public pure nothrow @safe encodeFirework(Buffer buffer) { 744 with(buffer) { 745 writeBigEndianUbyte(6); 746 writeBigEndianUbyte(5); 747 this._firework.value.encode(bufferInstance); 748 } 749 } 750 751 public pure nothrow @property @safe @nogc sul.protocol.minecraft210.types.Slot item() { 752 return _item.value; 753 } 754 755 public pure nothrow @property @safe sul.protocol.minecraft210.types.Slot item(sul.protocol.minecraft210.types.Slot value) { 756 this._cached = false; 757 this._item.value = value; 758 if(!this._item.changed) { 759 this._item.changed = true; 760 this._changed ~= &this.encodeItem; 761 } 762 return value; 763 } 764 765 public pure nothrow @safe encodeItem(Buffer buffer) { 766 with(buffer) { 767 writeBigEndianUbyte(6); 768 writeBigEndianUbyte(5); 769 this._item.value.encode(bufferInstance); 770 } 771 } 772 773 public pure nothrow @property @safe @nogc uint rotation() { 774 return _rotation.value; 775 } 776 777 public pure nothrow @property @safe uint rotation(uint value) { 778 this._cached = false; 779 this._rotation.value = value; 780 if(!this._rotation.changed) { 781 this._rotation.changed = true; 782 this._changed ~= &this.encodeRotation; 783 } 784 return value; 785 } 786 787 public pure nothrow @safe encodeRotation(Buffer buffer) { 788 with(buffer) { 789 writeBigEndianUbyte(7); 790 writeBigEndianUbyte(1); 791 writeBytes(varuint.encode(this._rotation.value)); 792 } 793 } 794 795 public pure nothrow @property @safe @nogc byte livingFlags() { 796 return _livingFlags.value; 797 } 798 799 public pure nothrow @property @safe byte livingFlags(byte value) { 800 this._cached = false; 801 this._livingFlags.value = value; 802 if(!this._livingFlags.changed) { 803 this._livingFlags.changed = true; 804 this._changed ~= &this.encodeLivingFlags; 805 } 806 return value; 807 } 808 809 public pure nothrow @safe encodeLivingFlags(Buffer buffer) { 810 with(buffer) { 811 writeBigEndianUbyte(6); 812 writeBigEndianUbyte(0); 813 writeBigEndianByte(this._livingFlags.value); 814 } 815 } 816 817 public pure nothrow @property @safe bool handActive() { 818 return (_livingFlags.value >>> 0) & 1; 819 } 820 821 public pure nothrow @property @safe bool handActive(bool value) { 822 if(value) livingFlags = cast(byte)(_livingFlags.value | (cast(byte)true << 0)); 823 else livingFlags = cast(byte)(_livingFlags.value & ~(cast(byte)true << 0)); 824 return value; 825 } 826 827 public pure nothrow @property @safe bool offhand() { 828 return (_livingFlags.value >>> 1) & 1; 829 } 830 831 public pure nothrow @property @safe bool offhand(bool value) { 832 if(value) livingFlags = cast(byte)(_livingFlags.value | (cast(byte)true << 1)); 833 else livingFlags = cast(byte)(_livingFlags.value & ~(cast(byte)true << 1)); 834 return value; 835 } 836 837 public pure nothrow @property @safe @nogc float health() { 838 return _health.value; 839 } 840 841 public pure nothrow @property @safe float health(float value) { 842 this._cached = false; 843 this._health.value = value; 844 if(!this._health.changed) { 845 this._health.changed = true; 846 this._changed ~= &this.encodeHealth; 847 } 848 return value; 849 } 850 851 public pure nothrow @safe encodeHealth(Buffer buffer) { 852 with(buffer) { 853 writeBigEndianUbyte(7); 854 writeBigEndianUbyte(2); 855 writeBigEndianFloat(this._health.value); 856 } 857 } 858 859 public pure nothrow @property @safe @nogc uint potionColor() { 860 return _potionColor.value; 861 } 862 863 public pure nothrow @property @safe uint potionColor(uint value) { 864 this._cached = false; 865 this._potionColor.value = value; 866 if(!this._potionColor.changed) { 867 this._potionColor.changed = true; 868 this._changed ~= &this.encodePotionColor; 869 } 870 return value; 871 } 872 873 public pure nothrow @safe encodePotionColor(Buffer buffer) { 874 with(buffer) { 875 writeBigEndianUbyte(8); 876 writeBigEndianUbyte(1); 877 writeBytes(varuint.encode(this._potionColor.value)); 878 } 879 } 880 881 public pure nothrow @property @safe @nogc bool potionAmbient() { 882 return _potionAmbient.value; 883 } 884 885 public pure nothrow @property @safe bool potionAmbient(bool value) { 886 this._cached = false; 887 this._potionAmbient.value = value; 888 if(!this._potionAmbient.changed) { 889 this._potionAmbient.changed = true; 890 this._changed ~= &this.encodePotionAmbient; 891 } 892 return value; 893 } 894 895 public pure nothrow @safe encodePotionAmbient(Buffer buffer) { 896 with(buffer) { 897 writeBigEndianUbyte(9); 898 writeBigEndianUbyte(6); 899 writeBigEndianBool(this._potionAmbient.value); 900 } 901 } 902 903 public pure nothrow @property @safe @nogc uint arrows() { 904 return _arrows.value; 905 } 906 907 public pure nothrow @property @safe uint arrows(uint value) { 908 this._cached = false; 909 this._arrows.value = value; 910 if(!this._arrows.changed) { 911 this._arrows.changed = true; 912 this._changed ~= &this.encodeArrows; 913 } 914 return value; 915 } 916 917 public pure nothrow @safe encodeArrows(Buffer buffer) { 918 with(buffer) { 919 writeBigEndianUbyte(10); 920 writeBigEndianUbyte(1); 921 writeBytes(varuint.encode(this._arrows.value)); 922 } 923 } 924 925 public pure nothrow @property @safe @nogc float additionalHearts() { 926 return _additionalHearts.value; 927 } 928 929 public pure nothrow @property @safe float additionalHearts(float value) { 930 this._cached = false; 931 this._additionalHearts.value = value; 932 if(!this._additionalHearts.changed) { 933 this._additionalHearts.changed = true; 934 this._changed ~= &this.encodeAdditionalHearts; 935 } 936 return value; 937 } 938 939 public pure nothrow @safe encodeAdditionalHearts(Buffer buffer) { 940 with(buffer) { 941 writeBigEndianUbyte(11); 942 writeBigEndianUbyte(2); 943 writeBigEndianFloat(this._additionalHearts.value); 944 } 945 } 946 947 public pure nothrow @property @safe @nogc uint score() { 948 return _score.value; 949 } 950 951 public pure nothrow @property @safe uint score(uint value) { 952 this._cached = false; 953 this._score.value = value; 954 if(!this._score.changed) { 955 this._score.changed = true; 956 this._changed ~= &this.encodeScore; 957 } 958 return value; 959 } 960 961 public pure nothrow @safe encodeScore(Buffer buffer) { 962 with(buffer) { 963 writeBigEndianUbyte(12); 964 writeBigEndianUbyte(1); 965 writeBytes(varuint.encode(this._score.value)); 966 } 967 } 968 969 public pure nothrow @property @safe @nogc byte skinParts() { 970 return _skinParts.value; 971 } 972 973 public pure nothrow @property @safe byte skinParts(byte value) { 974 this._cached = false; 975 this._skinParts.value = value; 976 if(!this._skinParts.changed) { 977 this._skinParts.changed = true; 978 this._changed ~= &this.encodeSkinParts; 979 } 980 return value; 981 } 982 983 public pure nothrow @safe encodeSkinParts(Buffer buffer) { 984 with(buffer) { 985 writeBigEndianUbyte(13); 986 writeBigEndianUbyte(0); 987 writeBigEndianByte(this._skinParts.value); 988 } 989 } 990 991 public pure nothrow @property @safe bool cape() { 992 return (_skinParts.value >>> 0) & 1; 993 } 994 995 public pure nothrow @property @safe bool cape(bool value) { 996 if(value) skinParts = cast(byte)(_skinParts.value | (cast(byte)true << 0)); 997 else skinParts = cast(byte)(_skinParts.value & ~(cast(byte)true << 0)); 998 return value; 999 } 1000 1001 public pure nothrow @property @safe bool jacket() { 1002 return (_skinParts.value >>> 1) & 1; 1003 } 1004 1005 public pure nothrow @property @safe bool jacket(bool value) { 1006 if(value) skinParts = cast(byte)(_skinParts.value | (cast(byte)true << 1)); 1007 else skinParts = cast(byte)(_skinParts.value & ~(cast(byte)true << 1)); 1008 return value; 1009 } 1010 1011 public pure nothrow @property @safe bool leftSleeve() { 1012 return (_skinParts.value >>> 2) & 1; 1013 } 1014 1015 public pure nothrow @property @safe bool leftSleeve(bool value) { 1016 if(value) skinParts = cast(byte)(_skinParts.value | (cast(byte)true << 2)); 1017 else skinParts = cast(byte)(_skinParts.value & ~(cast(byte)true << 2)); 1018 return value; 1019 } 1020 1021 public pure nothrow @property @safe bool rightSleeve() { 1022 return (_skinParts.value >>> 3) & 1; 1023 } 1024 1025 public pure nothrow @property @safe bool rightSleeve(bool value) { 1026 if(value) skinParts = cast(byte)(_skinParts.value | (cast(byte)true << 3)); 1027 else skinParts = cast(byte)(_skinParts.value & ~(cast(byte)true << 3)); 1028 return value; 1029 } 1030 1031 public pure nothrow @property @safe bool leftPants() { 1032 return (_skinParts.value >>> 4) & 1; 1033 } 1034 1035 public pure nothrow @property @safe bool leftPants(bool value) { 1036 if(value) skinParts = cast(byte)(_skinParts.value | (cast(byte)true << 4)); 1037 else skinParts = cast(byte)(_skinParts.value & ~(cast(byte)true << 4)); 1038 return value; 1039 } 1040 1041 public pure nothrow @property @safe bool rightPants() { 1042 return (_skinParts.value >>> 5) & 1; 1043 } 1044 1045 public pure nothrow @property @safe bool rightPants(bool value) { 1046 if(value) skinParts = cast(byte)(_skinParts.value | (cast(byte)true << 5)); 1047 else skinParts = cast(byte)(_skinParts.value & ~(cast(byte)true << 5)); 1048 return value; 1049 } 1050 1051 public pure nothrow @property @safe bool hat() { 1052 return (_skinParts.value >>> 6) & 1; 1053 } 1054 1055 public pure nothrow @property @safe bool hat(bool value) { 1056 if(value) skinParts = cast(byte)(_skinParts.value | (cast(byte)true << 6)); 1057 else skinParts = cast(byte)(_skinParts.value & ~(cast(byte)true << 6)); 1058 return value; 1059 } 1060 1061 public pure nothrow @property @safe @nogc byte mainHand() { 1062 return _mainHand.value; 1063 } 1064 1065 public pure nothrow @property @safe byte mainHand(byte value) { 1066 this._cached = false; 1067 this._mainHand.value = value; 1068 if(!this._mainHand.changed) { 1069 this._mainHand.changed = true; 1070 this._changed ~= &this.encodeMainHand; 1071 } 1072 return value; 1073 } 1074 1075 public pure nothrow @safe encodeMainHand(Buffer buffer) { 1076 with(buffer) { 1077 writeBigEndianUbyte(14); 1078 writeBigEndianUbyte(0); 1079 writeBigEndianByte(this._mainHand.value); 1080 } 1081 } 1082 1083 public pure nothrow @property @safe @nogc byte armorStandFlags() { 1084 return _armorStandFlags.value; 1085 } 1086 1087 public pure nothrow @property @safe byte armorStandFlags(byte value) { 1088 this._cached = false; 1089 this._armorStandFlags.value = value; 1090 if(!this._armorStandFlags.changed) { 1091 this._armorStandFlags.changed = true; 1092 this._changed ~= &this.encodeArmorStandFlags; 1093 } 1094 return value; 1095 } 1096 1097 public pure nothrow @safe encodeArmorStandFlags(Buffer buffer) { 1098 with(buffer) { 1099 writeBigEndianUbyte(11); 1100 writeBigEndianUbyte(0); 1101 writeBigEndianByte(this._armorStandFlags.value); 1102 } 1103 } 1104 1105 public pure nothrow @property @safe bool isSmall() { 1106 return (_armorStandFlags.value >>> 0) & 1; 1107 } 1108 1109 public pure nothrow @property @safe bool isSmall(bool value) { 1110 if(value) armorStandFlags = cast(byte)(_armorStandFlags.value | (cast(byte)true << 0)); 1111 else armorStandFlags = cast(byte)(_armorStandFlags.value & ~(cast(byte)true << 0)); 1112 return value; 1113 } 1114 1115 public pure nothrow @property @safe bool hasArms() { 1116 return (_armorStandFlags.value >>> 2) & 1; 1117 } 1118 1119 public pure nothrow @property @safe bool hasArms(bool value) { 1120 if(value) armorStandFlags = cast(byte)(_armorStandFlags.value | (cast(byte)true << 2)); 1121 else armorStandFlags = cast(byte)(_armorStandFlags.value & ~(cast(byte)true << 2)); 1122 return value; 1123 } 1124 1125 public pure nothrow @property @safe bool noBasePlate() { 1126 return (_armorStandFlags.value >>> 3) & 1; 1127 } 1128 1129 public pure nothrow @property @safe bool noBasePlate(bool value) { 1130 if(value) armorStandFlags = cast(byte)(_armorStandFlags.value | (cast(byte)true << 3)); 1131 else armorStandFlags = cast(byte)(_armorStandFlags.value & ~(cast(byte)true << 3)); 1132 return value; 1133 } 1134 1135 public pure nothrow @property @safe bool setMarker() { 1136 return (_armorStandFlags.value >>> 4) & 1; 1137 } 1138 1139 public pure nothrow @property @safe bool setMarker(bool value) { 1140 if(value) armorStandFlags = cast(byte)(_armorStandFlags.value | (cast(byte)true << 4)); 1141 else armorStandFlags = cast(byte)(_armorStandFlags.value & ~(cast(byte)true << 4)); 1142 return value; 1143 } 1144 1145 public pure nothrow @property @safe @nogc Tuple!(float, "x", float, "y", float, "z") headRotation() { 1146 return _headRotation.value; 1147 } 1148 1149 public pure nothrow @property @safe Tuple!(float, "x", float, "y", float, "z") headRotation(Tuple!(float, "x", float, "y", float, "z") value) { 1150 this._cached = false; 1151 this._headRotation.value = value; 1152 if(!this._headRotation.changed) { 1153 this._headRotation.changed = true; 1154 this._changed ~= &this.encodeHeadRotation; 1155 } 1156 return value; 1157 } 1158 1159 public pure nothrow @safe encodeHeadRotation(Buffer buffer) { 1160 with(buffer) { 1161 writeBigEndianUbyte(12); 1162 writeBigEndianUbyte(7); 1163 writeBigEndianFloat(this._headRotation.value.x); writeBigEndianFloat(this._headRotation.value.y); writeBigEndianFloat(this._headRotation.value.z); 1164 } 1165 } 1166 1167 public pure nothrow @property @safe @nogc Tuple!(float, "x", float, "y", float, "z") bodyRotation() { 1168 return _bodyRotation.value; 1169 } 1170 1171 public pure nothrow @property @safe Tuple!(float, "x", float, "y", float, "z") bodyRotation(Tuple!(float, "x", float, "y", float, "z") value) { 1172 this._cached = false; 1173 this._bodyRotation.value = value; 1174 if(!this._bodyRotation.changed) { 1175 this._bodyRotation.changed = true; 1176 this._changed ~= &this.encodeBodyRotation; 1177 } 1178 return value; 1179 } 1180 1181 public pure nothrow @safe encodeBodyRotation(Buffer buffer) { 1182 with(buffer) { 1183 writeBigEndianUbyte(13); 1184 writeBigEndianUbyte(7); 1185 writeBigEndianFloat(this._bodyRotation.value.x); writeBigEndianFloat(this._bodyRotation.value.y); writeBigEndianFloat(this._bodyRotation.value.z); 1186 } 1187 } 1188 1189 public pure nothrow @property @safe @nogc Tuple!(float, "x", float, "y", float, "z") leftArmRotation() { 1190 return _leftArmRotation.value; 1191 } 1192 1193 public pure nothrow @property @safe Tuple!(float, "x", float, "y", float, "z") leftArmRotation(Tuple!(float, "x", float, "y", float, "z") value) { 1194 this._cached = false; 1195 this._leftArmRotation.value = value; 1196 if(!this._leftArmRotation.changed) { 1197 this._leftArmRotation.changed = true; 1198 this._changed ~= &this.encodeLeftArmRotation; 1199 } 1200 return value; 1201 } 1202 1203 public pure nothrow @safe encodeLeftArmRotation(Buffer buffer) { 1204 with(buffer) { 1205 writeBigEndianUbyte(14); 1206 writeBigEndianUbyte(7); 1207 writeBigEndianFloat(this._leftArmRotation.value.x); writeBigEndianFloat(this._leftArmRotation.value.y); writeBigEndianFloat(this._leftArmRotation.value.z); 1208 } 1209 } 1210 1211 public pure nothrow @property @safe @nogc Tuple!(float, "x", float, "y", float, "z") rightArmRotation() { 1212 return _rightArmRotation.value; 1213 } 1214 1215 public pure nothrow @property @safe Tuple!(float, "x", float, "y", float, "z") rightArmRotation(Tuple!(float, "x", float, "y", float, "z") value) { 1216 this._cached = false; 1217 this._rightArmRotation.value = value; 1218 if(!this._rightArmRotation.changed) { 1219 this._rightArmRotation.changed = true; 1220 this._changed ~= &this.encodeRightArmRotation; 1221 } 1222 return value; 1223 } 1224 1225 public pure nothrow @safe encodeRightArmRotation(Buffer buffer) { 1226 with(buffer) { 1227 writeBigEndianUbyte(15); 1228 writeBigEndianUbyte(7); 1229 writeBigEndianFloat(this._rightArmRotation.value.x); writeBigEndianFloat(this._rightArmRotation.value.y); writeBigEndianFloat(this._rightArmRotation.value.z); 1230 } 1231 } 1232 1233 public pure nothrow @property @safe @nogc Tuple!(float, "x", float, "y", float, "z") leftLegRotation() { 1234 return _leftLegRotation.value; 1235 } 1236 1237 public pure nothrow @property @safe Tuple!(float, "x", float, "y", float, "z") leftLegRotation(Tuple!(float, "x", float, "y", float, "z") value) { 1238 this._cached = false; 1239 this._leftLegRotation.value = value; 1240 if(!this._leftLegRotation.changed) { 1241 this._leftLegRotation.changed = true; 1242 this._changed ~= &this.encodeLeftLegRotation; 1243 } 1244 return value; 1245 } 1246 1247 public pure nothrow @safe encodeLeftLegRotation(Buffer buffer) { 1248 with(buffer) { 1249 writeBigEndianUbyte(16); 1250 writeBigEndianUbyte(7); 1251 writeBigEndianFloat(this._leftLegRotation.value.x); writeBigEndianFloat(this._leftLegRotation.value.y); writeBigEndianFloat(this._leftLegRotation.value.z); 1252 } 1253 } 1254 1255 public pure nothrow @property @safe @nogc Tuple!(float, "x", float, "y", float, "z") rightLegRotation() { 1256 return _rightLegRotation.value; 1257 } 1258 1259 public pure nothrow @property @safe Tuple!(float, "x", float, "y", float, "z") rightLegRotation(Tuple!(float, "x", float, "y", float, "z") value) { 1260 this._cached = false; 1261 this._rightLegRotation.value = value; 1262 if(!this._rightLegRotation.changed) { 1263 this._rightLegRotation.changed = true; 1264 this._changed ~= &this.encodeRightLegRotation; 1265 } 1266 return value; 1267 } 1268 1269 public pure nothrow @safe encodeRightLegRotation(Buffer buffer) { 1270 with(buffer) { 1271 writeBigEndianUbyte(17); 1272 writeBigEndianUbyte(7); 1273 writeBigEndianFloat(this._rightLegRotation.value.x); writeBigEndianFloat(this._rightLegRotation.value.y); writeBigEndianFloat(this._rightLegRotation.value.z); 1274 } 1275 } 1276 1277 public pure nothrow @property @safe @nogc byte instentientFlags() { 1278 return _instentientFlags.value; 1279 } 1280 1281 public pure nothrow @property @safe byte instentientFlags(byte value) { 1282 this._cached = false; 1283 this._instentientFlags.value = value; 1284 if(!this._instentientFlags.changed) { 1285 this._instentientFlags.changed = true; 1286 this._changed ~= &this.encodeInstentientFlags; 1287 } 1288 return value; 1289 } 1290 1291 public pure nothrow @safe encodeInstentientFlags(Buffer buffer) { 1292 with(buffer) { 1293 writeBigEndianUbyte(11); 1294 writeBigEndianUbyte(0); 1295 writeBigEndianByte(this._instentientFlags.value); 1296 } 1297 } 1298 1299 public pure nothrow @property @safe bool noAi() { 1300 return (_instentientFlags.value >>> 0) & 1; 1301 } 1302 1303 public pure nothrow @property @safe bool noAi(bool value) { 1304 if(value) instentientFlags = cast(byte)(_instentientFlags.value | (cast(byte)true << 0)); 1305 else instentientFlags = cast(byte)(_instentientFlags.value & ~(cast(byte)true << 0)); 1306 return value; 1307 } 1308 1309 public pure nothrow @property @safe bool leftHanded() { 1310 return (_instentientFlags.value >>> 1) & 1; 1311 } 1312 1313 public pure nothrow @property @safe bool leftHanded(bool value) { 1314 if(value) instentientFlags = cast(byte)(_instentientFlags.value | (cast(byte)true << 1)); 1315 else instentientFlags = cast(byte)(_instentientFlags.value & ~(cast(byte)true << 1)); 1316 return value; 1317 } 1318 1319 public pure nothrow @property @safe @nogc byte hanging() { 1320 return _hanging.value; 1321 } 1322 1323 public pure nothrow @property @safe byte hanging(byte value) { 1324 this._cached = false; 1325 this._hanging.value = value; 1326 if(!this._hanging.changed) { 1327 this._hanging.changed = true; 1328 this._changed ~= &this.encodeHanging; 1329 } 1330 return value; 1331 } 1332 1333 public pure nothrow @safe encodeHanging(Buffer buffer) { 1334 with(buffer) { 1335 writeBigEndianUbyte(12); 1336 writeBigEndianUbyte(0); 1337 writeBigEndianByte(this._hanging.value); 1338 } 1339 } 1340 1341 public pure nothrow @property @safe @nogc bool baby() { 1342 return _baby.value; 1343 } 1344 1345 public pure nothrow @property @safe bool baby(bool value) { 1346 this._cached = false; 1347 this._baby.value = value; 1348 if(!this._baby.changed) { 1349 this._baby.changed = true; 1350 this._changed ~= &this.encodeBaby; 1351 } 1352 return value; 1353 } 1354 1355 public pure nothrow @safe encodeBaby(Buffer buffer) { 1356 with(buffer) { 1357 writeBigEndianUbyte(12); 1358 writeBigEndianUbyte(6); 1359 writeBigEndianBool(this._baby.value); 1360 } 1361 } 1362 1363 public pure nothrow @property @safe @nogc byte horseFlags() { 1364 return _horseFlags.value; 1365 } 1366 1367 public pure nothrow @property @safe byte horseFlags(byte value) { 1368 this._cached = false; 1369 this._horseFlags.value = value; 1370 if(!this._horseFlags.changed) { 1371 this._horseFlags.changed = true; 1372 this._changed ~= &this.encodeHorseFlags; 1373 } 1374 return value; 1375 } 1376 1377 public pure nothrow @safe encodeHorseFlags(Buffer buffer) { 1378 with(buffer) { 1379 writeBigEndianUbyte(13); 1380 writeBigEndianUbyte(0); 1381 writeBigEndianByte(this._horseFlags.value); 1382 } 1383 } 1384 1385 public pure nothrow @property @safe bool horseTamed() { 1386 return (_horseFlags.value >>> 1) & 1; 1387 } 1388 1389 public pure nothrow @property @safe bool horseTamed(bool value) { 1390 if(value) horseFlags = cast(byte)(_horseFlags.value | (cast(byte)true << 1)); 1391 else horseFlags = cast(byte)(_horseFlags.value & ~(cast(byte)true << 1)); 1392 return value; 1393 } 1394 1395 public pure nothrow @property @safe bool horseSaddled() { 1396 return (_horseFlags.value >>> 2) & 1; 1397 } 1398 1399 public pure nothrow @property @safe bool horseSaddled(bool value) { 1400 if(value) horseFlags = cast(byte)(_horseFlags.value | (cast(byte)true << 2)); 1401 else horseFlags = cast(byte)(_horseFlags.value & ~(cast(byte)true << 2)); 1402 return value; 1403 } 1404 1405 public pure nothrow @property @safe bool horseChested() { 1406 return (_horseFlags.value >>> 3) & 1; 1407 } 1408 1409 public pure nothrow @property @safe bool horseChested(bool value) { 1410 if(value) horseFlags = cast(byte)(_horseFlags.value | (cast(byte)true << 3)); 1411 else horseFlags = cast(byte)(_horseFlags.value & ~(cast(byte)true << 3)); 1412 return value; 1413 } 1414 1415 public pure nothrow @property @safe bool horseEating() { 1416 return (_horseFlags.value >>> 5) & 1; 1417 } 1418 1419 public pure nothrow @property @safe bool horseEating(bool value) { 1420 if(value) horseFlags = cast(byte)(_horseFlags.value | (cast(byte)true << 5)); 1421 else horseFlags = cast(byte)(_horseFlags.value & ~(cast(byte)true << 5)); 1422 return value; 1423 } 1424 1425 public pure nothrow @property @safe bool horseRearing() { 1426 return (_horseFlags.value >>> 6) & 1; 1427 } 1428 1429 public pure nothrow @property @safe bool horseRearing(bool value) { 1430 if(value) horseFlags = cast(byte)(_horseFlags.value | (cast(byte)true << 6)); 1431 else horseFlags = cast(byte)(_horseFlags.value & ~(cast(byte)true << 6)); 1432 return value; 1433 } 1434 1435 public pure nothrow @property @safe bool mouthOpen() { 1436 return (_horseFlags.value >>> 7) & 1; 1437 } 1438 1439 public pure nothrow @property @safe bool mouthOpen(bool value) { 1440 if(value) horseFlags = cast(byte)(_horseFlags.value | (cast(byte)true << 7)); 1441 else horseFlags = cast(byte)(_horseFlags.value & ~(cast(byte)true << 7)); 1442 return value; 1443 } 1444 1445 public pure nothrow @property @safe @nogc uint horseType() { 1446 return _horseType.value; 1447 } 1448 1449 public pure nothrow @property @safe uint horseType(uint value) { 1450 this._cached = false; 1451 this._horseType.value = value; 1452 if(!this._horseType.changed) { 1453 this._horseType.changed = true; 1454 this._changed ~= &this.encodeHorseType; 1455 } 1456 return value; 1457 } 1458 1459 public pure nothrow @safe encodeHorseType(Buffer buffer) { 1460 with(buffer) { 1461 writeBigEndianUbyte(14); 1462 writeBigEndianUbyte(1); 1463 writeBytes(varuint.encode(this._horseType.value)); 1464 } 1465 } 1466 1467 public pure nothrow @property @safe @nogc uint horseVariant() { 1468 return _horseVariant.value; 1469 } 1470 1471 public pure nothrow @property @safe uint horseVariant(uint value) { 1472 this._cached = false; 1473 this._horseVariant.value = value; 1474 if(!this._horseVariant.changed) { 1475 this._horseVariant.changed = true; 1476 this._changed ~= &this.encodeHorseVariant; 1477 } 1478 return value; 1479 } 1480 1481 public pure nothrow @safe encodeHorseVariant(Buffer buffer) { 1482 with(buffer) { 1483 writeBigEndianUbyte(15); 1484 writeBigEndianUbyte(1); 1485 writeBytes(varuint.encode(this._horseVariant.value)); 1486 } 1487 } 1488 1489 public pure nothrow @property @safe @nogc sul.protocol.minecraft210.types.OptionalUuid ownerUuid() { 1490 return _ownerUuid.value; 1491 } 1492 1493 public pure nothrow @property @safe sul.protocol.minecraft210.types.OptionalUuid ownerUuid(sul.protocol.minecraft210.types.OptionalUuid value) { 1494 this._cached = false; 1495 this._ownerUuid.value = value; 1496 if(!this._ownerUuid.changed) { 1497 this._ownerUuid.changed = true; 1498 this._changed ~= &this.encodeOwnerUuid; 1499 } 1500 return value; 1501 } 1502 1503 public pure nothrow @safe encodeOwnerUuid(Buffer buffer) { 1504 with(buffer) { 1505 writeBigEndianUbyte(16); 1506 writeBigEndianUbyte(11); 1507 this._ownerUuid.value.encode(bufferInstance); 1508 } 1509 } 1510 1511 public pure nothrow @property @safe @nogc uint horseArmor() { 1512 return _horseArmor.value; 1513 } 1514 1515 public pure nothrow @property @safe uint horseArmor(uint value) { 1516 this._cached = false; 1517 this._horseArmor.value = value; 1518 if(!this._horseArmor.changed) { 1519 this._horseArmor.changed = true; 1520 this._changed ~= &this.encodeHorseArmor; 1521 } 1522 return value; 1523 } 1524 1525 public pure nothrow @safe encodeHorseArmor(Buffer buffer) { 1526 with(buffer) { 1527 writeBigEndianUbyte(17); 1528 writeBigEndianUbyte(1); 1529 writeBytes(varuint.encode(this._horseArmor.value)); 1530 } 1531 } 1532 1533 public pure nothrow @property @safe @nogc bool pigSaddled() { 1534 return _pigSaddled.value; 1535 } 1536 1537 public pure nothrow @property @safe bool pigSaddled(bool value) { 1538 this._cached = false; 1539 this._pigSaddled.value = value; 1540 if(!this._pigSaddled.changed) { 1541 this._pigSaddled.changed = true; 1542 this._changed ~= &this.encodePigSaddled; 1543 } 1544 return value; 1545 } 1546 1547 public pure nothrow @safe encodePigSaddled(Buffer buffer) { 1548 with(buffer) { 1549 writeBigEndianUbyte(13); 1550 writeBigEndianUbyte(6); 1551 writeBigEndianBool(this._pigSaddled.value); 1552 } 1553 } 1554 1555 public pure nothrow @property @safe @nogc uint rabbitVariant() { 1556 return _rabbitVariant.value; 1557 } 1558 1559 public pure nothrow @property @safe uint rabbitVariant(uint value) { 1560 this._cached = false; 1561 this._rabbitVariant.value = value; 1562 if(!this._rabbitVariant.changed) { 1563 this._rabbitVariant.changed = true; 1564 this._changed ~= &this.encodeRabbitVariant; 1565 } 1566 return value; 1567 } 1568 1569 public pure nothrow @safe encodeRabbitVariant(Buffer buffer) { 1570 with(buffer) { 1571 writeBigEndianUbyte(13); 1572 writeBigEndianUbyte(1); 1573 writeBytes(varuint.encode(this._rabbitVariant.value)); 1574 } 1575 } 1576 1577 public pure nothrow @property @safe @nogc bool standingUp() { 1578 return _standingUp.value; 1579 } 1580 1581 public pure nothrow @property @safe bool standingUp(bool value) { 1582 this._cached = false; 1583 this._standingUp.value = value; 1584 if(!this._standingUp.changed) { 1585 this._standingUp.changed = true; 1586 this._changed ~= &this.encodeStandingUp; 1587 } 1588 return value; 1589 } 1590 1591 public pure nothrow @safe encodeStandingUp(Buffer buffer) { 1592 with(buffer) { 1593 writeBigEndianUbyte(13); 1594 writeBigEndianUbyte(6); 1595 writeBigEndianBool(this._standingUp.value); 1596 } 1597 } 1598 1599 public pure nothrow @property @safe @nogc byte sheepFlagsAndColor() { 1600 return _sheepFlagsAndColor.value; 1601 } 1602 1603 public pure nothrow @property @safe byte sheepFlagsAndColor(byte value) { 1604 this._cached = false; 1605 this._sheepFlagsAndColor.value = value; 1606 if(!this._sheepFlagsAndColor.changed) { 1607 this._sheepFlagsAndColor.changed = true; 1608 this._changed ~= &this.encodeSheepFlagsAndColor; 1609 } 1610 return value; 1611 } 1612 1613 public pure nothrow @safe encodeSheepFlagsAndColor(Buffer buffer) { 1614 with(buffer) { 1615 writeBigEndianUbyte(13); 1616 writeBigEndianUbyte(0); 1617 writeBigEndianByte(this._sheepFlagsAndColor.value); 1618 } 1619 } 1620 1621 public pure nothrow @property @safe bool sheared() { 1622 return (_sheepFlagsAndColor.value >>> 7) & 1; 1623 } 1624 1625 public pure nothrow @property @safe bool sheared(bool value) { 1626 if(value) sheepFlagsAndColor = cast(byte)(_sheepFlagsAndColor.value | (cast(byte)true << 7)); 1627 else sheepFlagsAndColor = cast(byte)(_sheepFlagsAndColor.value & ~(cast(byte)true << 7)); 1628 return value; 1629 } 1630 1631 public pure nothrow @property @safe @nogc byte tameableFlags() { 1632 return _tameableFlags.value; 1633 } 1634 1635 public pure nothrow @property @safe byte tameableFlags(byte value) { 1636 this._cached = false; 1637 this._tameableFlags.value = value; 1638 if(!this._tameableFlags.changed) { 1639 this._tameableFlags.changed = true; 1640 this._changed ~= &this.encodeTameableFlags; 1641 } 1642 return value; 1643 } 1644 1645 public pure nothrow @safe encodeTameableFlags(Buffer buffer) { 1646 with(buffer) { 1647 writeBigEndianUbyte(13); 1648 writeBigEndianUbyte(0); 1649 writeBigEndianByte(this._tameableFlags.value); 1650 } 1651 } 1652 1653 public pure nothrow @property @safe bool sitting() { 1654 return (_tameableFlags.value >>> 0) & 1; 1655 } 1656 1657 public pure nothrow @property @safe bool sitting(bool value) { 1658 if(value) tameableFlags = cast(byte)(_tameableFlags.value | (cast(byte)true << 0)); 1659 else tameableFlags = cast(byte)(_tameableFlags.value & ~(cast(byte)true << 0)); 1660 return value; 1661 } 1662 1663 public pure nothrow @property @safe bool angry() { 1664 return (_tameableFlags.value >>> 1) & 1; 1665 } 1666 1667 public pure nothrow @property @safe bool angry(bool value) { 1668 if(value) tameableFlags = cast(byte)(_tameableFlags.value | (cast(byte)true << 1)); 1669 else tameableFlags = cast(byte)(_tameableFlags.value & ~(cast(byte)true << 1)); 1670 return value; 1671 } 1672 1673 public pure nothrow @property @safe bool tamed() { 1674 return (_tameableFlags.value >>> 2) & 1; 1675 } 1676 1677 public pure nothrow @property @safe bool tamed(bool value) { 1678 if(value) tameableFlags = cast(byte)(_tameableFlags.value | (cast(byte)true << 2)); 1679 else tameableFlags = cast(byte)(_tameableFlags.value & ~(cast(byte)true << 2)); 1680 return value; 1681 } 1682 1683 public pure nothrow @property @safe @nogc uint ocelotVariant() { 1684 return _ocelotVariant.value; 1685 } 1686 1687 public pure nothrow @property @safe uint ocelotVariant(uint value) { 1688 this._cached = false; 1689 this._ocelotVariant.value = value; 1690 if(!this._ocelotVariant.changed) { 1691 this._ocelotVariant.changed = true; 1692 this._changed ~= &this.encodeOcelotVariant; 1693 } 1694 return value; 1695 } 1696 1697 public pure nothrow @safe encodeOcelotVariant(Buffer buffer) { 1698 with(buffer) { 1699 writeBigEndianUbyte(15); 1700 writeBigEndianUbyte(1); 1701 writeBytes(varuint.encode(this._ocelotVariant.value)); 1702 } 1703 } 1704 1705 public pure nothrow @property @safe @nogc float wolfHealth() { 1706 return _wolfHealth.value; 1707 } 1708 1709 public pure nothrow @property @safe float wolfHealth(float value) { 1710 this._cached = false; 1711 this._wolfHealth.value = value; 1712 if(!this._wolfHealth.changed) { 1713 this._wolfHealth.changed = true; 1714 this._changed ~= &this.encodeWolfHealth; 1715 } 1716 return value; 1717 } 1718 1719 public pure nothrow @safe encodeWolfHealth(Buffer buffer) { 1720 with(buffer) { 1721 writeBigEndianUbyte(15); 1722 writeBigEndianUbyte(2); 1723 writeBigEndianFloat(this._wolfHealth.value); 1724 } 1725 } 1726 1727 public pure nothrow @property @safe @nogc bool begging() { 1728 return _begging.value; 1729 } 1730 1731 public pure nothrow @property @safe bool begging(bool value) { 1732 this._cached = false; 1733 this._begging.value = value; 1734 if(!this._begging.changed) { 1735 this._begging.changed = true; 1736 this._changed ~= &this.encodeBegging; 1737 } 1738 return value; 1739 } 1740 1741 public pure nothrow @safe encodeBegging(Buffer buffer) { 1742 with(buffer) { 1743 writeBigEndianUbyte(16); 1744 writeBigEndianUbyte(6); 1745 writeBigEndianBool(this._begging.value); 1746 } 1747 } 1748 1749 public pure nothrow @property @safe @nogc uint collarColor() { 1750 return _collarColor.value; 1751 } 1752 1753 public pure nothrow @property @safe uint collarColor(uint value) { 1754 this._cached = false; 1755 this._collarColor.value = value; 1756 if(!this._collarColor.changed) { 1757 this._collarColor.changed = true; 1758 this._changed ~= &this.encodeCollarColor; 1759 } 1760 return value; 1761 } 1762 1763 public pure nothrow @safe encodeCollarColor(Buffer buffer) { 1764 with(buffer) { 1765 writeBigEndianUbyte(17); 1766 writeBigEndianUbyte(1); 1767 writeBytes(varuint.encode(this._collarColor.value)); 1768 } 1769 } 1770 1771 public pure nothrow @property @safe @nogc uint profession() { 1772 return _profession.value; 1773 } 1774 1775 public pure nothrow @property @safe uint profession(uint value) { 1776 this._cached = false; 1777 this._profession.value = value; 1778 if(!this._profession.changed) { 1779 this._profession.changed = true; 1780 this._changed ~= &this.encodeProfession; 1781 } 1782 return value; 1783 } 1784 1785 public pure nothrow @safe encodeProfession(Buffer buffer) { 1786 with(buffer) { 1787 writeBigEndianUbyte(13); 1788 writeBigEndianUbyte(1); 1789 writeBytes(varuint.encode(this._profession.value)); 1790 } 1791 } 1792 1793 public pure nothrow @property @safe @nogc byte createdByPlayer() { 1794 return _createdByPlayer.value; 1795 } 1796 1797 public pure nothrow @property @safe byte createdByPlayer(byte value) { 1798 this._cached = false; 1799 this._createdByPlayer.value = value; 1800 if(!this._createdByPlayer.changed) { 1801 this._createdByPlayer.changed = true; 1802 this._changed ~= &this.encodeCreatedByPlayer; 1803 } 1804 return value; 1805 } 1806 1807 public pure nothrow @safe encodeCreatedByPlayer(Buffer buffer) { 1808 with(buffer) { 1809 writeBigEndianUbyte(12); 1810 writeBigEndianUbyte(0); 1811 writeBigEndianByte(this._createdByPlayer.value); 1812 } 1813 } 1814 1815 public pure nothrow @property @safe @nogc byte snowmanFlags() { 1816 return _snowmanFlags.value; 1817 } 1818 1819 public pure nothrow @property @safe byte snowmanFlags(byte value) { 1820 this._cached = false; 1821 this._snowmanFlags.value = value; 1822 if(!this._snowmanFlags.changed) { 1823 this._snowmanFlags.changed = true; 1824 this._changed ~= &this.encodeSnowmanFlags; 1825 } 1826 return value; 1827 } 1828 1829 public pure nothrow @safe encodeSnowmanFlags(Buffer buffer) { 1830 with(buffer) { 1831 writeBigEndianUbyte(12); 1832 writeBigEndianUbyte(0); 1833 writeBigEndianByte(this._snowmanFlags.value); 1834 } 1835 } 1836 1837 public pure nothrow @property @safe bool pumpkinless() { 1838 return (_snowmanFlags.value >>> 4) & 1; 1839 } 1840 1841 public pure nothrow @property @safe bool pumpkinless(bool value) { 1842 if(value) snowmanFlags = cast(byte)(_snowmanFlags.value | (cast(byte)true << 4)); 1843 else snowmanFlags = cast(byte)(_snowmanFlags.value & ~(cast(byte)true << 4)); 1844 return value; 1845 } 1846 1847 public pure nothrow @property @safe @nogc uint shulkerDirection() { 1848 return _shulkerDirection.value; 1849 } 1850 1851 public pure nothrow @property @safe uint shulkerDirection(uint value) { 1852 this._cached = false; 1853 this._shulkerDirection.value = value; 1854 if(!this._shulkerDirection.changed) { 1855 this._shulkerDirection.changed = true; 1856 this._changed ~= &this.encodeShulkerDirection; 1857 } 1858 return value; 1859 } 1860 1861 public pure nothrow @safe encodeShulkerDirection(Buffer buffer) { 1862 with(buffer) { 1863 writeBigEndianUbyte(12); 1864 writeBigEndianUbyte(10); 1865 writeBytes(varuint.encode(this._shulkerDirection.value)); 1866 } 1867 } 1868 1869 public pure nothrow @property @safe @nogc sul.protocol.minecraft210.types.OptionalPosition shulkerAttachment() { 1870 return _shulkerAttachment.value; 1871 } 1872 1873 public pure nothrow @property @safe sul.protocol.minecraft210.types.OptionalPosition shulkerAttachment(sul.protocol.minecraft210.types.OptionalPosition value) { 1874 this._cached = false; 1875 this._shulkerAttachment.value = value; 1876 if(!this._shulkerAttachment.changed) { 1877 this._shulkerAttachment.changed = true; 1878 this._changed ~= &this.encodeShulkerAttachment; 1879 } 1880 return value; 1881 } 1882 1883 public pure nothrow @safe encodeShulkerAttachment(Buffer buffer) { 1884 with(buffer) { 1885 writeBigEndianUbyte(13); 1886 writeBigEndianUbyte(9); 1887 this._shulkerAttachment.value.encode(bufferInstance); 1888 } 1889 } 1890 1891 public pure nothrow @property @safe @nogc byte shulkerShieldHeight() { 1892 return _shulkerShieldHeight.value; 1893 } 1894 1895 public pure nothrow @property @safe byte shulkerShieldHeight(byte value) { 1896 this._cached = false; 1897 this._shulkerShieldHeight.value = value; 1898 if(!this._shulkerShieldHeight.changed) { 1899 this._shulkerShieldHeight.changed = true; 1900 this._changed ~= &this.encodeShulkerShieldHeight; 1901 } 1902 return value; 1903 } 1904 1905 public pure nothrow @safe encodeShulkerShieldHeight(Buffer buffer) { 1906 with(buffer) { 1907 writeBigEndianUbyte(14); 1908 writeBigEndianUbyte(0); 1909 writeBigEndianByte(this._shulkerShieldHeight.value); 1910 } 1911 } 1912 1913 public pure nothrow @property @safe @nogc byte blazeOnFire() { 1914 return _blazeOnFire.value; 1915 } 1916 1917 public pure nothrow @property @safe byte blazeOnFire(byte value) { 1918 this._cached = false; 1919 this._blazeOnFire.value = value; 1920 if(!this._blazeOnFire.changed) { 1921 this._blazeOnFire.changed = true; 1922 this._changed ~= &this.encodeBlazeOnFire; 1923 } 1924 return value; 1925 } 1926 1927 public pure nothrow @safe encodeBlazeOnFire(Buffer buffer) { 1928 with(buffer) { 1929 writeBigEndianUbyte(12); 1930 writeBigEndianUbyte(0); 1931 writeBigEndianByte(this._blazeOnFire.value); 1932 } 1933 } 1934 1935 public pure nothrow @property @safe @nogc uint creeperState() { 1936 return _creeperState.value; 1937 } 1938 1939 public pure nothrow @property @safe uint creeperState(uint value) { 1940 this._cached = false; 1941 this._creeperState.value = value; 1942 if(!this._creeperState.changed) { 1943 this._creeperState.changed = true; 1944 this._changed ~= &this.encodeCreeperState; 1945 } 1946 return value; 1947 } 1948 1949 public pure nothrow @safe encodeCreeperState(Buffer buffer) { 1950 with(buffer) { 1951 writeBigEndianUbyte(12); 1952 writeBigEndianUbyte(1); 1953 writeBytes(varuint.encode(this._creeperState.value)); 1954 } 1955 } 1956 1957 public pure nothrow @property @safe @nogc bool charged() { 1958 return _charged.value; 1959 } 1960 1961 public pure nothrow @property @safe bool charged(bool value) { 1962 this._cached = false; 1963 this._charged.value = value; 1964 if(!this._charged.changed) { 1965 this._charged.changed = true; 1966 this._changed ~= &this.encodeCharged; 1967 } 1968 return value; 1969 } 1970 1971 public pure nothrow @safe encodeCharged(Buffer buffer) { 1972 with(buffer) { 1973 writeBigEndianUbyte(13); 1974 writeBigEndianUbyte(6); 1975 writeBigEndianBool(this._charged.value); 1976 } 1977 } 1978 1979 public pure nothrow @property @safe @nogc bool ignited() { 1980 return _ignited.value; 1981 } 1982 1983 public pure nothrow @property @safe bool ignited(bool value) { 1984 this._cached = false; 1985 this._ignited.value = value; 1986 if(!this._ignited.changed) { 1987 this._ignited.changed = true; 1988 this._changed ~= &this.encodeIgnited; 1989 } 1990 return value; 1991 } 1992 1993 public pure nothrow @safe encodeIgnited(Buffer buffer) { 1994 with(buffer) { 1995 writeBigEndianUbyte(14); 1996 writeBigEndianUbyte(6); 1997 writeBigEndianBool(this._ignited.value); 1998 } 1999 } 2000 2001 public pure nothrow @property @safe @nogc byte guardianFlags() { 2002 return _guardianFlags.value; 2003 } 2004 2005 public pure nothrow @property @safe byte guardianFlags(byte value) { 2006 this._cached = false; 2007 this._guardianFlags.value = value; 2008 if(!this._guardianFlags.changed) { 2009 this._guardianFlags.changed = true; 2010 this._changed ~= &this.encodeGuardianFlags; 2011 } 2012 return value; 2013 } 2014 2015 public pure nothrow @safe encodeGuardianFlags(Buffer buffer) { 2016 with(buffer) { 2017 writeBigEndianUbyte(12); 2018 writeBigEndianUbyte(0); 2019 writeBigEndianByte(this._guardianFlags.value); 2020 } 2021 } 2022 2023 public pure nothrow @property @safe bool retractingSpikes() { 2024 return (_guardianFlags.value >>> 1) & 1; 2025 } 2026 2027 public pure nothrow @property @safe bool retractingSpikes(bool value) { 2028 if(value) guardianFlags = cast(byte)(_guardianFlags.value | (cast(byte)true << 1)); 2029 else guardianFlags = cast(byte)(_guardianFlags.value & ~(cast(byte)true << 1)); 2030 return value; 2031 } 2032 2033 public pure nothrow @property @safe bool elder() { 2034 return (_guardianFlags.value >>> 2) & 1; 2035 } 2036 2037 public pure nothrow @property @safe bool elder(bool value) { 2038 if(value) guardianFlags = cast(byte)(_guardianFlags.value | (cast(byte)true << 2)); 2039 else guardianFlags = cast(byte)(_guardianFlags.value & ~(cast(byte)true << 2)); 2040 return value; 2041 } 2042 2043 public pure nothrow @property @safe @nogc uint guardianTarget() { 2044 return _guardianTarget.value; 2045 } 2046 2047 public pure nothrow @property @safe uint guardianTarget(uint value) { 2048 this._cached = false; 2049 this._guardianTarget.value = value; 2050 if(!this._guardianTarget.changed) { 2051 this._guardianTarget.changed = true; 2052 this._changed ~= &this.encodeGuardianTarget; 2053 } 2054 return value; 2055 } 2056 2057 public pure nothrow @safe encodeGuardianTarget(Buffer buffer) { 2058 with(buffer) { 2059 writeBigEndianUbyte(13); 2060 writeBigEndianUbyte(1); 2061 writeBytes(varuint.encode(this._guardianTarget.value)); 2062 } 2063 } 2064 2065 public pure nothrow @property @safe @nogc uint skeletonType() { 2066 return _skeletonType.value; 2067 } 2068 2069 public pure nothrow @property @safe uint skeletonType(uint value) { 2070 this._cached = false; 2071 this._skeletonType.value = value; 2072 if(!this._skeletonType.changed) { 2073 this._skeletonType.changed = true; 2074 this._changed ~= &this.encodeSkeletonType; 2075 } 2076 return value; 2077 } 2078 2079 public pure nothrow @safe encodeSkeletonType(Buffer buffer) { 2080 with(buffer) { 2081 writeBigEndianUbyte(12); 2082 writeBigEndianUbyte(1); 2083 writeBytes(varuint.encode(this._skeletonType.value)); 2084 } 2085 } 2086 2087 public pure nothrow @property @safe @nogc bool swingingArms() { 2088 return _swingingArms.value; 2089 } 2090 2091 public pure nothrow @property @safe bool swingingArms(bool value) { 2092 this._cached = false; 2093 this._swingingArms.value = value; 2094 if(!this._swingingArms.changed) { 2095 this._swingingArms.changed = true; 2096 this._changed ~= &this.encodeSwingingArms; 2097 } 2098 return value; 2099 } 2100 2101 public pure nothrow @safe encodeSwingingArms(Buffer buffer) { 2102 with(buffer) { 2103 writeBigEndianUbyte(13); 2104 writeBigEndianUbyte(6); 2105 writeBigEndianBool(this._swingingArms.value); 2106 } 2107 } 2108 2109 public pure nothrow @property @safe @nogc byte climbing() { 2110 return _climbing.value; 2111 } 2112 2113 public pure nothrow @property @safe byte climbing(byte value) { 2114 this._cached = false; 2115 this._climbing.value = value; 2116 if(!this._climbing.changed) { 2117 this._climbing.changed = true; 2118 this._changed ~= &this.encodeClimbing; 2119 } 2120 return value; 2121 } 2122 2123 public pure nothrow @safe encodeClimbing(Buffer buffer) { 2124 with(buffer) { 2125 writeBigEndianUbyte(12); 2126 writeBigEndianUbyte(0); 2127 writeBigEndianByte(this._climbing.value); 2128 } 2129 } 2130 2131 public pure nothrow @property @safe @nogc uint centerHeadTarget() { 2132 return _centerHeadTarget.value; 2133 } 2134 2135 public pure nothrow @property @safe uint centerHeadTarget(uint value) { 2136 this._cached = false; 2137 this._centerHeadTarget.value = value; 2138 if(!this._centerHeadTarget.changed) { 2139 this._centerHeadTarget.changed = true; 2140 this._changed ~= &this.encodeCenterHeadTarget; 2141 } 2142 return value; 2143 } 2144 2145 public pure nothrow @safe encodeCenterHeadTarget(Buffer buffer) { 2146 with(buffer) { 2147 writeBigEndianUbyte(12); 2148 writeBigEndianUbyte(1); 2149 writeBytes(varuint.encode(this._centerHeadTarget.value)); 2150 } 2151 } 2152 2153 public pure nothrow @property @safe @nogc uint leftHeadTarget() { 2154 return _leftHeadTarget.value; 2155 } 2156 2157 public pure nothrow @property @safe uint leftHeadTarget(uint value) { 2158 this._cached = false; 2159 this._leftHeadTarget.value = value; 2160 if(!this._leftHeadTarget.changed) { 2161 this._leftHeadTarget.changed = true; 2162 this._changed ~= &this.encodeLeftHeadTarget; 2163 } 2164 return value; 2165 } 2166 2167 public pure nothrow @safe encodeLeftHeadTarget(Buffer buffer) { 2168 with(buffer) { 2169 writeBigEndianUbyte(13); 2170 writeBigEndianUbyte(1); 2171 writeBytes(varuint.encode(this._leftHeadTarget.value)); 2172 } 2173 } 2174 2175 public pure nothrow @property @safe @nogc uint rightHeadTarget() { 2176 return _rightHeadTarget.value; 2177 } 2178 2179 public pure nothrow @property @safe uint rightHeadTarget(uint value) { 2180 this._cached = false; 2181 this._rightHeadTarget.value = value; 2182 if(!this._rightHeadTarget.changed) { 2183 this._rightHeadTarget.changed = true; 2184 this._changed ~= &this.encodeRightHeadTarget; 2185 } 2186 return value; 2187 } 2188 2189 public pure nothrow @safe encodeRightHeadTarget(Buffer buffer) { 2190 with(buffer) { 2191 writeBigEndianUbyte(14); 2192 writeBigEndianUbyte(1); 2193 writeBytes(varuint.encode(this._rightHeadTarget.value)); 2194 } 2195 } 2196 2197 public pure nothrow @property @safe @nogc uint invulnerableTime() { 2198 return _invulnerableTime.value; 2199 } 2200 2201 public pure nothrow @property @safe uint invulnerableTime(uint value) { 2202 this._cached = false; 2203 this._invulnerableTime.value = value; 2204 if(!this._invulnerableTime.changed) { 2205 this._invulnerableTime.changed = true; 2206 this._changed ~= &this.encodeInvulnerableTime; 2207 } 2208 return value; 2209 } 2210 2211 public pure nothrow @safe encodeInvulnerableTime(Buffer buffer) { 2212 with(buffer) { 2213 writeBigEndianUbyte(15); 2214 writeBigEndianUbyte(1); 2215 writeBytes(varuint.encode(this._invulnerableTime.value)); 2216 } 2217 } 2218 2219 public pure nothrow @property @safe @nogc uint zombieType() { 2220 return _zombieType.value; 2221 } 2222 2223 public pure nothrow @property @safe uint zombieType(uint value) { 2224 this._cached = false; 2225 this._zombieType.value = value; 2226 if(!this._zombieType.changed) { 2227 this._zombieType.changed = true; 2228 this._changed ~= &this.encodeZombieType; 2229 } 2230 return value; 2231 } 2232 2233 public pure nothrow @safe encodeZombieType(Buffer buffer) { 2234 with(buffer) { 2235 writeBigEndianUbyte(13); 2236 writeBigEndianUbyte(1); 2237 writeBytes(varuint.encode(this._zombieType.value)); 2238 } 2239 } 2240 2241 public pure nothrow @property @safe @nogc bool converting() { 2242 return _converting.value; 2243 } 2244 2245 public pure nothrow @property @safe bool converting(bool value) { 2246 this._cached = false; 2247 this._converting.value = value; 2248 if(!this._converting.changed) { 2249 this._converting.changed = true; 2250 this._changed ~= &this.encodeConverting; 2251 } 2252 return value; 2253 } 2254 2255 public pure nothrow @safe encodeConverting(Buffer buffer) { 2256 with(buffer) { 2257 writeBigEndianUbyte(14); 2258 writeBigEndianUbyte(6); 2259 writeBigEndianBool(this._converting.value); 2260 } 2261 } 2262 2263 public pure nothrow @property @safe @nogc bool handsHeldUp() { 2264 return _handsHeldUp.value; 2265 } 2266 2267 public pure nothrow @property @safe bool handsHeldUp(bool value) { 2268 this._cached = false; 2269 this._handsHeldUp.value = value; 2270 if(!this._handsHeldUp.changed) { 2271 this._handsHeldUp.changed = true; 2272 this._changed ~= &this.encodeHandsHeldUp; 2273 } 2274 return value; 2275 } 2276 2277 public pure nothrow @safe encodeHandsHeldUp(Buffer buffer) { 2278 with(buffer) { 2279 writeBigEndianUbyte(15); 2280 writeBigEndianUbyte(6); 2281 writeBigEndianBool(this._handsHeldUp.value); 2282 } 2283 } 2284 2285 public pure nothrow @property @safe @nogc uint carriedBlock() { 2286 return _carriedBlock.value; 2287 } 2288 2289 public pure nothrow @property @safe uint carriedBlock(uint value) { 2290 this._cached = false; 2291 this._carriedBlock.value = value; 2292 if(!this._carriedBlock.changed) { 2293 this._carriedBlock.changed = true; 2294 this._changed ~= &this.encodeCarriedBlock; 2295 } 2296 return value; 2297 } 2298 2299 public pure nothrow @safe encodeCarriedBlock(Buffer buffer) { 2300 with(buffer) { 2301 writeBigEndianUbyte(12); 2302 writeBigEndianUbyte(12); 2303 writeBytes(varuint.encode(this._carriedBlock.value)); 2304 } 2305 } 2306 2307 public pure nothrow @property @safe @nogc bool screaming() { 2308 return _screaming.value; 2309 } 2310 2311 public pure nothrow @property @safe bool screaming(bool value) { 2312 this._cached = false; 2313 this._screaming.value = value; 2314 if(!this._screaming.changed) { 2315 this._screaming.changed = true; 2316 this._changed ~= &this.encodeScreaming; 2317 } 2318 return value; 2319 } 2320 2321 public pure nothrow @safe encodeScreaming(Buffer buffer) { 2322 with(buffer) { 2323 writeBigEndianUbyte(13); 2324 writeBigEndianUbyte(6); 2325 writeBigEndianBool(this._screaming.value); 2326 } 2327 } 2328 2329 public pure nothrow @property @safe @nogc uint dragonPhase() { 2330 return _dragonPhase.value; 2331 } 2332 2333 public pure nothrow @property @safe uint dragonPhase(uint value) { 2334 this._cached = false; 2335 this._dragonPhase.value = value; 2336 if(!this._dragonPhase.changed) { 2337 this._dragonPhase.changed = true; 2338 this._changed ~= &this.encodeDragonPhase; 2339 } 2340 return value; 2341 } 2342 2343 public pure nothrow @safe encodeDragonPhase(Buffer buffer) { 2344 with(buffer) { 2345 writeBigEndianUbyte(12); 2346 writeBigEndianUbyte(1); 2347 writeBytes(varuint.encode(this._dragonPhase.value)); 2348 } 2349 } 2350 2351 public pure nothrow @property @safe @nogc bool ghastAttacking() { 2352 return _ghastAttacking.value; 2353 } 2354 2355 public pure nothrow @property @safe bool ghastAttacking(bool value) { 2356 this._cached = false; 2357 this._ghastAttacking.value = value; 2358 if(!this._ghastAttacking.changed) { 2359 this._ghastAttacking.changed = true; 2360 this._changed ~= &this.encodeGhastAttacking; 2361 } 2362 return value; 2363 } 2364 2365 public pure nothrow @safe encodeGhastAttacking(Buffer buffer) { 2366 with(buffer) { 2367 writeBigEndianUbyte(12); 2368 writeBigEndianUbyte(6); 2369 writeBigEndianBool(this._ghastAttacking.value); 2370 } 2371 } 2372 2373 public pure nothrow @property @safe @nogc uint slimeSize() { 2374 return _slimeSize.value; 2375 } 2376 2377 public pure nothrow @property @safe uint slimeSize(uint value) { 2378 this._cached = false; 2379 this._slimeSize.value = value; 2380 if(!this._slimeSize.changed) { 2381 this._slimeSize.changed = true; 2382 this._changed ~= &this.encodeSlimeSize; 2383 } 2384 return value; 2385 } 2386 2387 public pure nothrow @safe encodeSlimeSize(Buffer buffer) { 2388 with(buffer) { 2389 writeBigEndianUbyte(12); 2390 writeBigEndianUbyte(1); 2391 writeBytes(varuint.encode(this._slimeSize.value)); 2392 } 2393 } 2394 2395 public pure nothrow @property @safe @nogc uint shakingPower() { 2396 return _shakingPower.value; 2397 } 2398 2399 public pure nothrow @property @safe uint shakingPower(uint value) { 2400 this._cached = false; 2401 this._shakingPower.value = value; 2402 if(!this._shakingPower.changed) { 2403 this._shakingPower.changed = true; 2404 this._changed ~= &this.encodeShakingPower; 2405 } 2406 return value; 2407 } 2408 2409 public pure nothrow @safe encodeShakingPower(Buffer buffer) { 2410 with(buffer) { 2411 writeBigEndianUbyte(6); 2412 writeBigEndianUbyte(1); 2413 writeBytes(varuint.encode(this._shakingPower.value)); 2414 } 2415 } 2416 2417 public pure nothrow @property @safe @nogc uint shakingDirection() { 2418 return _shakingDirection.value; 2419 } 2420 2421 public pure nothrow @property @safe uint shakingDirection(uint value) { 2422 this._cached = false; 2423 this._shakingDirection.value = value; 2424 if(!this._shakingDirection.changed) { 2425 this._shakingDirection.changed = true; 2426 this._changed ~= &this.encodeShakingDirection; 2427 } 2428 return value; 2429 } 2430 2431 public pure nothrow @safe encodeShakingDirection(Buffer buffer) { 2432 with(buffer) { 2433 writeBigEndianUbyte(7); 2434 writeBigEndianUbyte(1); 2435 writeBytes(varuint.encode(this._shakingDirection.value)); 2436 } 2437 } 2438 2439 public pure nothrow @property @safe @nogc float shakingMultiplier() { 2440 return _shakingMultiplier.value; 2441 } 2442 2443 public pure nothrow @property @safe float shakingMultiplier(float value) { 2444 this._cached = false; 2445 this._shakingMultiplier.value = value; 2446 if(!this._shakingMultiplier.changed) { 2447 this._shakingMultiplier.changed = true; 2448 this._changed ~= &this.encodeShakingMultiplier; 2449 } 2450 return value; 2451 } 2452 2453 public pure nothrow @safe encodeShakingMultiplier(Buffer buffer) { 2454 with(buffer) { 2455 writeBigEndianUbyte(8); 2456 writeBigEndianUbyte(2); 2457 writeBigEndianFloat(this._shakingMultiplier.value); 2458 } 2459 } 2460 2461 public pure nothrow @property @safe @nogc uint minecartBlock() { 2462 return _minecartBlock.value; 2463 } 2464 2465 public pure nothrow @property @safe uint minecartBlock(uint value) { 2466 this._cached = false; 2467 this._minecartBlock.value = value; 2468 if(!this._minecartBlock.changed) { 2469 this._minecartBlock.changed = true; 2470 this._changed ~= &this.encodeMinecartBlock; 2471 } 2472 return value; 2473 } 2474 2475 public pure nothrow @safe encodeMinecartBlock(Buffer buffer) { 2476 with(buffer) { 2477 writeBigEndianUbyte(9); 2478 writeBigEndianUbyte(1); 2479 writeBytes(varuint.encode(this._minecartBlock.value)); 2480 } 2481 } 2482 2483 public pure nothrow @property @safe @nogc uint minecartBlockPosition() { 2484 return _minecartBlockPosition.value; 2485 } 2486 2487 public pure nothrow @property @safe uint minecartBlockPosition(uint value) { 2488 this._cached = false; 2489 this._minecartBlockPosition.value = value; 2490 if(!this._minecartBlockPosition.changed) { 2491 this._minecartBlockPosition.changed = true; 2492 this._changed ~= &this.encodeMinecartBlockPosition; 2493 } 2494 return value; 2495 } 2496 2497 public pure nothrow @safe encodeMinecartBlockPosition(Buffer buffer) { 2498 with(buffer) { 2499 writeBigEndianUbyte(10); 2500 writeBigEndianUbyte(1); 2501 writeBytes(varuint.encode(this._minecartBlockPosition.value)); 2502 } 2503 } 2504 2505 public pure nothrow @property @safe @nogc bool minecartCustomBlock() { 2506 return _minecartCustomBlock.value; 2507 } 2508 2509 public pure nothrow @property @safe bool minecartCustomBlock(bool value) { 2510 this._cached = false; 2511 this._minecartCustomBlock.value = value; 2512 if(!this._minecartCustomBlock.changed) { 2513 this._minecartCustomBlock.changed = true; 2514 this._changed ~= &this.encodeMinecartCustomBlock; 2515 } 2516 return value; 2517 } 2518 2519 public pure nothrow @safe encodeMinecartCustomBlock(Buffer buffer) { 2520 with(buffer) { 2521 writeBigEndianUbyte(11); 2522 writeBigEndianUbyte(6); 2523 writeBigEndianBool(this._minecartCustomBlock.value); 2524 } 2525 } 2526 2527 public pure nothrow @property @safe @nogc bool furnacePowered() { 2528 return _furnacePowered.value; 2529 } 2530 2531 public pure nothrow @property @safe bool furnacePowered(bool value) { 2532 this._cached = false; 2533 this._furnacePowered.value = value; 2534 if(!this._furnacePowered.changed) { 2535 this._furnacePowered.changed = true; 2536 this._changed ~= &this.encodeFurnacePowered; 2537 } 2538 return value; 2539 } 2540 2541 public pure nothrow @safe encodeFurnacePowered(Buffer buffer) { 2542 with(buffer) { 2543 writeBigEndianUbyte(12); 2544 writeBigEndianUbyte(6); 2545 writeBigEndianBool(this._furnacePowered.value); 2546 } 2547 } 2548 2549 public pure nothrow @property @safe @nogc string command() { 2550 return _command.value; 2551 } 2552 2553 public pure nothrow @property @safe string command(string value) { 2554 this._cached = false; 2555 this._command.value = value; 2556 if(!this._command.changed) { 2557 this._command.changed = true; 2558 this._changed ~= &this.encodeCommand; 2559 } 2560 return value; 2561 } 2562 2563 public pure nothrow @safe encodeCommand(Buffer buffer) { 2564 with(buffer) { 2565 writeBigEndianUbyte(12); 2566 writeBigEndianUbyte(3); 2567 writeBytes(varuint.encode(cast(uint)this._command.value.length)); writeString(this._command.value); 2568 } 2569 } 2570 2571 public pure nothrow @property @safe @nogc string lastOutput() { 2572 return _lastOutput.value; 2573 } 2574 2575 public pure nothrow @property @safe string lastOutput(string value) { 2576 this._cached = false; 2577 this._lastOutput.value = value; 2578 if(!this._lastOutput.changed) { 2579 this._lastOutput.changed = true; 2580 this._changed ~= &this.encodeLastOutput; 2581 } 2582 return value; 2583 } 2584 2585 public pure nothrow @safe encodeLastOutput(Buffer buffer) { 2586 with(buffer) { 2587 writeBigEndianUbyte(13); 2588 writeBigEndianUbyte(4); 2589 writeBytes(varuint.encode(cast(uint)this._lastOutput.value.length)); writeString(this._lastOutput.value); 2590 } 2591 } 2592 2593 public pure nothrow @property @safe @nogc uint fuseTime() { 2594 return _fuseTime.value; 2595 } 2596 2597 public pure nothrow @property @safe uint fuseTime(uint value) { 2598 this._cached = false; 2599 this._fuseTime.value = value; 2600 if(!this._fuseTime.changed) { 2601 this._fuseTime.changed = true; 2602 this._changed ~= &this.encodeFuseTime; 2603 } 2604 return value; 2605 } 2606 2607 public pure nothrow @safe encodeFuseTime(Buffer buffer) { 2608 with(buffer) { 2609 writeBigEndianUbyte(6); 2610 writeBigEndianUbyte(1); 2611 writeBytes(varuint.encode(this._fuseTime.value)); 2612 } 2613 } 2614 2615 public pure nothrow @safe encode(Buffer buffer) { 2616 with(buffer) { 2617 if(this._cached) { 2618 buffer.writeBytes(this._cache); 2619 } else { 2620 immutable start = buffer._buffer.length; 2621 foreach(del ; this._changed) del(buffer); 2622 writeBigEndianUbyte(255); 2623 this._cached = true; 2624 this._cache = buffer._buffer[start..$]; 2625 } 2626 } 2627 } 2628 2629 public static pure nothrow @safe Metadata decode(Buffer buffer) { 2630 return null; 2631 } 2632 2633 }