Package com.prineside.tdi2.systems
Class RandomEncounterSystem
java.lang.Object
com.prineside.tdi2.Registrable
com.prineside.tdi2.GameSystem
com.prineside.tdi2.systems.RandomEncounterSystem
- All Implemented Interfaces:
Disposable
,KryoSerializable
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic interface
class
static interface
static interface
-
Field Summary
Fields inherited from class com.prineside.tdi2.Registrable
S
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
addBird
(EncounterBird bird) boolean
void
birdAcceptAction
(int birdIdx) void
birdDeclineAction
(int birdIdx) boolean
Can be modified in place but only after PostSetup of this systemCan be modified in place but only after PostSetup of this systemboolean
void
Performs the final configuration of the system.void
void
void
setReceivedBonusLevelPass
(boolean receivedBonusLevelPass) void
setup()
Performs the initial configuration of the system.void
startFireworks
(float mapX, float mapY) void
void
update
(float deltaTime) void
Methods inherited from class com.prineside.tdi2.GameSystem
dispose, getFastStateHash, profileUpdate
Methods inherited from class com.prineside.tdi2.Registrable
isRegistered, setRegistered, setUnregistered
-
Constructor Details
-
RandomEncounterSystem
public RandomEncounterSystem()
-
-
Method Details
-
write
- Specified by:
write
in interfaceKryoSerializable
- Overrides:
write
in classRegistrable
-
read
- Specified by:
read
in interfaceKryoSerializable
- Overrides:
read
in classRegistrable
-
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
-
canGiveStateAffectingRewards
public boolean canGiveStateAffectingRewards() -
postSetup
public void postSetup()Description copied from class:GameSystem
Performs the final configuration of the system. At the moment of call, all systems are already loaded and setup(), all listeners are already added.- Overrides:
postSetup
in classGameSystem
-
postStateRestore
public void postStateRestore()- Overrides:
postStateRestore
in classGameSystem
-
isReceivedBonusLevelPass
public boolean isReceivedBonusLevelPass() -
startFireworks
public void startFireworks(float mapX, float mapY) -
setReceivedBonusLevelPass
public void setReceivedBonusLevelPass(boolean receivedBonusLevelPass) -
getEncounterTypes
Can be modified in place but only after PostSetup of this system -
getRewardTypes
Can be modified in place but only after PostSetup of this system -
getRandom
-
selectRandomReward
-
update
public void update(float deltaTime) - Overrides:
update
in classGameSystem
-
addBird
-
getActiveBirds
-
startNewEncounter
public void startNewEncounter() -
birdAcceptAction
public void birdAcceptAction(int birdIdx) -
birdDeclineAction
public void birdDeclineAction(int birdIdx) -
affectsGameState
public boolean affectsGameState()- Specified by:
affectsGameState
in classGameSystem
-
getSystemName
- Specified by:
getSystemName
in classGameSystem
-
prepareDefaultBird
-