BlockState
, Metadatable
, PersistentDataHolder
, TileState
public interface CreatureSpawner extends TileState
Modifier and Type | Method | Description |
---|---|---|
@NotNull String |
getCreatureTypeName() |
Deprecated.
magic value, use
getSpawnedType() . |
int |
getDelay() |
Get the spawner's delay.
|
int |
getMaxNearbyEntities() |
Set the new maximum amount of similar entities that are allowed to be
within spawning range of this spawner.
|
int |
getMaxSpawnDelay() |
The maximum spawn delay amount (in ticks).
|
int |
getMinSpawnDelay() |
The minimum spawn delay amount (in ticks).
|
int |
getRequiredPlayerRange() |
Get the maximum distance(squared) a player can be in order for this
spawner to be active.
|
int |
getSpawnCount() |
Get how many mobs attempt to spawn.
|
@NotNull EntityType |
getSpawnedType() |
Get the spawner's creature type.
|
int |
getSpawnRange() |
Get the radius around which the spawner will attempt to spawn mobs in.
|
void |
setCreatureTypeByName(@NotNull String creatureType) |
Deprecated.
magic value, use
setSpawnedType(org.bukkit.entity.EntityType) . |
void |
setDelay(int delay) |
Set the spawner's delay.
|
void |
setMaxNearbyEntities(int maxNearbyEntities) |
Set the maximum number of similar entities that are allowed to be within
spawning range of this spawner.
|
void |
setMaxSpawnDelay(int delay) |
Set the maximum spawn delay amount (in ticks).
|
void |
setMinSpawnDelay(int delay) |
Set the minimum spawn delay amount (in ticks).
|
void |
setRequiredPlayerRange(int requiredPlayerRange) |
Set the maximum distance (squared) a player can be in order for this
spawner to be active.
|
void |
setSpawnCount(int spawnCount) |
Set how many mobs attempt to spawn.
|
void |
setSpawnedType(@NotNull EntityType creatureType) |
Set the spawner's creature type.
|
void |
setSpawnRange(int spawnRange) |
Set the new spawn range.
|
getBlock, getBlockData, getChunk, getData, getLightLevel, getLocation, getLocation, getRawData, getType, getWorld, getX, getY, getZ, isPlaced, setBlockData, setData, setRawData, setType, update, update, update
getMetadata, hasMetadata, removeMetadata, setMetadata
getPersistentDataContainer
@NotNull @NotNull EntityType getSpawnedType()
void setSpawnedType(@NotNull @NotNull EntityType creatureType)
creatureType
- The creature type.@Deprecated void setCreatureTypeByName(@NotNull @NotNull String creatureType)
setSpawnedType(org.bukkit.entity.EntityType)
.creatureType
- The creature type's name.@Deprecated @NotNull @NotNull String getCreatureTypeName()
getSpawnedType()
.int getDelay()
void setDelay(int delay)
getMinSpawnDelay()
and getMaxSpawnDelay()
.delay
- The delay.int getMinSpawnDelay()
getMinSpawnDelay()
and getMaxSpawnDelay()
for its next getDelay()
.
Default value is 200 ticks.void setMinSpawnDelay(int delay)
delay
- the minimum spawn delay amountgetMinSpawnDelay()
int getMaxSpawnDelay()
getMinSpawnDelay()
and getMaxSpawnDelay()
for its next getDelay()
.
getMaxSpawnDelay()
.
Default value is 800 ticks.void setMaxSpawnDelay(int delay)
getMinSpawnDelay()
delay
- the new maximum spawn delay amountgetMaxSpawnDelay()
int getSpawnCount()
void setSpawnCount(int spawnCount)
spawnCount
- the new spawn countint getMaxNearbyEntities()
getDelay()
.
void setMaxNearbyEntities(int maxNearbyEntities)
EntityType
maxNearbyEntities
- the maximum number of nearby, similar, entitiesint getRequiredPlayerRange()
void setRequiredPlayerRange(int requiredPlayerRange)
requiredPlayerRange
- the maximum distance (squared) a player can be
in order for this spawner to be active.int getSpawnRange()
void setSpawnRange(int spawnRange)
spawnRange
- the new spawn rangegetSpawnRange()
Copyright © 2020. All rights reserved.