Molang SpawningContext Functions
Type is ObjectValue<SpawningContext>
.
Name | Description | Usage |
---|---|---|
biome(): ObjectValue<Biome>
|
Returns an ObjectValue<Biome> of the biome the SpawningContext is in.
|
v.spawning_context.biome()
|
world(): ObjectValue<World>
|
Returns an ObjectValue<World> of the world the SpawningContext is in.
|
v.spawning_context.world()
|
light(): Double
|
Returns the light value of the SpawningContext. | v.spawning_context.light()
|
x(): Double
|
Returns the x value as a Double. | v.spawning_context.x()
|
y(): Double
|
Returns the y value as a Double. | v.spawning_context.y()
|
z(): Double
|
Returns the z value as a Double. | v.spawning_context.z()
|
moon_phase(): Double
|
Returns the moon phase as a Double | v.spawning_context.moon_phase()
|
can_see_sky(): Double
|
Returns 1.0 if the SpawningContext can see the sky, otherwise returns 0.0 .
|
v.spawning_context.can_see_sky()
|
bucket(): String
|
Returns the bucket as a String. | v.spawning_context.bucket()
|
player(): MoValue
|
Returns an ObjectValue<Player> if the spawning was caused by a player, otherwise returns 0.0
|
v.spawning_context.player()
|