anders = {} anders.s = 1 anders.t = false function anders.hostscale () if anders.s > 1 then anders.s = 1 anders.t = true end if anders.s < 0 then anders.s = 0 anders.t = false end if anders.t then anders.s = anders.s - 0.1 else anders.s = anders.s + 0.1 end _ServerCommand("phys_timescale "..anders.s.."\n") end if anders.timer ~= nil then HaltTimer(anders.timer) end anders.timer = AddTimer(0.1, 0, anders.hostscale)