|We're building a new wiki, so information on this page may be out of date.|
Source Pause Tool
Source Pause Tool is a plugin for OrangeBox Engine games that automatically pauses the game on loads and level transitions thus allowing the player to take control of the game and start recording a demo as soon as possible (or stop a demo in the level transition case). It also contains other helpful speedrunning-related stuff.
Grab the latest release from here. You can find the source code there as well. If something utterly breaks, that is also the place to complain by reporting issues.
- Place spt.dll into the your game's directory (hl2, portal, ep2, etc.). For Old Engine, put spt-oe.dll in the bin directory beside hl2.exe.
- Enter plugin_load spt into the game console.
- Unless there are some warnings (which you can report here in case you need the functionality), everything should work!
- Note that for plugin loading to be enabled your game should be running in insecure mode. To launch the game in insecure mode add -insecure to the launch parameters. Singleplayer games are usually not VAC-protected so launch in insecure mode by default.
- y_spt_pause (0 | 1 | 2) - if 1, then the plugin pauses right after the game load, this is the most useful behaviour. If 2, the plugin pauses at the earliest possible moment, which is not very useful, because nothing has been loaded yet. If anything else, then the plugin doesn't pause the game at all.
- y_spt_autojump (0 | 1) - if 1, automatically jumps on landing while you hold your jump button.
- y_spt_autojump_ensure_legit (0 | 1) - if 1, makes sure that at no times consecutive jumps occur (jumps on two consecutive ticks), those jumps are not normally possible because you have to release the jump button for one tick before pressing it again.
- y_spt_motion_blur_fix (0 | 1) - if 1, makes the in-game motion blur (toggled in Video Settings or through the mat_motion_blur_enabled console variable) obey host_framerate and/or host_timescale time modifications (game running slower than normally or faster than normally), this is useful if you want to make, for example, slowmotion renders with the in-game motion blur.
- y_spt_additional_abh (0 | 1) - if 1, emulates ABH on each jump. Useful (and works) only in Black Mesa because ABH in Black Mesa is fun.
- _y_spt_afterframes_reset_on_server_activate (0 | 1) if 1, resets the afterframes queue on a map load.
- _y_spt_afterframes <count> <command> - inserts command into the afterframes queue to be executed after count frames have been drawn to the screen. Especially useful in conjunction with host_framerate.
- _y_spt_afterframes2 <count> <command> - same as the former, but takes the rest of the argstring as a command. Example: _y_spt_afterframes 5 "echo hi";_y_spt_afterframes2 5 echo hi.
- _y_spt_setpitch <pitch> and _y_spt_setyaw <yaw> set the pitch and yaw to the specified values on the next clientside angle adjustment call. Also _y_spt_setangles <pitch> <yaw> sets both angles.
- _y_spt_pitchspeed <speed> and _y_spt_yawspeed <speed> work exactly the same as cl_pitchspeed and cl_yawspeed with the respective keys active (+right, +lookup, etc.), but are more consistent.
- _y_spt_getvel - outputs the current player velocity into the console.
- _y_spt_getangles - outputs the view angles of the player.
Experimental timer commands
- y_spt_timer_start - starts the SPT timer.
- y_spt_timer_stop - stops the SPT timer and prints the current time.
- y_spt_timer_reset - stops and resets the SPT timer.
- y_spt_timer_print - prints the current time of the SPT timer.
- +y_spt_duckspam along with its "-" counterpart presses +duck every other frame when enabled.
- y_spt_cvar <name> [value] - obtains the info about the specified convar, or sets it if the value is present. The value is the rest of the argstring, so for example y_spt_cvar name Sample Name will set the "name" cvar to Sample Name, and y_spt_cvar name "Sample Name" will set the cvar to "Sample Name".
- _y_spt_tickrate <tickrate> - gets or sets the tickrate.