Skip to content

Instantly share code, notes, and snippets.

@h4xrOx
Created June 11, 2022 16:17
Show Gist options
  • Select an option

  • Save h4xrOx/7a1eec0458dc0c3b1ffb3bf73b6ebe80 to your computer and use it in GitHub Desktop.

Select an option

Save h4xrOx/7a1eec0458dc0c3b1ffb3bf73b6ebe80 to your computer and use it in GitHub Desktop.
Useful info for Source Engine Games Mod / Cheat
#**Console Commands**
#various Source engine games
```
changelevel [map] // Changes to specified map. Used when you're already loaded into a map. Use "map" command to launch from main menu.
connect [ip:port] // Join a server
cl_ragdoll_fade_time [#] // Seconds before ragdolls disappear
differences // Shows all CVars which are not at their default values
disconnect // Disconnect from server
ent_fire <entity> <commands> // Cheat. Executes commands on specified entity. Use "ent_fire !picker" to choose entity at crosshair.
ent_remove // Cheat. Removes targeted entity
ent_setname <name> // Cheat. Sets name of targeted entity (even a player)
ent_text // Cheat. Displays info (including model) on entity under crosshair.
exec [file].cfg // Executes any commands in example.cfg located in left4dead2/cfg directory.
give [item] // Cheat. Gives you an item.
give health // Cheat. Gives you full health and revives you if incapped
god [0/1] // Cheat. Disable/enable god mode (can't die)
firstperson // Cheat. Switch to first-person view
hidehud 4 // Cheat. Hides the whole HUD. Use hidehud 0 to reenable.
host_timescale [#] // Cheat. Changes time scale. Example: 0.5 half speed, 1.0 normal, 2.0 double
impulse 107 // Cheat. Prints to console the material player is aiming at. Only works on brushes (not models). Use mat_crosshair instead, which works on displacements too.
kill // Commit suicide
map [map_name] // Launches listen server on specified map
mat_crosshair // Cheat. Identify material under crosshair.
mat_reloadallmaterials // Cheat. Reloads all materials and textures.
mat_reloadmaterial models/props_junk/gnome // Cheat. Reloads a material (VMT) and texture (VTF) by name. Path is relative to materials folder.
mat_surfacemat [0/1] // Displays brush material names.
mp_decals [#] // Maximum # of decals allowed on server
noclip // Toggle no clipping mode
openserverbrowser // Cheat. Open old server browser interface
picker // Cheat. Highlights entity you're aiming at
prop_crosshair // Shows info about prop under crosshair
prop_dynamic_create props_fortifications/fencesmash.mdl // Cheat. Create dynamic prop at crosshair
prop_physics_create props_junk/wood_crate001a.mdl // Cheat. Create physics prop at crosshair
r_decals [#] // Def 2048. Maximum # of decals
r_drawvgui [0/1] // Cheat. Hides all HUD elements, including the console, so be sure to bind "r_drawvgui 1" to get it back. Useful because you can still change weapons.
r_drawviewmodel [0/1] // Cheat. Disable/enable viewmodel
r_farz [#] // Cheat, Def -1. Stops rendering anything at specified distance from you. Default -1 uses map-specific value in env_fog_controller entity.
respawn // Respawns you
snd_restart // Restarts the sound system. Great for testing replaced sounds in GMod, doesn't work for games like L4D2 with load them from VPKs.
snd_show 1 // Displays info about currently playing sounds
snd_visualize 1 // Displays info about currently playing sounds
status // Displays info about current server, including players, map and IP address
sv_cheats 1 // Enable cheat commands
thirdperson // Cheat. Enables third-person camera
thirdpersonshoulder // Toggles third-person-shoulder view
script Convars.SetValue("fps_max",60) // Forces specified CVar to a value. For example, just entering "fps_max 60" won't do anything. This command does.
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment