Package com.prineside.tdi2.towers
Class BasicTower
java.lang.Object
com.prineside.tdi2.Registrable
com.prineside.tdi2.Building
com.prineside.tdi2.Tower
com.prineside.tdi2.towers.BasicTower
- All Implemented Interfaces:
com.badlogic.gdx.utils.Disposable
,com.esotericsoftware.kryo.KryoSerializable
,ScheduledUpdater.Updatable
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class com.prineside.tdi2.Tower
Tower.AbilityConfig, Tower.AimStrategy, Tower.Factory<T extends Tower>, Tower.FindEnemyFilter
-
Field Summary
FieldsFields inherited from class com.prineside.tdi2.Tower
ABILITIES_COUNT, ABILITY_INDEX_POWERFUL, ABILITY_INDEX_SPECIAL, ABILITY_INDEX_ULTIMATE, ABILITY_NAMES, abilityAvailableParticleEffect, aimStrategy, angle, attackDisabled, bonusCoinsBrought, bountyModifiersNearby, currentLevelExperience, damageGiven, DPS_STAT_INTERVAL, DPS_STAT_SLOTS, dpsDamage, dpsTime, enemiesKilled, experience, experienceGeneration, experienceMultiplier, id, installedAbilities, LEVEL_EXPERIENCE, LEVEL_EXPERIENCE_MILESTONES, MAX_LEVEL, MAX_UPGRADE_LEVEL, mdps, minRangeInPixels, moneySpentOn, nextLevelExperience, outOfOrder, rangeInPixels, rangeInPixelsSqr, searchEnemiesHelper, SHADOW_COLOR, shotCount, type
Fields inherited from class com.prineside.tdi2.Building
buildingType
Fields inherited from class com.prineside.tdi2.Registrable
S
-
Method Summary
Modifier and TypeMethodDescriptionvoid
attack
(int shotsCount) boolean
canAim()
void
drawBase
(com.badlogic.gdx.graphics.g2d.SpriteCache spriteCache, int x, int y, MapRenderingSystem.DrawMode drawMode) float
float
int
float
getStat
(TowerStatType towerStatType) com.badlogic.gdx.utils.Array<TextureRegionConfig>
void
onAbilitySet
(int abilityIdx, boolean isSet) void
read
(com.esotericsoftware.kryo.Kryo kryo, com.esotericsoftware.kryo.io.Input input) void
scheduledUpdate
(float deltaTime) void
setExperience
(float exp) Установка опыта напрямуюvoid
update
(float deltaTime) void
Обновляет кэш текущих характеристик башни Так как характеристики обновляются, одновременно обновляется массив тайлов в радиусе пораженияvoid
write
(com.esotericsoftware.kryo.Kryo kryo, com.esotericsoftware.kryo.io.Output output) Methods inherited from class com.prineside.tdi2.Tower
addExperience, applyDrawInterpolation, canAbilityBeInstalled, canAttack, canAttackEnemy, canNewAbilityBeInstalled, cloneBuilding, customButtonAction, dispose, drawBatch, drawBatchAdditive, drawGlitch, drawHoveredRange, drawSelectedRange, drawWeapon, fillTowerMenu, findTarget, findTarget, getCachedStatBuffed, getEnemyPriority, getExpLevelStatBonusPercentage, getLevel, getLevelForExperience, getMaxTowerLevel, getMaxUpgradeLevel, getMinRange, getPowerCombinedMultiplier, getRange, getStartingLevel, getStatBuffed, getStatCacheState, getTarget, getUniqueStatDescription, getUpgradeLevel, hasCustomButton, isAbilityInstalled, isCustomButtonNeedMapPoint, isOutOfOrder, isSellFullRefundStillActive, isStatAffectedByPower, loadFromJson, onPreSell, placedOnMap, registerNearbyModifier, removedFromMap, rotateTo, rotateTo, scheduledUpdatableGetId, scheduledUpdatableSetId, setAimStrategy, setRegistered, setTarget, setTile, setUnregistered, setUpgradeLevel, shouldSearchForTarget, toJson, traverseTilesInRange, unregisterNearbyModifier, updateCustomButton, upgrade, upgrade
Methods inherited from class com.prineside.tdi2.Registrable
isRegistered
-
Field Details
-
ABILITY_FOUNDATION
public static final int ABILITY_FOUNDATION- See Also:
-
-
Method Details
-
write
public void write(com.esotericsoftware.kryo.Kryo kryo, com.esotericsoftware.kryo.io.Output output) -
read
public void read(com.esotericsoftware.kryo.Kryo kryo, com.esotericsoftware.kryo.io.Input input) -
getWeaponTextures
- Specified by:
getWeaponTextures
in classTower
-
getSellPrice
public int getSellPrice()- Overrides:
getSellPrice
in classTower
-
setExperience
public void setExperience(float exp) Description copied from class:Tower
Установка опыта напрямую- Overrides:
setExperience
in classTower
- Parameters:
exp
- кол-во опыта, которое будет установлено точно таким же
-
onAbilitySet
public void onAbilitySet(int abilityIdx, boolean isSet) - Overrides:
onAbilitySet
in classTower
-
canAim
public boolean canAim() -
getAttackDelay
public float getAttackDelay()- Overrides:
getAttackDelay
in classTower
-
attack
public void attack(int shotsCount) -
getStat
-
updateCache
public void updateCache()Description copied from class:Tower
Обновляет кэш текущих характеристик башни Так как характеристики обновляются, одновременно обновляется массив тайлов в радиусе поражения- Overrides:
updateCache
in classTower
-
drawBase
public void drawBase(com.badlogic.gdx.graphics.g2d.SpriteCache spriteCache, int x, int y, MapRenderingSystem.DrawMode drawMode) -
update
public void update(float deltaTime) -
getScheduledUpdateInterval
public float getScheduledUpdateInterval()- Overrides:
getScheduledUpdateInterval
in classTower
-
scheduledUpdate
public void scheduledUpdate(float deltaTime) - Specified by:
scheduledUpdate
in interfaceScheduledUpdater.Updatable
- Overrides:
scheduledUpdate
in classTower
-