Enemy.lua¶
Functions¶
enemy.getData¶
Gets LibLevelGen data for the given enemy type.
Parameters:
| Name | Type | Description |
|---|---|---|
type |
string |
Type from the enemy.Type enum |
Returns: LibLevelGen.EnemyData
enemy.register¶
Register LibLevelGen enemy data in the enemy enum.
Parameters:
| Name | Type | Description |
|---|---|---|
entity |
string |
Entity base name |
maxLevel |
number |
Max level this entity can have |
args |
LibLevelGen.EnemyData |
Additional enemy definition data |
Returns: number
Classes¶
LibLevelGen.EnemyData¶
Class containing data related to processing it by the various level generation components.
Properties:
| Name | Type | Description |
|---|---|---|
entity |
string |
The base entity type |
maxLevel |
number |
Max level the entity type can have |
id |
number[] |
Numeric IDs for every level the entity has |
warRingUpgrade |
table<number,number> |
Table containing a mapping which specifies which levels get converted to which when ring of war is in effect |
warShrineUpgrade |
table<number,number> |
Table containing a mapping which specifies which levels get converted to which when shrine of war is in effect |
peaceRingDowngrade |
table<number,number> |
Table containing a mapping which specifies which levels get converted to which when ring of peace is in effect |
challengeCharacterDowngrade |
table<number,number> |
Table containing a mapping which specifies which levels get converted to which when playing a challenge character (Monk/Coda/Aria/Bolt - used to downgrade black bats into blue) |
Enums¶
enemy.Type¶
Enum containing enemy types and their associated data. Use enemy.getData to get data for a given enemy from this enum.
Entries:
KingCoralRiffKingCongaDeathmetalFortissimoleNecrodancerDeadRingerFrankensteinwayConductorLuteDragonDirebatDragonBansheeMinotaurNightmareMommyOgreMetrognomeArmadilloArmoredskeletonBatBeetleBishopBlademasterCauldronCloneDevilElectricMageEvileyeFireelementalIceelementalGhastGhostGhoulGoblinGoblinBomberGolemGorgonHarpyHellhoundKnightLichMonkeyMushroomOrcPawnPixieQueenRookSarcophagusShovemonsterSkeletonSkeletonknightSkeletonmageSkullSleepingGoblinSlimeSpiderTarmonsterTentacleTrapcouldronTrapchestTrollWarlockWaterBallWightWraithYetiZombieZombieElectricZombieSnake