Package com.prineside.tdi2.systems
Class DamageSystem
java.lang.Object
com.prineside.tdi2.Registrable
com.prineside.tdi2.GameSystem
com.prineside.tdi2.systems.DamageSystem
- All Implemented Interfaces:
Disposable
,KryoSerializable
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsFields inherited from class com.prineside.tdi2.Registrable
S
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionboolean
void
Actually applies the damage given to the enemiesvoid
void
drawDebugDpsChart
(Batch batch) double
void
queueDamage
(DamageRecord record) void
queueEnemyKill
(DamageRecord lastDamage) void
void
setTowersMaxDps
(double mdps) void
setup()
Performs the initial configuration of the system.void
update
(float deltaTime) void
Methods inherited from class com.prineside.tdi2.GameSystem
dispose, getFastStateHash, postSetup, postStateRestore, profileUpdate
Methods inherited from class com.prineside.tdi2.Registrable
isRegistered, setRegistered, setUnregistered
-
Field Details
-
DAMAGE_DRAIN_MAX_ITERATIONS
public static final int DAMAGE_DRAIN_MAX_ITERATIONS- See Also:
-
-
Constructor Details
-
DamageSystem
public DamageSystem()
-
-
Method Details
-
write
- Specified by:
write
in interfaceKryoSerializable
- Overrides:
write
in classRegistrable
-
read
- Specified by:
read
in interfaceKryoSerializable
- Overrides:
read
in classRegistrable
-
obtainRecord
-
setup
public void setup()Description copied from class:GameSystem
Performs the initial configuration of the system. At the moment of call, systemProvider already contains all objects of systems.- Overrides:
setup
in classGameSystem
-
queueDamage
-
getTowersMaxDps
public double getTowersMaxDps()- Returns:
- MDPS
-
setTowersMaxDps
public void setTowersMaxDps(double mdps) -
queueEnemyKill
-
drainDamageAndKillQueue
public void drainDamageAndKillQueue()Actually applies the damage given to the enemies -
drainDamageAndKillQueueTillEmpty
public void drainDamageAndKillQueueTillEmpty() -
update
public void update(float deltaTime) - Overrides:
update
in classGameSystem
-
drawDebugDpsChart
-
affectsGameState
public boolean affectsGameState()- Specified by:
affectsGameState
in classGameSystem
-
getSystemName
- Specified by:
getSystemName
in classGameSystem
-