Bandidos
|
Public Member Functions | |
void | register (float x, float y, BaseEntity hitEntity, int toolType, int[] hitTypes) |
void | register (float x, float y, BaseEntity hitEntity, int toolType, int hitType) |
Public Member Functions inherited from com.mygdx.game.engine.events.EventDispatcher | |
void | addEventListener (String type, IEventReceiver listeningClass) |
void | dispatchEvent (Event event) |
void | removeEventListener (String type, IEventReceiver listener) |
boolean | hasEventListener (String type) |
ArrayList< ListenerItem > | getAllListeners () |
void | destroyAllListeners () |
void | clean () |
Static Public Member Functions | |
static HitRegistrationPoint | getInstance () |
Static Public Attributes | |
static final String | HIT_REGISTRATED_EVENT = "HitRegistrationEvent" |
This class is a singleton where all the hits of the game should be registered to. This is the center-point where all hit events can be listened to by other classes.
|
static |
void com.mygdx.game.hitRegistration.HitRegistrationPoint.register | ( | float | x, |
float | y, | ||
BaseEntity | hitEntity, | ||
int | toolType, | ||
int [] | hitTypes | ||
) |
This registers a hit which dispatches the HIT_REGISTRATED_EVENT type event which other classes can listen to.
hitEntity | is the entity which was hit. (This may be set as 'null' if you want to call a ground hit for example) |
toolType | indicates the object which hit the entity (Check HitGlobals for all the tools) |
hitTypes | indicates the types of hits these presented (Explosion, Fire etc) (Check HitGlobals for all the types) |
void com.mygdx.game.hitRegistration.HitRegistrationPoint.register | ( | float | x, |
float | y, | ||
BaseEntity | hitEntity, | ||
int | toolType, | ||
int | hitType | ||
) |
This registers a hit which dispatches the HIT_REGISTRATED_EVENT type event which other classes can listen to.
hitEntity | is the entity which was hit. (This may be set as 'null' if you want to call a ground hit for example) |
toolType | indicates the object which hit the entity (Check HitGlobals for all the tools) |
hitType | indicates the type of hit this presented (Explosion, Fire etc) (Check HitGlobals for all the types) |
|
static |