- summary: Opens the fight the character is entering: fight id, fight type, who attacked, whether a boss is in it and which monsters take part.
- area: Game.Fight.Preparation
Opens the fight the character is entering: fight id, fight type, who attacked, whether a boss is in it and which monsters take part.
Kind event · Area Game.Fight.Preparation
The first fight message of a fight. It tells you which fight you are in and how it started. It arrives once per fight, while the fight is still in its placement phase.
WHAT TO DO WHEN YOU RECEIVE IT
1. Start a new fight record. Forget the previous fight's state: fighters, turn
order, placement cells. Key the record by FightStartingEvent.fight_id.
2. Store FightStartingEvent.fight_type (FightType). It decides what the rest
of the fight looks like (PvM, arena, challenge, ...).
3. Store FightStartingEvent.attacker_id. When you attacked a monster group it is
your own character id.
4. Read FightStartingEvent.monsters if you need to know what you are fighting:
it lists the monster template ids taking part, before any fighter is shown.
5. SEND NOTHING BACK. No handler of this message builds a request.
6. Wait for FightJoinEvent, which comes right behind it and says whether you are
placing, ready-checking or already fighting.
WHAT THE CLIENT DOES. Its fight-state object takes the fight type (through the
client's own fight-type conversion), the attacker id and, on builds from 3.5 on,
the fight id. It sets a boss flag from FightStartingEvent.contain_boss and walks
FightStartingEvent.monsters, checking each id against one monster race of the
game data to set a second flag.
THE DEFENDER. The canonical message also carries the defender id - the attacked
entity, the monster group id when you attack monsters (the same negative id you
put in AttackMonsterRequest.monster_group_id). The client never reads it, so it is named here only on
builds where it is the one int64 left besides the attacker; a build that pads the
message with another int64 leaves it unnamed.
OBSERVED (one capture, PvM): attacker = own character id, defender = the attacked
monster group's id (-20002), fight_type = PvM, monsters = the two monster template
ids of the group, fight_id = 3089, the id the fight team updates (FightTeamUpdateEvent)
for the same fight had carried a few milliseconds earlier.
It arrived about 30 ms after ContextReadyRequest for the fight map, then
FightJoinEvent and one FightFighterShowEvent per fighter followed in the same burst.
IT IS NOT ONLY AN ANSWER TO YOUR ATTACK. It follows AttackMonsterRequest when you
attack a monster group, but it also opens the fight when another player attacks you
or when you join a fight on the map (FightJoinRequest).
PADDING. Builds add decoys: a repeated string (3.7), a nested message (3.4), a third int64 (3.6.12.16). Unnamed members are padding; leave them unset.
When you may send it
- Requires
context_readyinferred
Related messages
- You will then receive
FightJoinEventobserved — travelling companion: arrived in the same frame burst right after it, 1 of 1 observation (attack on a monster group) - Arrives after
AttackMonsterRequest - Arrives after
FightJoinRequest
Fields
| # | Field | Type | Meaning | You set it |
|---|---|---|---|---|
| 1 | attacker_id | int64 | Id of the entity that started the fight: your own character id when you attacked. (entity id) The one int64 the client reads and keeps; the unobfuscated beta handler names it attackerId. | never |
| 3 | monsters | repeated int32 | Template ids of the monsters taking part in the fight. (monster template id) Observed: [4046, 4047]The client walks the list and checks each id against one monster race of the game data. | never |
| 4 | defender_id | int64 | Id of the entity that was attacked: the monster group id when you attacked monsters. (entity id) Observed: -20002The client never reads it. Named only where it is the one int64 left beside the attacker; padded builds leave it unnamed. | never |
| 5 | contain_boss | bool | True when a boss monster takes part in the fight. | never |
| 6 | fight_type | FightType | The kind of fight that is starting. A FightType; the client converts it to its own fight-type value and keeps it for the whole fight. | never |
| 7 | fight_id | int32 | Id of the fight, the key every later message about this fight refers to. (fight id) Observed: 3089Stored by the client from 3.5 on; older handlers ignore it. | never |