@CatalogedBy(value=BlockChangeFlags.class) public interface BlockChangeFlag
| Modifier and Type | Method and Description |
|---|---|
BlockChangeFlag |
andFlag(BlockChangeFlag flag)
Gets the equivalent
BlockChangeFlag of this flag
with the trues set for this flag and the provided
flag, such that only if both flags have the same
true flags set will persist. |
BlockChangeFlag |
andNotFlag(BlockChangeFlag flag)
Gets the equivalent
BlockChangeFlag of this flag
with the trues set for this flag and the provided
flag, such that only if both flags have the same
true flags set will persist. |
BlockChangeFlag |
inverse()
Gets the inverted
BlockChangeFlag of this flag. |
boolean |
notifyObservers()
Gets whether this flag will update observer blocks, different
from notifying neighbors in that neighbor notifications
can cause further block notification loops (like redstone),
whereas this focuses on
BlockTypes.OBSERVER blocks
being told of updates. |
boolean |
performBlockPhysics()
Gets whether this flag defines that a block change should
perform block physics checks or not.
|
boolean |
updateNeighbors()
Gets whether this flag defines that a block change should
notify neighboring blocks.
|
BlockChangeFlag |
withNotifyObservers(boolean notifyObservers)
Gets the equivalent
BlockChangeFlag of this flag with all
other flags while having the desired notifyObservers
as defined by the parameter. |
BlockChangeFlag |
withPhysics(boolean performBlockPhysics)
Gets the equivalent
BlockChangeFlag of this flag
with all other flags while having the desired performBlockPhysics
as defined by the parameter. |
BlockChangeFlag |
withUpdateNeighbors(boolean updateNeighbors)
Gets the equivalent
BlockChangeFlag of this flag with all
other flags while having the desired updateNeighbors
as defined by the parameter. |
boolean updateNeighbors()
boolean performBlockPhysics()
boolean notifyObservers()
BlockTypes.OBSERVER blocks
being told of updates.BlockChangeFlag withUpdateNeighbors(boolean updateNeighbors)
BlockChangeFlag of this flag with all
other flags while having the desired updateNeighbors
as defined by the parameter.updateNeighbors - Whether to update neighboring blocksBlockChangeFlag withPhysics(boolean performBlockPhysics)
BlockChangeFlag of this flag
with all other flags while having the desired performBlockPhysics
as defined by the parameter.performBlockPhysics - Whether to perform block physicsBlockChangeFlag withNotifyObservers(boolean notifyObservers)
BlockChangeFlag of this flag with all
other flags while having the desired notifyObservers
as defined by the parameter.notifyObservers - Whether to update observer blocksBlockChangeFlag inverse()
BlockChangeFlag of this flag.
Normally, this may cancel out certain interactions, such
as physics, neighbor notifications, or even observer
notifications. In certain circumstances, some flags may
even require clients to rejoin the world or restart their
connections to the server.BlockChangeFlag andFlag(BlockChangeFlag flag)
BlockChangeFlag of this flag
with the trues set for this flag and the provided
flag, such that only if both flags have the same
true flags set will persist.
For example, if this flag has notifyObservers()
and the incoming flag has notifyObservers() returning
true, the resulting flag will have
notifyObservers() return true as well. The
inverse is also true. If either has differing flags for any
of the above methods, the resulting flag will have a
false value.
flag - The incoming flag to and with this flagBlockChangeFlag andNotFlag(BlockChangeFlag flag)
BlockChangeFlag of this flag
with the trues set for this flag and the provided
flag, such that only if both flags have the same
true flags set will persist.
For example, if this flag has notifyObservers()
and the incoming flag has notifyObservers() returning
true, the resulting flag will have
notifyObservers() return true as well. The
inverse is also true. If either has differing flags for any
of the above methods, the resulting flag will have a
false value.
flag - The incoming flag to and with this flag