Block: get rid of getNonPersistentStateBitmask(), add writeStateToItemMeta()

this is more flexible and less confusing.
This commit is contained in:
Dylan K. Taylor
2021-08-02 19:17:24 +01:00
parent 01b48a21d9
commit bdac98beaf
13 changed files with 50 additions and 53 deletions

View File

@ -35,12 +35,12 @@ class Sponge extends Opaque{
$this->wet = ($stateMeta & BlockLegacyMetadata::SPONGE_FLAG_WET) !== 0;
}
public function getStateBitmask() : int{
return 0b1;
protected function writeStateToItemMeta() : int{
return $this->writeStateToMeta();
}
public function getNonPersistentStateBitmask() : int{
return 0;
public function getStateBitmask() : int{
return 0b1;
}
public function isWet() : bool{ return $this->wet; }