FANDOM


Please Note: Script Enforcer has been shut down without any notice, Please read here.Edit

The Script Enforcer is a system to prevent users from running 3rd party scripts in your gamemode. This will help prevent the use of aimbots, radars, wallhacks and custom HUDs.

To protect your gamemode you need to generate a clientscripts.txt file. This is a list of 'allowed' files.

This is what should happen

If the client tries to run a script that isn't on the list (usually via autorun) it will fail.

If the user's file doesn't match the one on the server, it won't load, and they will be kicked from the server. This should rarely happen as they will have received most files via AddCSLuaFile, which means it will match. So this can only really happen if they've somehow managed to edit one of the base file that aren't sent on a server connect. Which they should never have done.

This is what really happens

The file itself is very simple, and typically will look like this

sandbox/gamemode/scoreboard/player_infocard.lua
sandbox/gamemode/scoreboard/admin_buttons.lua
sandbox/gamemode/scoreboard/vote_button.lua
sandbox/gamemode/scoreboard/player_frame.lua
weapons/weapon_base/cl_init.lua
weapons/weapon_base/shared.lua
weapons/weapon_ak47/shared.lua
weapons/weapon_cs_base/shared.lua
weapons/weapon_deagle/shared.lua
weapons/weapon_fiveseven/shared.lua
weapons/weapon_glock/shared.lua
weapons/weapon_m4/shared.lua
weapons/weapon_mac10/shared.lua
weapons/weapon_mp5/shared.lua
weapons/weapon_para/shared.lua
weapons/weapon_pumpshotgun/shared.lua
weapons/weapon_tmp/shared.lua
weapons/weapon_base/cl_init.lua
weapons/weapon_base/shared.lua
weapons/gmod_camera/cl_init.lua
weapons/gmod_camera/shared.lua
weapons/gmod_tool/cl_init.lua
weapons/gmod_tool/shared.lua

Generating Edit

You don't need to generate this file by hand. Simply join your server then run the console command:

scriptenforce_createmanifest

EnablingEdit

If your gamemode doesn't have a clientscripts.txt in its gamemode folder then Enforcer will be disabled.

To enable ScriptEnforcer, you must set the server-side console variable "sv_scriptenforcer" to 1 or 2. Setting it to 2 will ban clients temporarily if an MD5 of their Lua state does not match with my Lua.

Ad blocker interference detected!


Wikia is a free-to-use site that makes money from advertising. We have a modified experience for viewers using ad blockers

Wikia is not accessible if you’ve made further modifications. Remove the custom ad blocker rule(s) and the page will load as expected.