#961: Add BlockData#copyTo

By: Jishuna <joshl5324@gmail.com>
This commit is contained in:
Bukkit/Spigot 2024-01-15 20:33:15 +11:00
parent a70e6187b4
commit 2803610916

View File

@ -247,6 +247,16 @@ public interface BlockData extends Cloneable {
*/
void mirror(@NotNull Mirror mirror);
/**
* Copies all applicable properties from this BlockData to the provided
* BlockData.
* <p>
* Only modifies properties that both blocks share in common.
*
* @param other the BlockData to copy properties to
*/
void copyTo(@NotNull BlockData other);
/**
* Creates a new default {@link BlockState} for this type of Block, not
* bound to a location.