Built-In Engine Events

From Valve Developer Community
Jump to: navigation, search
Русский

Game event format

  • No spaces in event names, max length 32
  • All strings are case sensitive
  • total game event byte length must be < 1024
  • valid data key types are:
  • none : value is not networked
  • string : a zero terminated string
  • bool : unsigned int, 1 bit
  • byte : unsigned int, 8 bit
  • short : signed int, 16 bit
  • long : signed int, 32 bit
  • float : float, 32 bit
  • uint64 : unsigned int 64 bit
  • local : any data, but not networked to clients
  • The following key names are reserved:
  • local : if set to 1, event is not networked to clients
  • unreliable : networked, but unreliable
  • suppress : never fire this event
  • time : firing server time
  • eventid : holds the event ID


Core team events

  • team_info: info about team
  • teamid ( byte ): unique team id
  • teamname ( string ): team name (e.g. Team Blue)
  • team_score: team score changed
  • teamid ( byte ): team id
  • score ( short ): total team score
  • teamplay_broadcast_audio: emits a sound to everyone on a team
  • team ( byte ): unique team id
  • sound ( string ): name of the sound to emit

Player events

  • player_team: player change his team
  • userid ( short ): user ID on server
  • team ( byte ): team id
  • oldteam( byte ): old team id
  • disconnect( bool ): team change because player disconnects
  • autoteam( bool ): true if the player was auto assigned to the team
  • silent( bool ): if true wont print the team join messages
  • player_class: a player changed his class
  • userid ( short ): user ID on server
  • class ( string ): new player class / model
  • player_death [broken]: a game event, name may be 32 characters long
  • userid ( short ): user ID who died
  • attacker ( short ): user ID who killed
  • player_hurt [broken]
  • userid ( short ): player index who was hurt
  • attacker ( short ): player index who attacked
  • health ( byte ): remaining health points
  • player_chat: a public player chat
  • teamonly ( bool ): true if team only chat
  • userid( short ): chatting player
  • text( string ): chat text
  • player_score: players scores changed
  • userid ( short ): user ID on server
  • kills ( short ): # of kills
  • deaths ( short ): # of deaths
  • score ( short ): total game score
  • player_spawn: player spawned in game
  • userid ( short ): user ID on server
  • player_shoot: player shoot his weapon
  • userid ( short ): user ID on server
  • weapon ( byte ): weapon ID
  • mode ( byte ): weapon mode
  • player_use
  • userid ( short ): user ID on server
  • entity ( short ): entity used by player
  • player_changename
  • userid ( short ): user ID on server
  • oldname ( string ): players old (current) name
  • newname ( string ): players new name
  • player_hintmessage
  • hintmessage ( string ): localizable string of a hint
  • player_reconnected : the player reconnet to the game
  • event(local):the data include the realitive infomation

Game events

  • game_init: sent when a new game is started
  • game_newmap: send when new map is completely loaded
  • mapname ( string ): map name
  • game_start: a new game starts
  • roundslimit ( long ): max round
  • timelimit ( long ): time limit
  • fraglimit ( long ): frag limit
  • objective ( string ): round objective
  • game_end: a game ended
  • winner ( byte ): winner team/user id
  • round_start
  • timelimit ( long ): round time limit in seconds
  • fraglimit ( long ): frag limit in seconds
  • objective ( string ): round objective
  • round_end
  • winner ( byte ): winner team/user i
  • reason ( byte ): reason team won
  • message ( string ): end round message
  • round_start_pre_entity
  • teamplay_round_start: round restart
  • full_reset ( bool ): is this a full reset of the map
  • hostname_changed
  • hostname ( string )
  • difficulty_changed
  • newDifficulty ( short )
  • oldDifficulty ( short )
  • strDifficulty( string ): new difficulty as string
  • finale_start
  • rushes ( short )
  • game_message: a message send by game logic to everyone
  • target ( byte ): 0 = console, 1 = HUD
  • text ( string ): the message text
  • break_breakable
  • entindex ( long )
  • userid ( short )
  • material ( byte ): BREAK_GLASS, BREAK_WOOD, etc
  • break_prop
  • entindex ( long )
  • userid ( short )
  • npc_spawned
  • entindex ( long )
  • npc_replaced
  • old_entindex ( long )
  • new_entindex ( long )
  • entity_killed
  • entindex_killed( long )
  • entindex_attacker ( long )
  • entindex_inflictor ( long )
  • damagebits ( long )
  • entity_hurt
  • entindex_killed( long )
  • entindex_attacker ( long )
  • entindex_inflictor ( long )
  • damagebits ( long )
  • bonus_updated
  • numadvanced ( short )
  • numbronze ( short )
  • numsilver ( short )
  • numgold ( short )
  • player_stats_updated
  • forceupload ( bool )
  • achievement_event
  • achievement_name ( string ): non-localized name of achievement
  • cur_val ( short ): # of steps toward achievement
  • max_val ( short ): total # of steps in achievement
  • achievement_earned
  • player ( byte ): entindex of the player
  • achievement ( short ): achievement ID

): Used for a notification message when an achievement fails to write

  • achievement_write_failed
  • physgun_pickup
  • entindex ( long ): entity picked up
  • flare_ignite_npc
  • entindex ( long ): entity ignited
  • helicopter_grenade_punt_miss
  • user_data_downloaded: fired when achievements/stats are downloaded from Steam or XBox Live
  • ragdoll_dissolved
  • entindex ( long )
  • gameinstructor_draw
  • gameinstructor_nodraw
  • map_transition
  • instructor_server_hint_create :create a hint using data supplied entirely by the server/map.
  • hint_name ( string ): what to name the hint. For referencing it again later (e.g. a kill command for the hint instead of a timeout)
  • hint_replace_key ( string ): type name so that messages of the same type will replace each other
  • hint_target ( long ): entity id that the hint should display at
  • hint_activator_userid ( short ): userid id of the activator
  • hint_timeout ( short ): how long in seconds until the hint automatically times out, 0 = never
  • hint_icon_onscreen ( string ): the hint icon to use when the hint is onscreen. (e.g. icon_alert_red)
  • hint_icon_offscreen ( string ): the hint icon to use when the hint is offscreen. (e.g. icon_alert)
  • hint_caption ( string ): the hint caption. (e.g. #ThisIsDangerous)
  • hint_activator_caption ( string ): the hint caption that only the activator sees (e.g. #YouPushedItGood)
  • hint_color ( string ): the hint color in (r,g,b( format where each component is 0-255))
  • hint_icon_offset ( float ): how far on the z axis to offset the hint from entity origin
  • hint_range ( float ): range before the hint is culled
  • hint_flags ( long ): hint flags
  • hint_binding ( string ): bindings to use when use_binding is the onscreen icon
  • hint_allow_nodraw_target ( bool ): if false, the hint will disappear if the target entity is invisible
  • hint_nooffscreen ( bool ): if true, the hint will not show when outside the player view
  • hint_forcecaption ( bool ): if true, the hint caption will show even if the hint is occluded
  • hint_local_player_only ( bool ): if true, only the local player will see the hint
  • instructor_server_hint_stop :destroys a server/map created hint
  • hint_name ( string ): The hint to stop. Will stop ALL hints with this name
  • chat_new_message: the specified channel contains new messages
  • channel ( byte )
  • chat_members_changed: the specified channel has had players leave or join
  • channel ( byte )
  • game_rules_state_change: the state of game changes

Economy events

  • inventory_updated
  • itemdef ( short )
  • cart_updated
  • store_pricesheet_updated
  • gc_connected
  • item_schema_initialized
  • drop_rate_modified
  • event_ticket_modified

ModEvents

  • modifier_event
  • eventname ( string )
  • caster ( short )
  • ability ( short )
  • dota_player_kill
  • victim_userid ( short )
  • killer1_userid ( short )
  • killer2_userid ( short )
  • killer3_userid ( short )
  • killer4_userid ( short )
  • killer5_userid ( short )
  • bounty ( short )
  • neutral ( short )
  • greevil ( short )
  • dota_player_deny
  • killer_userid ( short )
  • victim_userid ( short )
  • dota_barracks_kill
  • barracks_id ( short )
  • dota_tower_kill
  • killer_userid ( short )
  • teamnumber ( short )
  • gold ( short )
  • dota_roshan_kill
  • teamnumber ( short )
  • gold ( short )
  • dota_courier_lost
  • teamnumber ( short )
  • dota_courier_respawned
  • teamnumber ( short )
  • dota_glyph_used
  • teamnumber ( short )
  • dota_super_creeps
  • teamnumber ( short )
  • dota_item_purchased( edit: not dota_item_purchase )
  • userid ( short )
  • itemid ( short )
  • dota_item_gifted
  • userid ( short )
  • itemid ( short )
  • sourceid ( short )
  • dota_rune_pickup
  • userid ( short )
  • type ( short )
  • rune ( short )
  • dota_rune_spotted
  • userid ( short )
  • rune ( short )
  • dota_item_spotted
  • userid ( short )
  • itemid ( short )
  • dota_no_battle_points
  • userid ( short )
  • reason ( short )
  • dota_chat_informational
  • userid ( short )
  • type ( short )
  • dota_action_item
  • reason ( short )
  • itemdef ( short )
  • message ( short )
  • dota_chat_ban_notification
  • userid( short )
  • dota_chat_event
  • userid ( short )
  • gold ( short )
  • message ( short )
  • dota_chat_timed_reward
  • userid ( short )
  • itmedef ( short )
  • message ( short )
  • dota_pause_event
  • userid ( short )
  • value ( short )
  • message ( short )
  • dota_chat_kill_streak
  • gold ( short )
  • killer_id ( short )
  • killer_streak ( short )
  • killer_multikill ( short )
  • victim_id ( short )
  • victim_streak ( short )
  • dota_chat_first_blood
  • gold ( short )
  • killer_id ( short )
  • victim_id ( short )
  • dota_player_update_hero_selection
  • tabcycle ( bool )
  • dota_player_update_selected_unit
  • dota_player_update_query_unit
  • dota_player_update_killcam_unit
  • dota_player_take_tower_damage
  • PlayerID ( short )
  • damage ( short )
  • dota_hud_error_message
  • reason ( byte )
  • message ( string )
  • dota_action_success
  • dota_starting_position_changed
  • dota_money_changed
  • dota_enemy_money_changed
  • dota_portrait_unit_stats_changed
  • dota_portrait_unit_modifiers_changed
  • dota_force_portrait_update
  • dota_inventory_changed
  • dota_item_picked_up
  • itemname ( string )
  • PlayerID ( short )
  • ItemEntityIndex( short )
  • HeroEntityIndex( short )
  • dota_inventory_item_changed
  • entityIndex ( short )
  • dota_ability_changed
  • dota_portrait_ability_layout_changed
  • dota_inventory_item_added
  • itemname ( string )
  • dota_inventory_changed_query_unit
  • dota_link_clicked
  • link ( string )
  • nav ( bool ): internal to item panel - preserve the nav stack
  • nav_back ( bool ): internal to item panel - preserve the nav stack
  • recipe ( short )
  • shop ( short ): show the item in a particular shop
  • dota_set_quick_buy
  • item ( string )
  • recipe ( byte )
  • toggle ( bool )
  • dota_quick_buy_changed
  • item ( string )
  • recipe ( byte )
  • dota_player_shop_changed
  • prevshopmask ( byte )
  • shopmask ( byte )
  • dota_player_show_killcam
  • nodes ( byte )
  • player ( short )
  • dota_player_show_minikillcam
  • nodes ( byte )
  • player ( short )
  • gc_user_session_created
  • team_data_updated
  • guild_data_updated
  • guild_open_parties_updated
  • fantasy_updated
  • fantasy_league_changed
  • fantasy_score_info_changed
  • player_info_updated
  • game_rules_state_change
  • match_history_updated
  • SteamID ( uint64 )
  • match_details_updated
  • matchID ( uint64 )
  • result ( byte )
  • live_games_updated
  • recent_matches_updated
  • Page ( short )
  • news_updated
  • persona_updated
  • SteamID ( uint64 )
  • tournament_state_updated
  • party_updated
  • lobby_updated
  • dashboard_caches_cleared
  • last_hit
  • PlayerID ( short )
  • EntKilled ( short )
  • FirstBlood ( bool )
  • HeroKill ( bool )
  • TowerKill ( bool )
  • player_completed_game
  • PlayerID ( short )
  • Winner ( byte )
  • player_reconnected
  • PlayerID ( short )
  • nommed_tree
  • PlayerID ( short )
  • dota_rune_activated_server
  • PlayerID ( short )
  • rune ( short )
  • dota_player_gained_level
  • player ( short )
  • level ( short )
  • dota_player_pick_hero
  • player ( short )
  • heroindex ( short )
  • hero ( string )
  • dota_player_learned_ability
  • player ( short )
  • abilityname ( string )
  • dota_player_used_ability
  • PlayerID ( short )
  • abilityname ( string )
  • dota_non_player_used_ability
  • abilityname ( string )
  • dota_ability_channel_finished
  • abilityname ( string )
  • interrupted ( bool )
  • dota_holdout_revive_complete
  • caster( short )
  • target( short )
  • dota_player_killed
  • PlayerID ( short )
  • HeroKill ( bool )
  • TowerKill ( bool )
  • bindpanel_open
  • bindpanel_close
  • keybind_changed
  • dota_item_drag_begin
  • dota_item_drag_end
  • dota_shop_item_drag_begin
  • dota_shop_item_drag_end
  • dota_item_purchased
  • PlayerID ( short )
  • itemname ( string )
  • itemcost ( short )
  • dota_item_used
  • PlayerID ( short )
  • itemname ( string )
  • dota_item_auto_purchase
  • item_id ( short )
  • dota_unit_event
  • victim ( short )
  • attacker ( short )
  • basepriority ( short )
  • priority ( short )
  • eventtype ( short ): EDOTAHeroChaseEventType
  • dota_quest_started
  • questIndex ( long ): entity index
  • dota_quest_completed
  • questIndex ( long ): entity index
  • gameui_activated
  • gameui_hidden
  • player_fullyjoined
  • userid ( short ): user ID on server
  • name ( string ): player name
  • dota_spectate_hero
  • entindex ( byte )
  • dota_match_done
  • winningteam ( byte ): The ID of the winning team
  • dota_match_done_client
  • set_instructor_group_enabled
  • group ( string )
  • enabled ( short )
  • joined_chat_channel
  • channelName ( string )
  • left_chat_channel
  • channelName ( string )
  • gc_chat_channel_list_updated
  • today_messages_updated
  • num_messages ( short )
  • file_downloaded
  • success ( bool )
  • local_filename ( string )
  • remote_url ( string )
  • player_report_counts_updated
  • positive_remaining ( byte )
  • negative_remaining ( byte )
  • positive_total ( short )
  • negative_total ( short )
  • scaleform_file_download_complete
  • success ( bool )
  • local_filename ( string )
  • remote_url ( string )
  • item_purchased
  • itemid ( short )
  • gc_mismatched_version
  • demo_skip
  • local (1)
  • playback_tick ( long ): current playback tick
  • skipto_tick ( long ): tick we're going to
  • user_message_list ( local ): CSVCMsgList_UserMessages
  • dota_hero_chase_list ( local ): CSVCMsgList_GameEvents
  • demo_start
  • local (1)
  • dota_combatlog_list ( local ): CSVCMsgList_GameEvents that are combat log events
  • dota_hero_chase_list ( local ): CSVCMsgList_GameEvents
  • dota_pick_hero_list ( local ): CSVCMsgList_GameEvents
  • demo_stop


  • map_shutdown
  • dota_workshop_fileselected
  • filename ( string )
  • dota_workshop_filecanceled
  • rich_presence_updated
  • dota_hero_random
  • userid ( short )
  • heroid ( short )
  • dota_rd_chat_turn
  • userid ( short )
  • dota_favorite_heroes_updated
  • profile_closed
  • item_preview_closed
  • dashboard_switched_section
  • section ( short )
  • dota_tournament_item_event
  • winner_count ( short )
  • event_type ( short )
  • dota_hero_swap
  • playerid1 ( byte )
  • playerid2 ( byte )
  • dota_reset_suggested_items : reset the purchased / checked off state of suggested items in the store
  • halloween_high_score_received
  • round ( short )
  • halloween_phase_end
  • phase ( byte )
  • team ( byte )
  • halloween_high_score_request_failed
  • round ( short )
  • dota_hud_skin_changed
  • skin ( string )
  • style ( byte )
  • dota_inventory_player_got_item
  • itemname ( string )
  • player_is_experienced
  • player_is_notexperienced
  • dota_tutorial_lesson_start
  • map_location_updated
  • richpresence_custom_updated
  • game_end_visible
  • antiaddiction_update
  • highlight_hud_element
  • elementname ( string )
  • duration ( float )
  • hide_highlight_hud_element
  • intro_video_finished
  • matchmaking_status_visibility_changed
  • practice_lobby_visibility_changed
  • dota_courier_transfer_item
  • full_ui_unlocked
  • client_connectionless_packet
  • local (1
  • buffer( (local
  • buffersize( long )
  • address( string )
  • hero_selector_preview_set
  • setindex( short )
  • antiaddiction_toast
  • message ( string )
  • duration ( float )
  • hero_picker_shown
  • hero_picker_hidden
  • dota_local_quickbuy_changed
  • show_center_message
  • message ( string )
  • duration ( float )
  • clear_message_queue ( bool )
  • hud_flip_changed
  • flipped ( bool )
  • frosty_points_updated
  • defeated
  • entindex ( short )
  • reset_defeated
  • booster_state_updated
  • event_points_updated
  • event_id ( short )
  • points ( short )
  • premium_points ( short )
  • local_player_event_points
  • points ( short )
  • conversion_rate ( short )
  • custom_game_difficulty
  • difficulty ( byte )
  • tree_cut
  • tree_x ( float )
  • tree_y ( float )
  • ugc_details_arrived
  • published_file_id ( uint64 )
  • ugc_subscribed
  • published_file_id ( uint64 )
  • ugc_unsubscribed
  • published_file_id ( uint64 )
  • prizepool_received
  • success ( bool )
  • prizepool ( uint64 )
  • leagueid ( uint64 )
  • microtransaction_success
  • txnid ( uint64 )
  • dota_rubick_ability_steal
  • abilityIndex ( short )
  • abilityLevel ( byte )
  • compendium_event_actions_loaded
  • account_id ( uint64 )
  • league_id ( uint64 )
  • local_test( bool )
  • original_points ( uint64 )
  • compendium_selections_loaded
  • account_id ( uint64 )
  • league_id ( uint64 )
  • local_test( bool )
  • compendium_set_selection_failed
  • account_id ( uint64 )
  • league_id ( uint64 )
  • local_test( bool )
  • community_cached_names_updated