Enum Class MobSpawnEvent.PositionCheck.Result
java.lang.Object
java.lang.Enum<MobSpawnEvent.PositionCheck.Result>
net.neoforged.neoforge.event.entity.living.MobSpawnEvent.PositionCheck.Result
- All Implemented Interfaces:
Serializable
,Comparable<MobSpawnEvent.PositionCheck.Result>
,Constable
- Enclosing class:
MobSpawnEvent.PositionCheck
public static enum MobSpawnEvent.PositionCheck.Result
extends Enum<MobSpawnEvent.PositionCheck.Result>
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantDescriptionThe results ofMob.checkSpawnRules(LevelAccessor, MobSpawnType)
andMob.checkSpawnObstruction(LevelReader)
will be used to determine if the check will succeed.Forces the event to cause the position check to fail.Forces the event to cause the position check to succeed. -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionReturns the enum constant of this class with the specified name.static MobSpawnEvent.PositionCheck.Result[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
SUCCEED
Forces the event to cause the position check to succeed. -
DEFAULT
The results ofMob.checkSpawnRules(LevelAccessor, MobSpawnType)
andMob.checkSpawnObstruction(LevelReader)
will be used to determine if the check will succeed.If this is being called from a spawner, the
Mob.checkSpawnRules(LevelAccessor, MobSpawnType)
call will be skipped if anySpawnData.CustomSpawnRules
are present. -
FAIL
Forces the event to cause the position check to fail.
-
-
Constructor Details
-
Result
private Result()
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum class has no constant with the specified nameNullPointerException
- if the argument is null
-