· 6 years ago · May 04, 2020, 08:58 AM
1Press 'x' to enable and a box will show up.
2-- Throw your knife at the box until it is no longer colourful.
3-- This will only work if you have a target (not free for all/infected)
4
5local Players = game:GetService("Players")
6local Player = Players.LocalPlayer
7local Mouse = Player:GetMouse()
8
9local Enabled = false
10Mouse.KeyDown:connect(function(key)
11 key = key:upper()
12 if key == "X" then
13 if Enabled then
14 Enabled = false
15 print("Disabled")
16 else
17 Enabled = true
18 print("Enabled")
19 end
20 end
21end)
22
23--// Created by EncryptedRBX/Floof //--
24
25local Hitbox = Instance.new("Part")
26Hitbox.Transparency = 0.6
27Hitbox.Color = Color3.new(1, 1, 1)
28Hitbox.Size = Vector3.new(3, 3, 3)
29Hitbox.Material = "SmoothPlastic"
30Hitbox.CanCollide = false
31Hitbox.Anchored = true
32
33local S = Instance.new("SelectionBox", Hitbox)
34S.Adornee = Hitbox
35S.Transparency = 0.3
36S.SurfaceTransparency = 1
37S.Color3 = Color3.new(0, 0, 0)
38S.LineThickness = 0.05
39
40game:GetService("RunService"):BindToRenderStep(tostring(math.random(1, 10000)), 1, function()
41 if Player and Player.Character then
42 if Player.Character:findFirstChild("HumanoidRootPart") then
43 local HRP = Player.Character:findFirstChild("HumanoidRootPart")
44 Hitbox.CFrame = HRP.CFrame * CFrame.new(10, 0, 0)
45 end
46 if Player.PlayerGui.ScreenGui.UI.Target.Visible == false then
47 Hitbox.Transparency = 1
48 else
49 Hitbox.Transparency = 0.6
50 end
51 end
52end)
53
54--// Created by EncryptedRBX/Floof //--
55
56function c3lerp(a,b,t)
57 return Color3.new(a.r * (1-t) + (b.r*t),a.g * (1-t) + (b.g*t),a.b * (1-t) + (b.b*t))
58end
59
60local Rainbow = {
61 Color3.new(1,0,0);
62 Color3.new(0,1,0);
63 Color3.new(0,0,1);
64 Color3.new(0,1,1);
65 Color3.new(1,0,1);
66 Color3.new(1,1,0);
67}
68
69spawn(function()
70 while true do
71 local k=Hitbox.Color
72 local b=Rainbow[math.random(1,#Rainbow)]
73 local slow=100
74 for i=1, slow do
75 Hitbox.Color=c3lerp(k,b,i/slow)
76 wait()
77 end
78 end
79end)
80
81--// Created by EncryptedRBX/Floof //--
82
83GetTarget = function()
84 local Target = nil
85 local TargetName = nil
86 pcall(function()
87 TargetName = Player.PlayerGui.ScreenGui.UI.Target.TargetText.Text
88 end)
89 if TargetName then
90 if Players:findFirstChild(TargetName) then
91 Target = Players:findFirstChild(TargetName)
92 end
93 end
94 return Target
95end
96
97while wait() do
98 if Enabled then
99 local Target = GetTarget()
100 if Target and Target.Character then
101 Hitbox.Parent = Target.Character
102 else
103 Hitbox.Parent = workspace
104 end
105 else
106 Hitbox.Parent = nil
107 end
108end
109--// Created by Spho3nex //--
110RAW Paste Data
111
112We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
113Not a member of Pastebin yet?
114Sign Up, it unlocks many cool features!
115
116create new paste / dealsnew! / syntax languages / archive / faq / tools / night mode / api / scraping api
117privacy statement / cookies policy / terms of service / security disclosure / dmca / contact
118
119By using Pastebin.com you agree to our cookies policy to enhance your experience