Package net.regsirius06.engine.API
Interface WallState
- All Superinterfaces:
Loadable
Represents the state of a wall in a labyrinth.
The WallState interface defines properties and behaviors of walls in a labyrinth,
such as whether the wall is light, empty, or generable. It also provides methods to retrieve
the absorption value and the color associated with the wall.
As the labyrinth system evolves, additional parameters for wall states may be added. Implementations of this interface should provide the specific behavior for each of the defined methods based on the type of wall they represent.
The default method thisEquals(Object) checks if the current wall state is equal
to another object, either by class type or class comparison.
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptiondoubleReturns the absorption coefficient of the wall, which can be used to model properties like energy absorption or blocking power of the wall.@NotNull ColorgetColor()Returns the color of the wall.booleanisEmpty()Returns whether the wall is empty (i.e., there is no wall).booleanReturns whether the wall is generable, meaning it can be dynamically created or altered.booleanisLight()Returns whether the wall is light (e.g., transparent or lit).default booleanthisEquals(Object o) Checks if this wall state is equal to another object.
-
Method Details
-
isLight
boolean isLight()Returns whether the wall is light (e.g., transparent or lit).- Returns:
trueif the wall is light,falseotherwise
-
isEmpty
boolean isEmpty()Returns whether the wall is empty (i.e., there is no wall).- Returns:
trueif the wall is empty,falseotherwise
-
isGenerable
boolean isGenerable()Returns whether the wall is generable, meaning it can be dynamically created or altered.- Returns:
trueif the wall is generable,falseotherwise
-
getAbsorption
double getAbsorption()Returns the absorption coefficient of the wall, which can be used to model properties like energy absorption or blocking power of the wall.- Returns:
- the absorption value of the wall
-
getColor
Returns the color of the wall.- Returns:
- the color of the wall
-
thisEquals
Checks if this wall state is equal to another object.The method compares the class of the current object to the class of the provided object to determine if they are the same type.
- Parameters:
o- the object to compare to- Returns:
trueif the objects are of the same class,falseotherwise
-