Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local entity
- local Standing = ""
- local Moving = ""
- local InAir = ""
- local SlowWalk = ""
- local time = 0
- local time1 = 0
- local box = gui.Groupbox(gui.Reference('VISUALS', "ENEMIES", "Options"), "Random speed shit", 0, 1050, 213, 250)
- local speed_bar = gui.Combobox(box, "speed_bar", "Show Speed", "Off", "Bar", "Number","Both")
- local Moving_box = gui.Combobox(box, "Moving_box", "Velocity Flag", "Off", "Show SlowWalk", "Show all modes")
- local slider_r = gui.Slider(box, "slider_r", "Red", 255, 0, 255);
- local slider_g = gui.Slider(box, "slider_g", "Green", 255, 0, 255)
- local slider_b = gui.Slider(box, "slider_b", "Blue", 255, 0, 255);
- local slider_a = gui.Slider(box, "slider_a", "Alpha", 255, 0, 255);
- function speed_stuff()
- if entity ~= nil then
- if entity:IsAlive() and entity:IsPlayer() then
- local fFlags = entity:GetProp("m_fFlags");
- local VelocityX = entity:GetPropFloat("localdata", "m_vecVelocity[0]");
- local VelocityY = entity:GetPropFloat("localdata", "m_vecVelocity[1]");
- local Velocity = math.sqrt(VelocityX ^ 2 + VelocityY ^ 2);
- if Velocity == 0 and (fFlags == 257 or fFlags == 263 or fFlags == 261 or fFlags == 259) then
- Standing = "Standing";
- time = globals.CurTime()
- else
- Standing = "";
- end
- if Velocity >= 95 and (fFlags == 257 or fFlags == 263 or fFlags == 261 or fFlags == 259) and time1 +0.5 < globals.CurTime() then
- time = globals.CurTime()
- Moving = "Moving";
- SlowWalk = ""
- elseif (Velocity <= 95 and math.floor(Velocity + 0.5) ~= 0 )and (fFlags == 257 or fFlags == 263 or fFlags == 261 or fFlags == 259) and time +0.25 > globals.CurTime() then
- Moving = "Moving";
- SlowWalk = ""
- elseif (math.floor(Velocity + 0.5) <= 95 and math.floor(Velocity + 0.5) ~= 0 ) and (fFlags == 257 or fFlags ==259) and time+0.25 < globals.CurTime() then
- SlowWalk = "Slow Walking"
- Moving = "";
- elseif (math.floor(Velocity + 0.5) <= 32 and math.floor(Velocity + 0.5) ~= 0 )and (fFlags == 263 or fFlags == 261) and time+0.25< globals.CurTime() then
- SlowWalk = "Slow Walking"
- Moving = "";
- else
- Moving = "";
- SlowWalk = ""
- end
- if fFlags == 256 or fFlags == 262 or fFlags == 260 then
- InAir = "In Air"
- time1 = globals.CurTime()
- else
- InAir = ""
- end
- return math.floor(Velocity + 0.5);
- end
- end
- end
- local function debug_builder(Builder)
- maxspeed = tonumber(client.GetConVar("sv_maxspeed"))
- entity = Builder:GetEntity()
- local speed = speed_bar:GetValue()
- local mode = Moving_box:GetValue()
- if entities.GetLocalPlayer():GetTeamNumber() ~= entity:GetTeamNumber() then
- Builder:Color(slider_r:GetValue(), slider_g:GetValue(), slider_b:GetValue(), slider_a:GetValue())
- if speed_stuff() ~= nil and entity:IsPlayer() then
- if speed == 1 then
- Builder:AddBarLeft((speed_stuff() / maxspeed))
- elseif speed == 2 then
- Builder:AddTextBottom(speed_stuff())
- elseif speed == 3 then
- Builder:AddTextBottom(speed_stuff())
- Builder:AddBarLeft((speed_stuff() / maxspeed))
- end
- if mode == 1 then
- Builder:AddTextTop(SlowWalk)
- elseif mode == 2 then
- Builder:AddTextTop(Moving .. Standing .. InAir .. SlowWalk)
- end
- end
- end
- end
- callbacks.Register("DrawESP", "debug_builder", debug_builder)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement