Day of Defeat: Source/Scripting/Game Events
This article lists game events in Day of Defeat: Source. These were retrieved from serverevents.res
, gameevents.res
and modevents.res
in the resource
folder.

params.class
, as class
is a reserved word in Squirrel. Instead, use string indexing like so: params["class"]

scripts/vscripts/
folder and run script_execute showevents
in console.achievement_earned
- player (byte) - entindex of the player
- achievement (short) - achievement ID
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_increment
- achievement_id (long) - ID of achievement that went up
- cur_val (short) - # of steps toward achievement
- max_val (short) - total # of steps in achievement
ammo_pickup
- ammo_index (long)
- amount (long)
- total (long)
base_player_teleported
- entindex (short)
bonus_updated
- numadvanced (short)
- numbronze (short)
- numsilver (short)
- numgold (short)
break_breakable
- entindex (long)
- userid (short)
- material (byte) - BREAK_GLASS, BREAK_WOOD, etc
break_prop
- entindex (long)
- userid (short)
browse_replays
cart_updated
christmas_gift_grab
- userid (short)
client_beginconnect
client tries to connect to server
- address (string) - Name we used to connect to the server
- ip (long)
- port (short) - server port
- source (string) - what caused us to attempt this connection? (blank for general command line, "serverbrowser", "quickplay", etc)
client_connected
client has completed the challenge / handshake process and is in SIGNONSTATE_CONNECTED
- address (string) - Name we used to connect to the server
- ip (long)
- port (short) - server port
client_disconnect
client side disconnect message
- message (string) - Why are we disconnecting? This could be a localization token or an English-language string
client_fullconnect
- address (string) - Name we used to connect to the server
- ip (long)
- port (short) - server port
dod_allies_ready
dod_axis_ready
dod_bomb_defused
- cp (byte) - index of the point where the bomb was defused
- cpname (string) - name of the point
- userid (short) - user ID of the player that defused the bomb
- team (byte) - team that defused
dod_bomb_exploded
- cp (byte) - index of the point where the bomb exploded
- cpname (string) - name of the point
- userid (short) - user ID of the player that planted the bomb
dod_bomb_planted
- cp (byte) - index of the point where the bomb was planted
- cpname (string) - name of the point
- userid (short) - user ID of the player that planted the bomb
- team (byte) - team that planted
dod_broadcast_audio
Used for the round victory music; both clientside and serverside.
- sound (string) - sound to play
dod_capture_blocked
- cp (byte) - index of the point that was blocked
- cpname (string) - name of the point
- blocker (byte) - index of the player that blocked the cap
- bomb (bool) - was the block on a defuse or a plant?
dod_game_over
- reason (string) - why the game is over ( timelimit, winlimit )
dod_hint
- hintmessage (string) - localizable string of a hint
dod_kill_defuser
- userid (short) - user ID of the player killed the defuser
- victimid (short) - user ID of the player that was killed
dod_kill_planter
- userid (short) - user ID of the player killed the planter
- victimid (short) - user ID of the player that was killed
dod_map_time_remaining
- seconds (short)
dod_point_captured
- cp (byte) - index of the point that was captured
- cpname (string) - name of the point
- cappers (string) - string where each character is a player index of someone that capped
- bomb (bool) - was this a bomb exploding
dod_ready_restart
dod_restart_round
dod_round_active
called when round is active, players can move
dod_round_restart_seconds
- seconds (short)
dod_round_start
dod_round_win
- team (byte) - which team won the round
dod_stats_player_damage
- attacker (short) - userid of the attacker
- victim (short) - userid of the victim
- weapon (byte) - weapon id
- damage (short) - total damage in this shot
- damage_given (byte) - applied damage, not to exceed health
- distance (float) - distance of the shot
- hitgroup (byte) - hitgroup that was hit
dod_stats_player_killed
- attacker (byte)
- victim (byte)
- weapon (byte)
dod_stats_weapon_attack
- attacker (short)
- weapon (byte)
dod_team_scores
- allies_caps (short) - how many rounds won by Allies
- allies_tick (short) - how many tick points Allies have
- allies_players (byte) - how many players Allies have
- axis_caps (short) - .. same for Axis.
- axis_tick (short)
- axis_players (byte)
dod_tick_points
- team (byte) - which team scored tick points
- score (byte) - how many did they score
- totalscore (short) - the new total score
dod_timer_flash
- time_remaining (short) - how many seconds until the round ends
dod_timer_time_added
- seconds_added (short) - how many seconds were added to the round timer
dod_tnt_pickup
dod_warmup_begins
dod_warmup_ends
dod_win_panel
- show_timer_defend (bool)
- show_timer_attack (bool)
- timer_time (short)
- final_event (byte) - 0 - no event, 1 - bomb exploded, 2 - flag capped, 3 - timer expired
- category_left (byte) - 0-4: none, bombers, cappers, defenders, killers
- left_1 (byte) - player index if first
- left_score_1 (byte)
- left_2 (byte)
- left_score_2 (byte)
- left_3 (byte)
- left_score_3 (byte)
- category_right (byte)
- right_1 (byte)
- right_score_1 (byte)
- right_2 (byte)
- right_score_2 (byte)
- right_3 (byte)
- right_score_3 (byte)
econ_inventory_connected
enter_vehicle
- vehicle (long) - entindex of the vehicle
entered_performance_mode
entity_killed
- entindex_killed (long)
- entindex_attacker (long)
- entindex_inflictor (long)
- damagebits (long)
flare_ignite_npc
- entindex (long) - entity ignited
freezecam_started
game_end
a game ended
- winner (byte) - winner team/user id
game_init
sent when a new game is started
game_message
a message send by game logic to everyone
- target (byte) - 0 = console, 1 = HUD
- text (string) - the message text
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
gameui_activate
gameui_hide
gc_lost_session
gc_new_session
helicopter_grenade_punt_miss
hide_freezepanel
hltv_changed_mode
- oldmode (short)
- newmode (short)
- obs_target (short)
hltv_changed_target
- mode (short)
- old_target (short)
- obs_target (short)
host_quit
inventory_updated
item_schema_initialized
leave_vehicle
- vehicle (long) - entindex of the vehicle
physgun_pickup
- entindex (long) - entity picked up
player_activate
- userid (short) - user ID on server
player_changeclass
- userid (short) - user ID who changed class
- class (short) - class that they changed to
player_changename
- userid (short) - user ID on server
- oldname (string) - players old (current) name
- newname (string) - players new name
player_chat
a public player chat
- teamonly (bool) - true if team only chat
- userid (short) - chatting player
- text (string) - chat text
player_class
a player changed his class
- userid (short) - user ID on server
- class (string) - new player class / model
player_connect
a new client connected - we should only really have server listeners for this, due to the IP being exposed
- name (string) - player name
- index (byte) - player slot (entity index-1)
- userid (short) - user ID on server (unique on server)
- networkid (string) - player network (i.e steam) id
- address (string) - ip:port
- bot (short) - is a bot
player_connect_client
a new client connected
- name (string) - player name
- index (byte) - player slot (entity index-1)
- userid (short) - user ID on server (unique on server)
- networkid (string) - player network (i.e steam) id
- bot (short) - is a bot
player_death
- userid (short) - user ID who died
- attacker (short) - user ID who killed
- weapon (string) - weapon name killed used
- dominated (bool)
- revenge (bool)
player_disconnect
a client was disconnected
- userid (short) - user ID on server
- reason (string) - "self", "kick", "ban", "cheat", "error"
- name (string) - player name
- networkid (string) - player network (i.e steam) id
- bot (short) - is a bot
player_hintmessage
- hintmessage (string) - localizable string of a hint
player_hurt
- userid (short) - user ID who was hurt
- attacker (short) - user ID who attacked
- weapon (string) - weapon name attacker used
- health (byte) - health remaining
- damage (byte) - how much damage in this attack
- hitgroup (byte) - what hitgroup was hit
player_info
a player changed his name
- name (string) - player name
- index (byte) - player slot (entity index-1)
- userid (short) - user ID on server (unique on server)
- networkid (string) - player network (i.e steam) id
- bot (bool) - true if player is a AI bot
player_say
- userid (short) - user ID on server
- text (string) - the say 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_shoot
player shoot his weapon
- userid (short) - user ID on server
- weapon (byte) - weapon ID
- mode (byte) - weapon mode
player_spawn
player spawned in game
- userid (short) - user ID on server
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
- name (string) - player's name
player_use
- userid (short) - user ID on server
- entity (short) - entity used by player
ragdoll_dissolved
- entindex (long)
replay_saved
replay_youtube_stats
- views (long)
- likes (long)
- favorited (long)
round_end
- winner (byte) - winner team/user i
- reason (byte) - reson why team won
- message (string) - end round message
round_start
- timelimit (long) - round time limit in seconds
- fraglimit (long) - frag limit in seconds
- objective (string) - round objective
server_addban
- name (string) - player name
- userid (short) - user ID on server
- networkid (string) - player network (i.e steam) id
- ip (string) - IP address
- duration (string) - length of the ban
- by (string) - banned by...
- kicked (bool) - whether the player was also kicked
server_changelevel_failed
- levelname (string) - The level name that failed changelevel
server_cvar
a server console var has changed
- cvarname (string) - cvar name, eg "mp_roundtime"
- cvarvalue (string) - new cvar value
server_message
a generic server message
- text (string) - the message text
server_removeban
- networkid (string) - player network (i.e steam) id
- ip (string) - IP address
- by (string) - removed by...
server_shutdown
server shut down
- reason (string) - reason why server was shut down
server_spawn
send once a server starts
- hostname (string) - public host name
- address (string) - hostame, IP or DNS name
- ip (long)
- port (short) - server port
- game (string) - game dir
- mapname (string) - map name
- maxplayers (long) - max players
- os (string) - WIN32, LINUX
- dedicated (bool) - true if dedicated server
- password (bool) - true if password protected
show_freezepanel
- killer (short) - entindex of the killer entity
single_player_death
spec_target_updated
store_pricesheet_updated
take_armor
- amount (long)
- total (long)
take_health
- amount (long)
- total (long)
- entindex (long)
team_info
info about team
- teamid (byte) - unique team id
- teamname (string) - team name eg "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
user_data_downloaded
fired when achievements/stats are downloaded from Steam or XBox Live
vote_cast
- vote_option (byte) - which option the player voted on
- team (short)
- entityid (long) - entity id of the voter
- voteidx (long)
vote_changed
- vote_option1 (byte)
- vote_option2 (byte)
- vote_option3 (byte)
- vote_option4 (byte)
- vote_option5 (byte)
- potentialVotes (byte)
- voteidx (long)
vote_ended
vote_failed
- team (byte)
- voteidx (long)
vote_options
- count (byte) - Number of options - up to MAX_VOTE_OPTIONS
- option1 (string)
- option2 (string)
- option3 (string)
- option4 (string)
- option5 (string)
- voteidx (long)
vote_passed
- details (string)
- param1 (string)
- team (byte)
- voteidx (long)
vote_started
- issue (string)
- param1 (string)
- team (byte)
- initiator (long) - entity id of the player who initiated the vote
- voteidx (long)
weapon_equipped
- class (string)
- entindex (long)
- owner_entindex (long)