Package net.minecraft.world.biome
Class Biome.SpawnDensity
java.lang.Object
net.minecraft.world.biome.Biome.SpawnDensity
- Enclosing class:
- Biome
public static class Biome.SpawnDensity extends Object
Embodies the density limit information of a type of entity in entity
spawning logic. The density field is generated for all entities spawned
than a specific type of entity.
-
Field Summary
Fields Modifier and Type Field Description private doublegravityLimitprivate doublemass -
Constructor Summary
Constructors Constructor Description SpawnDensity(double gravityLimit, double mass) -
Method Summary
Modifier and Type Method Description doublegetGravityLimit()Represents the cap of gravity as inGravityField.calculate(BlockPos, double)for entity spawning.doublegetMass()Represents the mass of each entity spawned.
-
Field Details
-
gravityLimit
private final double gravityLimit -
mass
private final double mass
-
-
Constructor Details
-
SpawnDensity
public SpawnDensity(double gravityLimit, double mass)
-
-
Method Details
-
getGravityLimit
public double getGravityLimit()Represents the cap of gravity as inGravityField.calculate(BlockPos, double)for entity spawning. If the cap is exceeded, the entity spawning attempt will skip. -
getMass
public double getMass()Represents the mass of each entity spawned. Will affect gravity calculation.
-