--File: example.lua if SERVER then AddCSLuaFile("example.lua") end --This makes the clients download and execute this file function propSelect() --This function is shared (it's defined both server and client-side) if SERVER then --Here you do what you need to do server-side end if CLIENT then DrawBeam() end end if CLIENT then --This block is only executed by the client-side function DrawBeam() --Here you do the trace from the player and draw the beam effect end end