A disgusting pile of loose-knit, à la carte scripts for Garry's Mod
Halt! Are you 100% sure your idea doesn't fit better in its own repo, or perhaps another one of our addons? Loose-knit script repos like this are in danger of turning into a unmaintainable dumping ground. Please do your best to keep it clean and reasonable.
All scripts should follow these rules:
- Be contained to a single directory under
lua/cfc_gmod_scripts/
- Have an
init.lua
at the root of their directory - Have a section in this README under the Included Scripts category
- Ideally, have a convar to enable/disable them
All shared/server scripts have a convar to enable/disable them. Where relevant, these convars are replicated to the client, so the the server can easily disable them for both realms.
Unless otherwise stated, all config convars are:
FCVAR_ARCHIVE
'd- Prefixed with
cfc_gmodscripts_
- Default to
1
(enabled) - Replicated to the client (for shared scripts)
- Server Prevents players from spam rejoining the server to spam chat messages.
cfc_gmodscripts_anti_joinspam
(1/0
)
- Client
Fixes on-tick
hudScaler
error spam with the CW 2.0 Melee Base
cfc_gmodscripts_anti_joinspam
(1/0
)
Disables annoying bloom for maps that use bloom.
- Shared Limits the effects that players can spawn to a pre-defined whitelist.
This affects:
- Manually spawning effects
- Spawning effects with E2's Effect Core
- Spawning effects with Starfall's Effect library
More effects can be whitelisted by adding them to the global GmodScripts.EffectWhitelist
table.
hook.Add( "InitPostEntity", "example", function()
GmodScripts.EffectWhitelist["my_effect"] = true
end )
cfc_gmodscripts_effect_whitelist
- Server
Fixes a silly (but absurdly spammy)
nil
error that occurrs in a popular L4D2 SimfPhys Vehicle Pack (this fix has already been proposed upstream, but the author doesn't appear to want to implement it)
cfc_gmodscripts_l4d2_handbrake_fix
- Client Fixes some spammy Lua errors on the base Mobenix map
- Server Removes certain net messages that are never used or useless for our usecase.
cfc_gmodscripts_remove_bad_net_receivers
- Server Fixes a situation where users/regulars use Team chat and cannot be seen by others. Forces those ranks to use global chat even if they use Team chat.
cfc_gmodscripts_public_team_chat
- Server
Fixes a weird Garry's Mod exploit that happens if a player issues an absurd amount of
Use
commands on a single entity.
cfc_gmodscripts_player_pickup_fix
- Server
Fixes a crash that occurs on Linux servers that use
debugoverlay.Sphere
env_projectedtexture
entities with the enableshadow
property enabled (as in wire lights and lamps) appear to cause a huge amount of clientside lag when they face other props (and cast shadows)
This disables the enableshadow
property on all newly created env_projectedtexture
entities.
- Shared
Uses the
cfc_remove_tabs
addons' hooks to allow Moderators+ access to NPCs.
cfc_gmodscripts_rank_restrict_removetabs
- Shared Prevents configured weapon classes to be prevented from loading, such as abusive admin weapons.
cfc_gmodscripts_remove_sweps
- Client Replicates the Simple Armor Display addon
- Client
Forces clients to use the new
gmod_uncache_test
convar at a value of1
, which should reduce crashes
- Client
Clientside fix that forces clients to run
r_flushlod
if they join when the server has a short uptime
- Shared Fixes a bug where using Proper Clipping on a dropped weapon would crash the server
cfc_gmodscripts_weapon_clip_fix
- Server Prints ULX-like logs when a player spawns a Wiremod entity (either with the toolgun or AdvDupe2)
cfc_gmodscripts_wire_entspawn_alert