|
| 1 | +## Game events |
| 2 | + |
| 3 | +List of game events that may be trigerred during parsing, some events are available only in GOTV and/or POV demos. |
| 4 | + |
| 5 | +You can add a listener on the parser's event `GenericGameEvent` to listen to all events, example: |
| 6 | + |
| 7 | +```go |
| 8 | +parser.RegisterEventHandler(func(event events.GenericGameEvent) { |
| 9 | + fmt.Println(event.Name, event.Data) |
| 10 | +}) |
| 11 | +``` |
| 12 | + |
| 13 | +> **Warning** |
| 14 | +> It has been noticed that some demos may not fire events when it should. A noticable one is the `round_end` event. |
| 15 | +> If you encounter this problem it's probably not a parser bug but simply a demo with missing events. |
| 16 | +> As a workaround you may subscribe to properties update. |
| 17 | +> For example to detect rounds end you could subscribe to updates of the property `m_iRoundWinStatus` of the entity `CCSGameRulesProxy`. |
| 18 | +
|
| 19 | +✅ = Available, ❌ = Not available, ? = Not sure, need to be tested |
| 20 | + |
| 21 | +| Event name | GOTV | POV | |
| 22 | +| ------------------------------- | ---- | --- | |
| 23 | +| ammo_pickup | ❌ | ✅ | |
| 24 | +| announce_phase_end | ✅ | ✅ | |
| 25 | +| begin_new_match | ✅ | ✅ | |
| 26 | +| bomb_beep | ✅ | ❌ | |
| 27 | +| bomb_begindefuse | ✅ | ❌ | |
| 28 | +| bomb_beginplant | ✅ | ❌ | |
| 29 | +| bomb_defused | ✅ | ✅ | |
| 30 | +| bomb_dropped | ✅ | ✅ | |
| 31 | +| bomb_exploded | ✅ | ✅ | |
| 32 | +| bomb_pickup | ✅ | ✅ | |
| 33 | +| bomb_planted | ✅ | ✅ | |
| 34 | +| bot_takeover | ✅ | ✅ | |
| 35 | +| buytime_ended | ✅ | ❌ | |
| 36 | +| choppers_incoming_warning | ? | ✅ | |
| 37 | +| cs_intermission | ❌ | ✅ | |
| 38 | +| cs_match_end_restart | ✅ | ✅ | |
| 39 | +| cs_pre_restart | ✅ | ✅ | |
| 40 | +| cs_round_final_beep | ✅ | ✅ | |
| 41 | +| cs_round_start_beep | ✅ | ✅ | |
| 42 | +| cs_win_panel_match | ✅ | ✅ | |
| 43 | +| cs_win_panel_round | ✅ | ✅ | |
| 44 | +| decoy_detonate | ✅ | ✅ | |
| 45 | +| decoy_started | ✅ | ✅ | |
| 46 | +| endmatch_cmm_start_reveal_items | ✅ | ❌ | |
| 47 | +| enter_bombzone | ❌ | ✅ | |
| 48 | +| enter_buyzone | ❌ | ✅ | |
| 49 | +| entity_visible | ❌ | ✅ | |
| 50 | +| exit_bombzone | ❌ | ✅ | |
| 51 | +| exit_buyzone | ❌ | ✅ | |
| 52 | +| firstbombs_incoming_warning | ? | ✅ | |
| 53 | +| flashbang_detonate | ✅ | ✅ | |
| 54 | +| hegrenade_detonate | ✅ | ✅ | |
| 55 | +| hltv_chase | ✅ | ❌ | |
| 56 | +| hltv_fixed | ✅ | ? | |
| 57 | +| hltv_message | ✅ | ? | |
| 58 | +| hltv_status | ❌ | ✅ | |
| 59 | +| hostage_follows | ❌ | ✅ | |
| 60 | +| hostage_hurt | ✅ | ✅ | |
| 61 | +| hostage_killed | ✅ | ✅ | |
| 62 | +| hostage_rescued | ✅ | ✅ | |
| 63 | +| hostage_rescued_all | ✅ | ✅ | |
| 64 | +| hostname_changed | ❌ | ✅ | |
| 65 | +| inferno_expire | ✅ | ✅ | |
| 66 | +| inferno_startburn | ✅ | ✅ | |
| 67 | +| inspect_weapon | ❌ | ✅ | |
| 68 | +| item_equip | ✅ | ❌ | |
| 69 | +| item_pickup | ✅ | ❌ | |
| 70 | +| item_pickup_slerp | ❌ | ✅ | |
| 71 | +| item_remove | ✅ | ❌ | |
| 72 | +| jointeam_failed | ❌ | ✅ | |
| 73 | +| other_death | ✅ | ✅ | |
| 74 | +| player_blind | ✅ | ❌ | |
| 75 | +| player_connect | ✅ | ✅ | |
| 76 | +| player_connect_full | ✅ | ✅ | |
| 77 | +| player_death | ✅ | ✅ | |
| 78 | +| player_disconnect | ✅ | ✅ | |
| 79 | +| player_falldamage | ✅ | ❌ | |
| 80 | +| player_footstep | ✅ | ❌ | |
| 81 | +| player_given_c4 | ❌ | ✅ | |
| 82 | +| player_hurt | ✅ | ✅ | |
| 83 | +| player_jump | ✅ | ❌ | |
| 84 | +| player_changename | ✅ | ✅ | |
| 85 | +| player_ping | ❌ | ✅ | |
| 86 | +| player_ping_stop | ❌ | ✅ | |
| 87 | +| player_spawn | ✅ | ✅ | |
| 88 | +| player_spawned | ❌ | ✅ | |
| 89 | +| player_team | ✅ | ✅ | |
| 90 | +| round_announce_final | ✅ | ✅ | |
| 91 | +| round_announce_last_round_half | ✅ | ✅ | |
| 92 | +| round_announce_match_point | ✅ | ✅ | |
| 93 | +| round_announce_match_start | ✅ | ✅ | |
| 94 | +| round_announce_warmup | ✅ | ✅ | |
| 95 | +| round_end | ✅ | ✅ | |
| 96 | +| round_end_upload_stats | ❌ | ✅ | |
| 97 | +| round_freeze_end | ✅ | ✅ | |
| 98 | +| round_mvp | ✅ | ✅ | |
| 99 | +| round_poststart | ✅ | ❌ | |
| 100 | +| round_prestart | ✅ | ❌ | |
| 101 | +| round_officially_ended | ✅ | ✅ | |
| 102 | +| round_start | ✅ | ✅ | |
| 103 | +| round_time_warning | ✅ | ✅ | |
| 104 | +| server_cvar | ✅ | ✅ | |
| 105 | +| show_survival_respawn_status | ? | ✅ | |
| 106 | +| smokegrenade_detonate | ✅ | ✅ | |
| 107 | +| smokegrenade_expired | ✅ | ✅ | |
| 108 | +| survival_paradrop_spawn | ? | ✅ | |
| 109 | +| switch_team | ❌ | ✅ | |
| 110 | +| tournament_reward | ✅ | ? | |
| 111 | +| vote_cast | ❌ | ✅ | |
| 112 | +| weapon_fire | ✅ | ✅ | |
| 113 | +| weapon_fire_on_empty | ✅ | ❌ | |
| 114 | +| weapon_reload | ✅ | ❌ | |
| 115 | +| weapon_zoom | ✅ | ❌ | |
| 116 | +| weapon_zoom_rifle | ❌ | ✅ | |
0 commit comments