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