Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local ref = gui.Reference("Visuals", "Other", "Effects")
- local noshadows_checkbox = gui.Checkbox(ref, "noshadows", "No Shadows", false)
- local function noshadows()
- if noshadows_checkbox:GetValue() then
- client.SetConVar("r_shadows", 0, true);
- client.SetConVar("cl_csm_static_prop_shadows", 0, true );
- client.SetConVar("cl_csm_shadows", 0, true );
- client.SetConVar("cl_csm_world_shadows", 0, true );
- client.SetConVar("cl_foot_contact_shadows", 0, true );
- client.SetConVar("cl_csm_viewmodel_shadows", 0, true );
- client.SetConVar("cl_csm_rope_shadows", 0, true );
- client.SetConVar("cl_csm_sprite_shadows", 0, true );
- else
- client.SetConVar("r_shadows", 1, true);
- client.SetConVar("cl_csm_static_prop_shadows", 1, true );
- client.SetConVar("cl_csm_shadows", 1, true );
- client.SetConVar("cl_csm_world_shadows", 1, true );
- client.SetConVar("cl_foot_contact_shadows", 1, true );
- client.SetConVar("cl_csm_viewmodel_shadows", 1, true );
- client.SetConVar("cl_csm_rope_shadows", 1, true );
- client.SetConVar("cl_csm_sprite_shadows", 1, true );
- end
- end
- noshadows()
- local function event(e)
- if e:GetName() == "round_start" then
- noshadows()
- end
- end
- client.AllowListener("round_start")
- callbacks.Register ("FireGameEvent", event)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement