Garry’s Mod Modern Hardware Optimization in GMOD Tutorial

Garry’s Mod Modern Hardware Optimization in GMOD Tutorial 1 - steamsplay.com
Garry’s Mod Modern Hardware Optimization in GMOD Tutorial 1 - steamsplay.com

Improve your performance using modern variables with good looks, this guide aims to optimize inefficiencies while preserving as much eye candy as you can get.

Intro

This guide will greatly improve performance on modern hardware and avoid the crap and misinformation or lack of information within a lot of guides, I’ve noticed that source communities outside of TF2 seem to be, quite frankly, incompetent with cvars and how the source engine works. This guide is aimed at creating a balanced config for a modern PC, if you are on a potato you may convert the config I post (based off of but not the same as mastercomfig). https://docs.mastercomfig.com/latest/ – [mastercomfig.com]

This Guide a*sumes you are well accustomed to using a PC. If you are not please look up some basic tutorials on things like Central Processing Units, Graphics Cards, Memory, or you can just copy and paste the commands into your console/autoexec and call it a day.

Launch Options

-novid -nojoy -nosteamcontroller -particles 1 -precachefontchars +mat_dxlevel 100

Put this into your launch options inside of your game properties tab in steam.

-novid, removes the dumb source video, saving loading speed slightly.

-nojoy, disables joystick controls, who uses joysticks.

-nosteamcontroller self explanitory

-particles 1 Keeps particles to a minimum

-precachefontchars self explanitory (if you don’t know what precaching is look it up)

+mat_dxlevel 100 DirectX 9 with support for extra features, using dx8 on modern hardware is horrible in gmod and does absoutely nothing but hurt performance, use dx95.

Optional

-sw -h y -w x Windowed mode, can hurt performance, x is pixel width, y is pixel height

-no_texture_stream, if you are not stressed for memory, disabling texture streaming can improve performance

Autoexec PT.1

Copy and paste this entire thing into your autoexec.cfg, if you do not have one go to /GarrysMod/garrysmod/cfg and create a file called autoexec.cfg.

// ▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒

// ‘~~~~~~~~~ mastercomfig (Modified for GMOD by Bucket) ~~~~~~~~~’

// ———————————-

// Version: 9.6.4 | October 20, 2021

// ———————————-

// ▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒

// Full mastercomfig console variables list, check out modules too!

// https://docs.mastercomfig.com/page/customization/modules/ – [mastercomfig.com]

// Recommended launch options: -novid -nojoy -nosteamcontroller -particles 1 -precachefontchars

// =================

// ‘— Network —‘

// =================

// —————

// ‘– General –‘

// —————

// Optimizes for better networking

net_maxpacketdrop 0 // Use all packets

//net_maxpacketdrop 5000 // Use default packet drop threshold

cl_timeout 3600 // Max client timeout

//cl_smooth 1 // Do not instantly correct prediction errors, as they are predominantly small enough to be smoothed over with negligible error and has less distracting jitters in view

cl_smoothtime .05 // Decrease smooth time to reject large prediction errors faster

//cl_pred_optimize 2 // Keep client-side prediction

//net_queued_packet_thread 1 // Keep thread on in case we start sending split packets

//net_queued_packet_thread 581304 // Queue all packets

//net_splitrate 1 // Number of fragments for a splitpacket that can be sent per frame

//net_udp_rcvbuf 131072 // Game does not handle overflows correctly, so no point in setting this lower

net_chokeloop 1 // Early check for multiplayer

sv_lan 1 // Protect local servers

cl_localnetworkbackdoor 0 // Fast path to skip backdoor

host_limitlocal 1 // Prevent excess work on local

// Directly forward string cmds to server for lower latency

alias resetcla*s”cmd resetcla*s”

alias menuopen”cmd menuopen”

alias menuclosed”cmd menuclosed”

alias stop_taunt”cmd stop_taunt”

alias td_buyback”cmd td_buyback”

alias arena_changecla*s”cmd arena_changecla*s”

alias extendfreeze”cmd extendfreeze”

alias show_motd”cmd show_motd”

alias showroundinfo”cmd showroundinfo”

alias autoteam”cmd autoteam”

alias boo”cmd boo”

alias done_viewing_loot”cmd done_viewing_loot”

alias spectate”cmd spectate”

alias demorestart”cmd demorestart”

alias fade”cmd fade”

alias nextmap”cmd nextmap”

alias timeleft”cmd timeleft”

alias ignoremsg”cmd ignoremsg”

alias commentary_finishnode”cmd commentary_finishnode”

alias kill”cmd kill”

alias explode”cmd explode”

// ================================

// ‘— Interp and general net —‘

// ================================

cl_interp .022499;setinfo cl_interp .022499;cl_cmdrate 66;cl_updaterate 66;cl_interp_ratio 1;setinfo cl_interp_ratio 1;

net_compresspackets 0;net_splitpacket_maxrate 50000;net_compresspackets_minsize 4097;net_maxroutable 1200;net_maxfragments 1200;rate 1048576;net_maxfilesize 64;cl_downloadfilter all;net_maxcleartime 0;

// =============

// ‘— LOD —‘

// =============

r_rootlod 0;r_lod -1;

// Lighting

mat_filterlightmaps 1;r_ambientboost 1;r_lightaverage 1;r_dynamic 1;r_maxdlights 4;r_worldlightmin .0002;r_lightcache_zbuffercache 1;r_worldlights 12;mat_disable_lightwarp 0;mat_reducefillrate 0;r_rimlight 1;mat_bumpmap 1;mat_specular 1;building_cubemaps 1;

// Shadows

r_shadows 1;r_shadowrendertotexture 1;r_shadowmaxrendered 11;nb_shadow_dist 400

//Flashlight

mat_supportflashlight 1;r_flashlightculldepth 1;r_flashlightdepthres 1024;r_flashlightdepthtexture 1;r_flashlightmodels 1;r_flashlightrender 1;r_flashlightscissor 1

//Effects

tracer_extra 1;cl_show_splashes 1;cl_ejectbra*s 0;cl_drawmonitors 1;muzzleflash_light 0;cl_fasttempentcollision 5

//Water

r_WaterDrawReflection 1;r_waterforceexpensive 0;r_waterforcereflectentities 1;r_WaterDrawRefraction 1;r_cheapwaterstart 284;r_cheapwaterend 736

//Particles

mat_reduceparticles 0;cl_new_impact_effects 0;cl_particle_batch_mode 1;r_drawflecks 1;cl_particle_retire_cost .0001

//PP

mat_colcorrection_disableentities 0;r_bloomtintr .3;r_bloomtintg .59;r_bloomtintb .1;r_bloomtintexponent 2.2;mat_hdr_level 2;mat_colorcorrection 1;mat_bloom_scalefactor_scalar .75;

//MB

mat_motion_blur_enabled 0;

//AA

mat_alphacoverage 1;mat_antialias 2;mat_software_aa_strength 0;mat_software_aa_strength_vgui 0

//Face

r_flex 1;flex_rules 1;anim_3wayblend 1;r_teeth 1;flex_smooth 0;r_eyes 1;r_eyemove 1;blink_duration 0;phonemefilter .08;phonemedelay 0;phonemesnap 4

//Decals

r_decals 32;mp_decals 32;r_decal_cover_count 4;r_decal_overlap_area .4;r_decal_overlap_count 3;r_drawbatchdecals 1;

//Body Decals

r_drawmodeldecals 1;r_maxmodeldecal 9

//Sprays

r_renderoverlayfragment 1;cl_allowdownload 1;cl_allowupload 1;r_spray_lifetime 0;

//Gibs

cl_burninggibs 0;props_break_max_pieces 2;violence_hgibs 1;violence_hblood 1;violence_agibs 1;violence_ablood 1

//Props

r_drawdetailprops 1;cl_detaildist 1024;cl_detailfade 0;r_decalstaticprops 0;cl_phys_props_enable 0;r_staticprop_lod -1;r_propsmaxdist 0;lod_TransitionDist -1;

//Textures

mat_filtertextures 1;mat_picmip 0;mat_disable_fancy_blending 0;mat_forceaniso 4;

//Ropes

r_drawropes 1;rope_rendersolid 1;r_ropetranslucent 0;rope_smooth 0;rope_subdiv 1;rope_collide 0;rope_wind_dist 0

Autoexec PT.2

//Optimization

engine_no_focus_sleep 1 // Balance between power savings and background responsiveness

r_ForceWaterLeaf 1 // Optimization to visleafs

r_occlusion 1 // Use CPU to have the GPU skip rendering models/props you cannot see

r_fastzreject 1 // Early Z pa*s. Uses the CPU to prevent overdraw.

mat_tonemapping_occlusion_use_stencil 0 // Force disable stencil buffer for tonemapping

r_norefresh 1 // Do not store a useless and unused frame time variable

fast_fogvolume 1 // Fast path for one leaf water data

r_pixelfog 1 // Use a pixel shader for fog if possible

mod_offline_hdr_switch 1 // Skip outdated Source engine pathways

mat_forcemanagedtextureintohardware 0 // Do not do tricks to render textures into hardware

jpeg_quality 100 // JPEG quality percentage

mat_requires_rt_alloc_first 0 // Force disable, since new GPUs do not need to do this. Improves load times.

sys_minidumpspewlines 0 // Do not save any console output to a memory buffer in case of a crash

//r_shader_srgb 0 // Hardware caps for sRGB writes

sv_logdownloadlist 0 // Disable download list logging

mat_forcehardwaresync 1 // Keep the CPU submission within 1 to 2 frames of the GPU

mat_managedtextures 0 // Disable managed textures which do not work in D3D9Ex

mat_queue_mode -1 // Make sure ideal threading mode is on

//mat_bufferprimitives 1 // Skip flushing of primitives when meshes draw

//FPS Cap

fps_max 600;mat_powersavingsmode 0

//Memory

lzma_persistent_buffer 1 // Keep the LZMA compression system in memory to prevent reloads of it

cl_always_flush_models 0 // Keep models loaded in between map loads and keep preloading

//FS

filesystem_buffer_size 1 // 32KB buffer

//filesystem_buffer_size 0 // No buffer

filesystem_max_stdio_read 64 // Use a higher max read cap (64MB)

//MISC

bugreporter_uploadasync 1 // Upload bug reporter attachments asynchronously

ai_frametime_limit .015 // Use simpler NPC AI if the frametime is too low, useful for Source singleplayer and mods

//ai_frametime_limit 50 // Do not use simpler AI

//Models

mod_load_anims_async 1 // Async animation loading

mod_load_mesh_async 1 // Async mesh loading

mod_load_vcollide_async 1 // Async vcollide loading

mod_forcetouchdata 1 // Put all model data into cache on load

mod_forcedata 1 // Load submodel data and load lingering async loads

mod_touchalldata 1 // Load vcollide sync, load all peer data

mod_forcetouchdata 0 // Skip loading all model data into cache on load

mod_forcedata 0 // Async model cache does not force data by default

mod_touchalldata 0 // Load vcollide async and skip submodel loading

mod_dynamicunloadtime 150 // How long in seconds a dynamic model can be unused for before being unloaded

mod_dynamicunloadtex 1 // Unload textures when dynamic models are unloaded

//Threads

snd_async_fullyasync 1 // Skip sound cache, load all sounds async

snd_async_minsize 0 // ^

gmod_mcore_test 1

cl_threaded_bone_setup 1

//Sound

//volume 1 // Set the primary volume

//snd_musicvolume 1 // Set music volume

snd_mixahead .05 // How many seconds of the 44100 sample rate we mix. Value chosen as a fraction of samples.

snd_delay_sound_shift .001 // Reduce delay (risky with hitches)

//cl_soundemitter_flush // Command to clear out the loaded sounds file

//cl_soundscape_flush // Command to clear out the loaded soundscapes file

//snd_pitchquality 0 // Use linear mixer for sound, performance benefit

snd_pitchquality 1 // Use interpolated mixer for sound, sound quality increase

snd_disable_mixer_duck 0 // Enable mixing sounds to adjust volume

//snd_disable_mixer_duck 1 // Disable some sounds being mixed to be louder than others

//snd_surround_speakers -1 // Autodetect speaker configuration from OS

snd_surround_speakers 0 // Force headphones

//snd_surround_speakers 2 // Force mono/stereo

//snd_surround_speakers 4 // Force quad

//snd_surround_speakers 5 // Force 5.1

snd_legacy_surround 0 // Turn off legacy surround sound pathway

//windows_speaker_config -1 // Windows speaker configuration

//dsp_enhance_stereo 0 // Disable extra spatial DSP effects and delays

dsp_enhance_stereo 1 // Enable to apply spatial DSP effects to all channels

dsp_slow_cpu 0 // Use enhanced positional effects

//dsp_slow_cpu 1 // Disable initialization of enhanced spatialization

//snd_spatialize_roundrobin 1 // Spatialize sounds every 2 frames, less performance benefit

snd_spatialize_roundrobin 3 // Spatialize sounds every 8 frames (2^3) using round-robin algorithm. Pretty reasonable performance benefit, but delay in spatialization.

//snd_spatialize_roundrobin 0 // Spatialize every frame

//dsp_room 0 // Disable automatic DSP

dsp_room 1 // Enable automatic DSP, adjusts DSP according to the room type/size you are in

//dsp_speaker 50 // Administrator effect (can be 50 to 59)

dsp_speaker 0 // Disable administrator effect

//dsp_water 14 // Water muffling effect (small delay)

//dsp_water 15 // Water muffling effect (medium delay)

//dsp_water 16 // Water muffling effect (large delay)

dsp_water 0 // Disable water muffling effect

dsp_spatial 40 // Spatial delay effect for positional audio

//dsp_spatial 0 // Disable spatial effect

//snd_cull_duplicates 0 // Do not skip playing duplicate sounds

snd_cull_duplicates 1 // Only play one of each sound at a time

voice_steal 2 // Reuse unimportant sound channels, increases FPS and sound quality

snd_noextraupdate 1 // Do not update sound twice

snd_defer_trace 1 // Defer DSP spatialization with tracing to the next frame

//snd_defer_trace 0 // Immediately trace on the first frame

snd_async_spew_blocking 0 // Disable async spew

//Keyboard

in_usekeyboardsampletime 1 // Determine key time from smoothed frametime for keyboard look only

cl_yawspeed 210 // Yaw speed for keyboard look (+left, +right)

cl_pitchspeed 225 // Pitch speed for keyboard look (+lookup, +lookdown)

64 Bit Computing

32 bit is ancient and slow, GMOD thankfully supports 64 bit which comes with a HUGE performance and feature boost and allows for GMOD to handle more memory and crash less frequently.

Go to your properties tab by right clicking on your game in steam, press betas and choose x86-64 chromium.

Singleplayer

While running GMOD on singleplayer in sandbox, while you are not using an addon I highly advise disabling it, if you no longer plan on using an addon EVER again uninstalling it is recommended.

Things to be mindful of.

Gsync reduces max framerate on GMOD cause source engine is funny like that, if you want your maximums to increase but your stability to potentially decrease I recommend disabling it.

A lot of misinformation is spread about on the internet and it saddens me that so many believe it (like putting high priority on your games in windows, please never do this.)

Software that says it will improve your performance is likely to degrade your performance and siphon data from your PC, do not install fishy software.

Trusted software that actually can improve your performance

NVCleanInstall (Nvidia Drivers)

SDI (General Drivers)

Ryzen Master/Intel XTU

MSI Afterburner

DDU (Display Driver Uninstaller, fixes errors if you encounter any on your nvidia/amd drivers.)

WinAero (Can disable many telementary features of windows and enables a lot of cool stuff.)

TCP Optimizer (Improves web data transfer)

Chris Titus Tech’s Debloat script

Bloatware

Razer Cortex

Anything from ioBit

CCleaner

Defraggler

Anti Virus’ (Windows defender is MORE than enough)

Geforce Experience

Most microsoft apps

Not everything I put in this guide may be accurate in a few years time or maybe even now but I tried my hardest to find reliable resources I trust.

Conclusion

I hope I solved your performance issues running on modern hardware with GMOD, it saddens me there are no good guides out there for people these days to get a solid framerate in Garry’s Mod.

Written by Bucket

This is all for Garry’s Mod Modern Hardware Optimization in GMOD Tutorial hope you enjoy the post. If you believe we forget or we should update the post please let us know via comment, we will try our best to fix how fast is possible! Have a great day!


Be the first to comment

Leave a Reply

Your email address will not be published.


*