Garry's Mod Logo
add_circle

Features

  • Added physenv.SetTimeScale & physenv.GetTimeScale
  • Added Player:GetFlashlightColor
  • Added 5th optional argument to Entity:Dissolve - delay
  • Added 2 new STUDIO enum flags - STUDIO_SKIP_FLEXES, STUDIO_SKIP_DECALS
  • Added math.Sign (Community Contribution)
  • Added new optional argument to steamworks.GetList - search string
  • Added cam.GetProjectionMatrix and cam.GetViewMatrix
  • Added CSoundPatch:GetSoundName
  • Added 3 new formats for render.Capture - "rgba", "rgb" and "bgra"
  • Added timer.IsPaused
  • Added new argument to steamworks.FileInfo - bool extraInfo
  • Added Entity:EmitStepSound
  • Added CNavArea:GetLightIntensity - nav meshes must be updated with nav_update_lighting to generate necessary data
  • Implement ENTITY:OnTraceAttack for ai and anim type SENTs
  • Added util.IntersectRayWithTriangle
  • Added 2nd return to util.IntersectRayWithPlane - dist
  • Added language.FormatPhrase
  • Added player_manager.GetAllPlayerModels that includes categories/nice names
  • Added 2 new arguments to player_manager.AddValidModel - nice name and category
  • Added util.IsPlayerSpeaking
  • Added DColorMixer:SetPaletteName
  • Added player_manager.RemoveValidModel
  • Added render.BindLocalCubemap
  • Panel:RebuildSpawnIconEx now accepts "lightbox" and "lights" keys
  • Added CMoveData:RemoveKey helper function
arrow_circle_up

Improvements

  • GM:PostPlayerDraw now throws a non halting error when an infinite loop is broken to let developers know there's an issue
  • string.ToColor can now accept inputs without alpha channel (Community Contribution)
  • Added cyclic table reference test to net.WriteTable and util.TableToKeyValues to prevent game hangs and developer confusion
  • Reworked cvars.AddChangeCallback filter
  • Convars that cannot be identified as server only or client only now run the callback in both realms
  • FCVAR_PROTECTED convars no longer run this callback at all
  • Reset surface.SetAlphaMultiplier every frame
  • Switched Lua timers to use double precision curtime
  • resource.AddWorkshop bails when given empty input or input that is too short - Also throws non halting error with lua_strict 1
  • Make render.ComputeLighting 2nd argument optional
  • Optimized file path related functions in string library (Community Contribution)
  • sound.Add throws errors when given no "name" or "sound" fields
  • Optimizations for Vector:ToColor and Entity:BeingLookedAtByLocalPlayer (Community Contributions)
  • Narrow down PhysObj:SetMass input checks to prevent crashes (from 0 to 0.1 as minimum)
  • GM:PlayerStartVoice & GM:PlayerEndVoice now get called consistently even if the player entity does not exist. They also both consistently get the PlayerIndex argument
  • Make DHorizontalDivider work with percentages instead of raw pixel values - This helps when resizing the parent panel, and when screen resolution changes between game sessions
  • Make DColorMixer palette centered and attempt to size it correctly to fit an even number of colors per row
  • render.SetLocalModelLights sets missing lights in the input table to disabled state
  • Changed order of GM:DrawOverlay, GM:PostRenderVGUI and GM:PostRender hooks so they cannot cover up the main menu when it is open
  • Disabled GM:PreRender return value (kill all game rendering) while main menu is open
  • Made Lua VGUI panels never overlap the main menu when it is open
  • Allow Lua matproxies without a bind function (so only init is ran per material instance)
  • Apply "10+ loop deep" error to GM:PrePlayerDraw as well (Was only activated for GM:PostPlayerDraw before)
  • Do not clamp flexes of C_BaseFlex entities when set from Lua on clientside only entities
  • Make Entity:GetHitboxSetCount return a number instead of nil for entities without a model, etc.
handyman

Fixed

  • Player:UnSpectate now fully cleans up values set on the player by Player:Spectate
  • Fixed Player:Spectate sending 3 useless usermessages to the player
  • Fixed "all keys are 0" check in util.KeyValuesToTablePreserveOrder to work like intended
  • Fixed GM:Think hook serverside running when server is paused (double curtime to float truncation issue)
  • Fixed cookie.GetString not returning consistent types, not returning values set right after cookie deletion (Community Contribution)
  • Fixed Entity:Remove removing stuff prematurely when crazy physics is involved
  • Made bone manipulations not hijack Entity:SetRenderBounds calls, nullifying them
  • Fixed returning from GM:PreDrawSkyBox causing area portals to flicker
  • Fixed DPanelList ownLine handling
  • Fixed DPanelSelect re-running ConVars for each added item on creation
  • Fixed DColorMixer:GetVector being always 1 change behind - This changes GetColor in DColorMixer:ValueChanged to be the new value
  • Try to make Entity:IsPlayerHolding more reliable
  • ColorToHSV no longer truncates returned hue to integer
  • Fixed DLabel:SetDisabled always calling Panel:InvalidateLayout, even when the enabled value did not change
  • Fixed string.FormattedTime returning incorrect millisecond value (divided by 10)
  • Fixed couple potential Lua stack corruption issues with GM:CreateClientsideRagdoll and GM:EntityEmitSound hooks
  • Fixed IMesh:BuildFromTriangles reading bone weights from the wrong table
remove_circle

Removed

  • Blocked various convars (ones that save between sessions) from being modifiable by Lua
  • Removed built-in "VehicleMemDupe" entity modifier - Appears to really just do nothing useful