View difference between Paste ID: GvCvBE0G and hJAEJPc3
SHOW: | | - or go back to the newest paste.
1
local Plr = owner
2
local char = owner.Character
3
local plr = owner
4
5
-- [[ Color Functions ]] --
6
7
h = math.random(0, 100)
8
color = Color3.fromHSV(h / 100, 1, 0.9)
9
lastbeat = 0
10
lastloud = 0
11
12
-- [[ Cone ]] --
13
14
local cone = Instance.new("Part")
15
cone.Anchored = true
16
cone.CanCollide = false
17
cone.Locked = true
18
cone.Size = Vector3.new(0.5, 0.5, 0.5)
19
cone.Parent = char
20
21
local conem = Instance.new("SpecialMesh")
22
conem.MeshType = Enum.MeshType.FileMesh
23
conem.MeshId = "rbxassetid://120647846"
24
conem.Scale = Vector3.new(1, 1, 1)
25
conem.Parent = cone
26
conem.Transparency = 1
27
28
--[[ Particles ]]--
29
30
local partic = Instance.new("ParticleEmitter")
31
partic.Rate = 50
32
partic.EmissionDirection = Enum.NormalId.Right
33
partic.Texture = "rbxassetid://443789987"
34
partic.LightEmission = 5
35
partic.LightInfluence = 1
36
partic.Transparency = NumberSequence.new({NumberSequenceKeypoint.new(0, 0), NumberSequenceKeypoint.new(1, 1)})
37
partic.Parent = cone
38
39
--[[ Light ]]--
40
41
local lite = Instance.new("PointLight")
42
lite.Range = 0
43
lite.Brightness = 0
44
lite.Parent = char.HumanoidRootPart
45
46
--[[ Sound ]]--
47
48
local sound = Instance.new("Sound")
49
sound.Parent = char.HumanoidRootPart
50
sound.Volume = 10
51
sound.Name = "Music"
52
sound.Looped = true
53
54
plr.Chatted:connect(function(msg)
55
        if msg:sub(1, 6):lower()=='visual' then
56
                local val = Instance.new("NumberValue", char)
57
                val.Value = tonumber(msg:sub(7))
58
                local id = val.Value
59
                sound:Stop()
60
                sound.SoundId = 'rbxassetid://'..id
61
                sound:Play()
62
                sound.Looped = true
63
                wait()
64
        elseif msg:sub(1,5):lower()=='pitch' then
65
                local val2 = Instance.new("NumberValue", char)
66
                val2.Value = tonumber(msg:sub(6))
67
                local Pitch = val2.Value
68
                sound.Pitch = Pitch
69
        elseif msg:sub(1,3):lower()=='vol' then
70
                local val3 = Instance.new("NumberValue", char)
71
                val3.Value = tonumber(msg:sub(5))
72
                local Volume = val3.Value
73
                sound.Volume = Volume
74
end
75
end)
76
77
--[[ Remote ]]--
78
79
local Remote = Instance.new("RemoteEvent", char) 
80
Remote.Name = "Event"
81
local PlaybackSound = 0
82
83
--[[ Visual ]]--
84
85
local spin = 0
86
87
Remote.OnServerEvent:connect(function(plr, Playback)
88
	
89
spin = spin + 0.08 + Playback/10000
90
91
	local beat = math.abs(PlaybackSound - lastloud)
92
		if beat > lastbeat then
93
			lastbeat = beat
94
		else
95
			lastbeat = lastbeat - 10
96
			if lastbeat < 0 then
97
				lastbeat = 0
98
			end
99
		end
100
101
		h = (h + beat / 250) % 100
102
		lastloud = PlaybackSound
103
		color = Color3.fromHSV(h / 100, 5, 0.5 + lastbeat / 50)
104
		
105
lite.Range = 10 + Playback/25
106
lite.Brightness = 5 + Playback/5
107
lite.Color = lite.Color:lerp(Color3.fromHSV(h / 100, 1, 1), 0.25)
108
109
cone.CFrame = cone.CFrame:lerp(char.Head.CFrame * CFrame.new(0, 5, 0) * CFrame.Angles(0, spin, 0), 0.25)
110
cone.Color = cone.Color:lerp(Color3.fromHSV(h / 100, 1, 1), 0.25)
111
112
conem.Scale = conem.Scale:lerp(Vector3.new(1 + Playback/250, 1 + Playback/250, 1 + Playback/250), 0.25)
113
114
partic.Speed = NumberRange.new(5 + Playback/1000)
115
partic.Lifetime = NumberRange.new(5 + Playback/1000)
116
partic.Drag = 5 - Playback/50
117
partic.Size = NumberSequence.new({NumberSequenceKeypoint.new(0, 0 + Playback/1000), NumberSequenceKeypoint.new(1, 0.25 + Playback/1000)})
118
partic.Color = ColorSequence.new(Color3.fromHSV(h / 100, 1, 1), Color3.fromHSV(h / 100, 1, 1))
119
partic.RotSpeed = NumberRange.new(0 - sound.PlaybackLoudness/-250, 0 + sound.PlaybackLoudness/250)
120
partic.SpreadAngle = Vector2.new(0 - sound.PlaybackLoudness/-25, 0 + sound.PlaybackLoudness/25)
121
122
PlaybackSound = Playback
123
124
end)
125
126
--[[ Fire Remote ]]--
127
128
NLS([==[
129
    while wait() do
130
        game:service'Players'.LocalPlayer.Character.Event:FireServer(game:GetService("Players").LocalPlayer.Character.HumanoidRootPart.Music.PlaybackLoudness)
131
    end
132
]==], char)
133
134
--[[ Debounce ]]--
135
136
function debounce(func)
137
    local isRunning = false
138
    return function(...)
139
        if not isRunning then
140
            isRunning = true
141
 
142
            func(...)
143
 
144
            isRunning = false
145
        end
146
    end
147
end
148
149
local BillboardGui = Instance.new("BillboardGui")
150
local TextLabel = Instance.new("TextLabel")
151
152
local vol = 1
153
local song = 0
154
local pitch = 1
155
local timepos = nil
156
local mus = Instance.new("Sound",char)
157
mus:Destroy()
158
159
BillboardGui.Name = "tag"
160
BillboardGui.Parent = char.Head
161
BillboardGui.ZIndexBehavior = Enum.ZIndexBehavior.Sibling
162
BillboardGui.AlwaysOnTop = false
163
BillboardGui.ExtentsOffset = Vector3.new(0, 3, 0)
164
BillboardGui.LightInfluence = 1
165
BillboardGui.Size = UDim2.new(0, 200, 0, 50)
166
 
167
TextLabel.Parent = BillboardGui
168
TextLabel.BackgroundColor3 = Color3.new(0, 0, 0)
169
TextLabel.BackgroundTransparency = 1
170
TextLabel.Size = UDim2.new(0, 200, 0, 50)
171
TextLabel.Font = Enum.Font.SourceSans
172
TextLabel.Text = ".Tame vis."
173
TextLabel.TextColor3 = Color3.new(126, 255, 240)
174
TextLabel.TextScaled = true
175
TextLabel.TextSize = 14
176
TextLabel.TextWrapped = true
177
178
179
	Plr.Chatted:connect(function(msg, recipient) onChatted(msg, recipient, Plr) end)
180
181
local hum = char:FindFirstChildOfClass("Humanoid")
182
local idleanim = Instance.new("Animation")
183
idleanim.Name = "Roblox Idle Animation"
184
idleanim.AnimationId = "http://www.roblox.com/asset/?id=180435571"
185
local idleanimplay = hum:LoadAnimation(idleanim)
186
idleanimplay:Play()
187
wait(0.1)
188
if char:FindFirstChild("Animate") then
189
	char.Animate:Destroy()
190
end
191
local remote = Instance.new("RemoteEvent", char)
192
remote.Name = "ReplicationEvent"
193
local client = NLS([==[
194
	local mouse = game:GetService("Players").LocalPlayer:GetMouse()
195
	local remote = game:GetService("Players").LocalPlayer.Character:WaitForChild("ReplicationEvent")
196
	spawn(function()
197
		while game:GetService("RunService").Heartbeat:Wait() do
198
			remote = game:GetService("Players").LocalPlayer.Character:WaitForChild("ReplicationEvent")
199
		end
200
	end)
201
	game:GetService("UserInputService").InputBegan:Connect(function(input, isTyping)
202
		if isTyping == false and input.UserInputType == Enum.UserInputType.Keyboard then
203
			remote:FireServer(1, input.KeyCode)
204
		end
205
	end)
206
207
    mouse.Button1Down:Connect(function()
208
        remote:FireServer(2)
209
    end)
210
211
]==], char)
212
213
local RS = char.Torso["Right Shoulder"]
214
local LS = char.Torso["Left Shoulder"]
215
local RH = char.Torso["Right Hip"]
216
local LH = char.Torso["Left Hip"]
217
local rootj = char.HumanoidRootPart.RootJoint
218
local normalanim = true
219
local animpose = "Idle"
220
local sine = 0
221
local RSnor = RS.C0
222
local LSnor = LS.C0
223
local RHnor = RH.C0
224
local LHnor = LH.C0
225
local rootjnor = rootj.C0
226
local ff = Instance.new("ForceField",char)
227
ff.Visible = false
228
229
---------------------------------
230
-----------Wrapping up-----------
231
---------------------------------
232
233
while game:GetService("RunService").Heartbeat:Wait() do
234
hum.Health = 9999999
235
hum.MaxHealth = 9999999
236
hum.PlatformStand = false
237
hum.Sit = false
238
239
for i,v in pairs(char:GetChildren()) do
240
if v.ClassName == "Accessory" then
241
v.Handle.Anchored = false
242
end
243
244
if v.ClassName == "Part" then
245
v.Anchored = false
246
end
247
end
248
249
	if normalanim then
250
		sine = sine + 1
251
	end
252
253
	if remote.Parent == char then
254
		remote.Name = "ReplicationEvent"
255
	else
256
		remote = Instance.new("RemoteEvent", char)
257
	end
258
	local touchfloor = workspace:FindPartOnRay(Ray.new(char.HumanoidRootPart.CFrame.Position, ((CFrame.new(char.HumanoidRootPart.Position, char.HumanoidRootPart.Position - Vector3.new(0, 1, 0))).LookVector).Unit * 4), char)
259
	if char.HumanoidRootPart.Velocity.Magnitude > 1 and touchfloor then
260
		animpose = "Walking"
261
	elseif char.HumanoidRootPart.Velocity.Y > 0.5 and touchfloor == nil then
262
		animpose = "Jumping"
263
	elseif char.HumanoidRootPart.Velocity.Y < 0.5 and touchfloor == nil then
264
		animpose = "Falling"
265
	else
266
		animpose = "Idle"
267
	end
268
	if animpose == "Idle" and normalanim then
269
        rootj.C0 = rootj.C0:Lerp(rootjnor * CFrame.Angles(-1.3, 0, 0), 0.15)
270
       rootj.C0 = rootj.C0 * CFrame.new(math.sin(sine / 10) / 7, 0, math.sin(sine / 5) / 10)
271
        RS.C0 = RS.C0:Lerp(RSnor * CFrame.Angles(0.3, 0, 0), 0.15)
272
        LS.C0 = LS.C0:Lerp(LSnor * CFrame.Angles(0.3, 0, 0), 0.15)
273
        RH.C0 = RH.C0:Lerp(RHnor * CFrame.Angles(-0.1, 0, 0), 0.15)
274
        LH.C0 = LH.C0:Lerp(LHnor * CFrame.Angles(-0.1, 0, 0), 0.15)
275
	elseif animpose == "Walking" and normalanim then
276
      rootj.C0 = rootj.C0:Lerp(rootjnor, 0.15)
277
        RS.C0 = RS.C0:Lerp(RSnor * CFrame.Angles(0, 0, math.sin(sine / 5)), 0.1) - Vector3.new(0, rootj.C0.Position.Y / 20, 0)
278
279
        LS.C0 = LS.C0:Lerp(LSnor * CFrame.Angles(0, 0, math.sin(sine / 5)), 0.1) - Vector3.new(0, rootj.C0.Position.Y / 20, 0)
280
281
        RH.C0 = RH.C0:Lerp(RHnor * CFrame.Angles(0, 0, math.sin(sine / 5)), 0.1) - Vector3.new(0, rootj.C0.Position.Y / 20, 0)
282
283
        LH.C0 = LH.C0:Lerp(LHnor * CFrame.Angles(0, 0, math.sin(sine / 5)), 0.1) - Vector3.new(0, rootj.C0.Position.Y / 20, 0)
284
	elseif animpose == "Jumping" and normalanim then
285
		rootj.C0 = rootj.C0:Lerp(rootjnor * CFrame.Angles(-0.5, 0, 0), 0.15)
286
		RS.C0 = RS.C0:Lerp(RSnor * CFrame.Angles(-0.3, 0, 0), 0.15)
287
		LS.C0 = LS.C0:Lerp(LSnor * CFrame.Angles(-0.3, 0, 0), 0.15)
288
		RH.C0 = RH.C0:Lerp(RHnor * CFrame.Angles(-0.3, 0, 0), 0.15)
289
		LH.C0 = LH.C0:Lerp(LHnor * CFrame.Angles(-0.3, 0, 0), 0.15)
290
	elseif animpose == "Falling" and normalanim then
291
		rootj.C0 = rootj.C0:Lerp(rootjnor * CFrame.Angles(0.5, 0, 0), 0.15)
292
		RS.C0 = RS.C0:Lerp(RSnor * CFrame.Angles(-0.6, 0, 0), 0.15)
293
		LS.C0 = LS.C0:Lerp(LSnor * CFrame.Angles(-0.6, 0, 0), 0.15)
294
		RH.C0 = RH.C0:Lerp(RHnor * CFrame.Angles(-0.2, 0, 0), 0.15)
295
		LH.C0 = LH.C0:Lerp(LHnor * CFrame.Angles(-0.2, 0, 0), 0.15)
296
	end
297
298
    if mus.Parent == char then
299
        mus.SoundId = "rbxassetid://"..song
300
        timepos = mus.TimePosition
301
mus.Pitch = pitch
302
        mus.Volume = vol
303
    else
304
        mus = Instance.new("Sound", char)
305
mus.Playing = true
306
mus.Looped = true
307
        mus.TimePosition = timepos
308
end
309
end