public class FrameData
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
java.util.Deque<Attack> |
attack
The projectile data of both characters
|
boolean |
emptyFlag
If this value is true, no data are available or they are dummy data.
|
KeyData |
keyData
The value of input information
|
CharacterData |
P1
The first character's data
|
CharacterData |
P2
The second character's data
|
long |
remainingTime
The remaining time in seconds of the current round
|
int |
round
The current round number
|
Constructor and Description |
---|
FrameData() |
FrameData(CharacterData P1,
CharacterData P2,
long remainingTime,
int round,
java.util.Deque<Attack> attack,
KeyData keyData)
This method receives the data from an instance of the Fighting class.
|
FrameData(FrameData frameData) |
Modifier and Type | Method and Description |
---|---|
void |
empty()
If data are not available, this method will be called to generate dummy data.
|
java.util.Deque<Attack> |
getAttack()
Returns the projectile data of both characters.
|
KeyData |
getKeyData()
Returns the value of input information.
|
CharacterData |
getMyCharacter(boolean playerNumber)
Returns CharacterData of your player character with the parameter player, returned from the method initialize in AIInterface.
|
CharacterData |
getOpponentCharacter(boolean playerNumber)
Returns CharacterData of the opponent' player character with the parameter player, returned from the method initialize in AIInterface.
|
CharacterData |
getP1()
Returns the first character's data.
|
CharacterData |
getP2()
Returns the second character's data.
|
long |
getRemainingTime()
Returns the remaining time in seconds of the current round.
|
int |
getRound()
Returns the current round number.
|
void |
loading(int timeCount)
If data are not available but the stage is ready, this method will be called.
|
public java.util.Deque<Attack> attack
public boolean emptyFlag
public KeyData keyData
public CharacterData P1
public CharacterData P2
public long remainingTime
public int round
public FrameData()
public FrameData(CharacterData P1, CharacterData P2, long remainingTime, int round, java.util.Deque<Attack> attack, KeyData keyData)
P1
- P2
- remainingTime
- round
- attack
- keyData
- public FrameData(FrameData frameData)
public void empty()
public java.util.Deque<Attack> getAttack()
public KeyData getKeyData()
public CharacterData getMyCharacter(boolean playerNumber)
playerNumber
- public CharacterData getOpponentCharacter(boolean playerNumber)
playerNumber
- public CharacterData getP1()
public CharacterData getP2()
public long getRemainingTime()
public int getRound()
public void loading(int timeCount)
timeCount
- The number of frames before a round starts