cMobSpawnerEntity


Index:
Articles
Classes
Hooks

Quick navigation:
BannerPattern
BossBarColor
BossBarDivisionType
cArrowEntity
cBeaconEntity
cBedEntity
cBlockArea
cBlockEntity
cBlockEntityWithItems
cBlockInfo
cBoat
cBoundingBox
cBrewingstandEntity
cChatColor
cChestEntity
cChunkDesc
cClientHandle
cColor
cCommandBlockEntity
cCompositeChat
cCraftingGrid
cCraftingRecipe
cCryptoHash
cCuboid
cDispenserEntity
cDropperEntity
cDropSpenserEntity
cEnchantments
cEnderCrystal
cEntity
cEntityEffect
cExpBottleEntity
cExpOrb
cFallingBlock
cFile
cFireChargeEntity
cFireworkEntity
cFloater
cFlowerPotEntity
cFurnaceEntity
cGhastFireballEntity
cHangingEntity
cHopperEntity
cIniFile
cInventory
cItem
cItemFrame
cItemGrid
cItems
cJson
cJukeboxEntity
cLeashKnot
cLineBlockTracer
cLuaWindow
cMap
cMapManager
cMobHeadEntity
cMobSpawnerEntity
cMojangAPI
cMonster
cNetwork
cNoteEntity
cObjective
cPainting
cPawn
cPickup
cPlayer
cPlugin
cPluginLua
cPluginManager
cProjectileEntity
cRankManager
cRoot
cScoreboard
cServer
cServerHandle
cSignEntity
cSplashPotionEntity
cStringCompression
cTCPLink
cTeam
cThrownEggEntity
cThrownEnderPearlEntity
cThrownSnowballEntity
cTNTEntity
cUDPEndpoint
cUrlClient
cUrlParser
CustomStatistic
cUUID
cWebAdmin
cWindow
cWitherSkullEntity
cWorld
EffectID
HTTPFormData
HTTPRequest
HTTPTemplateRequest
ItemCategory
lxp
SmokeDirection
sqlite3
StatisticsManager
TakeDamageInfo
tolua
Vector3d
Vector3f
Vector3i
Globals

Contents


cMobSpawnerEntity class

This class represents a mob spawner block entity in the world.


Inheritance

This class inherits from the following parent classes:


Functions

NameParametersReturn valueNotes
GetEntity
MobTypeeMonsterType
Returns the entity type that will be spawn by this mob spawner.
GetMaxNearbyEntities
number
Returns the maximum number of entities of the same type that can be present before the spawner cannot spawn more entities.
GetMaxSpawnDelay
number
Returns the maximum number of ticks the spawner waits until spawning new entities automatically.
GetMinSpawnDelay
number
Returns the minimum number of ticks the spawner waits until spawning new entities automatically.
GetNearbyMonsterNum
MobTypeeMonsterType
number
Returns the amount of this monster type in a radius defined by SetSpawnRange (Y: 4-block radius).
GetNearbyPlayersNum
number
Returns the amount of the nearby players in a 16-block radius.
GetRequiredPlayerRange
number
Returns the maximum euclidean distance from a player where the spawner can be activated.
GetSpawnCount
number
Returns the number of entities the spawner will try to spawn on each activation.
GetSpawnDelay
number
Returns the spawn delay. This is the tick delay that is needed to spawn new monsters.
GetSpawnRange
number
Returns half the length of the square the spawner tries to spawn entities in.
ResetTimer Sets the spawn delay to a new random value.
SetEntity
MobTypeeMonsterType
Sets the type of the mob that will be spawned by this mob spawner.
SetMaxNearbyEntities
MaxNearbyEntitiesnumber
Sets the maximum amount of nearby entities until the spawner will stop spawning this entity type.
SetMaxSpawnDelay
MaxSpawnDelaynumber
Sets the maximum amount of ticks the spawner will wait before spawning new entities.
SetMinSpawnDelay
MinSpawnDelaynumber
Sets the minimum amount of ticks the spawner will wait before spawning new entities.
SetRequiredPlayerRange
RequiredPlayerRangenumber
Sets the maximum euclidean distance from a player where the spawner can be activated.
SetSpawnCount
SpawnCountnumber
Sets the number of entities the spawner will try to spawn in each activation. Might not spawn all of them due to spawn limitations of the entity.
SetSpawnDelay
SpawnDelayTicksnumber
Sets the spawn delay.
SetSpawnRange
SpawnRangenumber
Sets half the length of the square the spawner will try to spawn entities in.
SpawnEntity Spawns the entity. NOTE: This function resets the delay before the next automatic activation of the spawner.
UpdateActiveState Update the active flag from the mob spawner. This function is called every 5 seconds from the Tick() function.

Functions inherited from cBlockEntity

NameParametersReturn valueNotes
GetBlockType
BLOCKTYPEnumber
Returns the blocktype which is represented by this blockentity. This is the primary means of type-identification
GetChunkX
number
Returns the chunk X-coord of the block entity's chunk
GetChunkZ
number
Returns the chunk Z-coord of the block entity's chunk
GetPos
Vector3i
Returns the name of the parent class, or empty string if no parent class.
GetPosX
number
Returns the block X-coord of the block entity's block
GetPosY
number
Returns the block Y-coord of the block entity's block
GetPosZ
number
Returns the block Z-coord of the block entity's block
GetRelPos
Vector3i
Returns the relative coords of the block entity's block within its chunk
GetRelX
number
Returns the relative X coord of the block entity's block within the chunk
GetRelZ
number
Returns the relative Z coord of the block entity's block within the chunk
GetWorld
cWorld
Returns the world to which the block entity belongs
Generated by APIDump on 2024-12-05 00:47:58, Build ID 88, Commit 4b2b02a8ba1cf259ead477cc256c4ac2a994809c