Class BattleStartedEvent
java.lang.Object
net.neoforged.bus.api.Event
com.pixelmonmod.pixelmon.api.events.battles.BattleEvent
com.pixelmonmod.pixelmon.api.events.battles.BattleStartedEvent
- Direct Known Subclasses:
BattleStartedEvent.Post
,BattleStartedEvent.Pre
This class represents the events fired when a battle begins between two sides.
All battles are started using the
functions which is where this event is most likely called from.
Check
invalid reference
com.pixelmonmod.pixelmon.battles.BattleRegistry#startBattle(BattleParticipant, BattleParticipant)
Check
BattleStartedEvent.Pre
and BattleStartedEvent.Post
for more specific implementation details-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic class
Fired after the battle has been registered and begun.static class
Fired before the battle is registered and begins. -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final BattleParticipant[]
protected final BattleParticipant[]
Fields inherited from class com.pixelmonmod.pixelmon.api.events.battles.BattleEvent
battleController
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotected
BattleStartedEvent
(BattleController bc, BattleParticipant[] teamOne, BattleParticipant[] teamTwo) -
Method Summary
Modifier and TypeMethodDescriptionGets the first team of battle participantsGets the second team of battle participantsMethods inherited from class com.pixelmonmod.pixelmon.api.events.battles.BattleEvent
getBattleController
-
Field Details
-
teamOne
-
teamTwo
-
-
Constructor Details
-
BattleStartedEvent
protected BattleStartedEvent(BattleController bc, BattleParticipant[] teamOne, BattleParticipant[] teamTwo)
-
-
Method Details
-
getTeamOne
Gets the first team of battle participants- Returns:
- The first team
-
getTeamTwo
Gets the second team of battle participants- Returns:
- The second team
-