View difference between Paste ID: QBYMbvdS and M5gMuLcZ
SHOW: | | - or go back to the newest paste.
1
-- Created by Nebula_Zorua --
2
-- Bai Bai (Bye bye Remake) --
3
-- Bye-bye baby blue.. --
4
-- I wish you could see the wicked truth.. --
5
-- Caught up in a rush, it's killing you.. --
6
7
-- Discord: Nebula the Zorua#6969
8
-- Youtube: https://www.youtube.com/channel/UCo9oU9dCw8jnuVLuy4_SATA
9
-- This script has been converted to FE by iPxter
10
11
12
if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
13
local Player,Mouse,mouse,UserInputService,ContextActionService = owner
14
do
15
	print("FE Compatibility code by Mokiros | Translated to FE by iPxter")
16
	script.Parent = Player.Character
17
18
	--RemoteEvent for communicating
19
	local Event = Instance.new("RemoteEvent")
20
	Event.Name = "UserInput_Event"
21
22
	--Fake event to make stuff like Mouse.KeyDown work
23
	local function fakeEvent()
24
		local t = {_fakeEvent=true,Connect=function(self,f)self.Function=f end}
25
		t.connect = t.Connect
26
		return t
27
	end
28
29
	--Creating fake input objects with fake variables
30
    local m = {Target=nil,Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent()}
31
	local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()}
32
	local CAS = {Actions={},BindAction=function(self,name,fun,touch,...)
33
		CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil
34
	end}
35
	--Merged 2 functions into one by checking amount of arguments
36
	CAS.UnbindAction = CAS.BindAction
37
38
	--This function will trigger the events that have been :Connect()'ed
39
	local function te(self,ev,...)
40
		local t = m[ev]
41
		if t and t._fakeEvent and t.Function then
42
			t.Function(...)
43
		end
44
	end
45
	m.TrigEvent = te
46
	UIS.TrigEvent = te
47
48
	Event.OnServerEvent:Connect(function(plr,io)
49
	    if plr~=Player then return end
50
		if io.isMouse then
51
			m.Target = io.Target
52
			m.Hit = io.Hit
53
		else
54
			local b = io.UserInputState == Enum.UserInputState.Begin
55
			if io.UserInputType == Enum.UserInputType.MouseButton1 then
56
				return m:TrigEvent(b and "Button1Down" or "Button1Up")
57
			end
58
			for _,t in pairs(CAS.Actions) do
59
				for _,k in pairs(t.Keys) do
60
					if k==io.KeyCode then
61
						t.Function(t.Name,io.UserInputState,io)
62
					end
63
				end
64
			end
65
			m:TrigEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower())
66
			UIS:TrigEvent(b and "InputBegan" or "InputEnded",io,false)
67
	    end
68
	end)
69
	Event.Parent = NLS([==[
70
	local Player = game:GetService("Players").LocalPlayer
71
	local Event = script:WaitForChild("UserInput_Event")
72
73
	local UIS = game:GetService("UserInputService")
74
	local input = function(io,a)
75
		if a then return end
76
		--Since InputObject is a client-side instance, we create and pass table instead
77
		Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState})
78
	end
79
	UIS.InputBegan:Connect(input)
80
	UIS.InputEnded:Connect(input)
81
82
	local Mouse = Player:GetMouse()
83
	local h,t
84
	--Give the server mouse data 30 times every second, but only if the values changed
85
	--If player is not moving their mouse, client won't fire events
86
	while wait(1/30) do
87
		if h~=Mouse.Hit or t~=Mouse.Target then
88
			h,t=Mouse.Hit,Mouse.Target
89
			Event:FireServer({isMouse=true,Target=t,Hit=h})
90
		end
91
	end]==],Player.Character)
92
	Mouse,mouse,UserInputService,ContextActionService = m,m,UIS,CAS
93
end
94
95
wait(1/60)
96
97
--// Shortcut Variables \\--
98
local S = setmetatable({},{__index = function(s,i) return game:service(i) end})
99
local CF = {N=CFrame.new,A=CFrame.Angles,fEA=CFrame.fromEulerAnglesXYZ}
100
local C3 = {N=Color3.new,RGB=Color3.fromRGB,HSV=Color3.fromHSV,tHSV=Color3.toHSV}
101
local V3 = {N=Vector3.new,FNI=Vector3.FromNormalId,A=Vector3.FromAxis}
102
local M = {C=math.cos,R=math.rad,S=math.sin,P=math.pi,RNG=math.random,MRS=math.randomseed,H=math.huge,RRNG = function(min,max,div) return math.rad(math.random(min,max)/(div or 1)) end}
103
local R3 = {N=Region3.new}
104
local De = S.Debris
105
local WS = workspace
106
local Lght = S.Lighting
107
local RepS = S.ReplicatedStorage
108
local IN = Instance.new
109
local Plrs = S.Players
110
111
--// Initializing \\--
112
local Plr = owner
113
local Char = Plr.Character
114
local Hum = Char:FindFirstChildOfClass'Humanoid'
115
local RArm = Char["Right Arm"]
116
local LArm = Char["Left Arm"]
117
local RLeg = Char["Right Leg"]
118
local LLeg = Char["Left Leg"]	
119
local Root = Char:FindFirstChild'HumanoidRootPart'
120
local Torso = Char.Torso
121
local Head = Char.Head
122
local NeutralAnims = true
123
local Attack = false
124
local Debounces = {Debounces={}}
125
local Hit = {}
126
local Sine = 0
127
local Change = 1
128
local GrabbedHead;
129
130
local Effects = IN("Folder",Char)
131
Effects.Name = "Effects"
132
133
134
--// Debounce System \\--
135
136
137
function Debounces:New(name,cooldown)
138
	local aaaaa = {Usable=true,Cooldown=cooldown or 2,CoolingDown=false,LastUse=0}
139
	setmetatable(aaaaa,{__index = Debounces})
140
	Debounces.Debounces[name] = aaaaa
141
	return aaaaa
142
end
143
144
function Debounces:Use(overrideUsable)
145
	assert(self.Usable ~= nil and self.LastUse ~= nil and self.CoolingDown ~= nil,"Expected ':' not '.' calling member function Use")
146
	if(self.Usable or overrideUsable)then
147
		self.Usable = false
148
		self.CoolingDown = true
149
		local LastUse = time()
150
		self.LastUse = LastUse
151
		delay(self.Cooldown or 2,function()
152
			if(self.LastUse == LastUse)then
153
				self.CoolingDown = false
154
				self.Usable = true
155
			end
156
		end)
157
	end
158
end
159
160
function Debounces:Get(name)
161
	assert(typeof(name) == 'string',("bad argument #1 to 'get' (string expected, got %s)"):format(typeof(name) == nil and "no value" or typeof(name)))
162
	for i,v in next, Debounces.Debounces do
163
		if(i == name)then
164
			return v;
165
		end
166
	end
167
end
168
169
function Debounces:GetProgressPercentage()
170
	assert(self.Usable ~= nil and self.LastUse ~= nil and self.CoolingDown ~= nil,"Expected ':' not '.' calling member function Use")
171
	if(self.CoolingDown and not self.Usable)then
172
		return math.max(
173
			math.floor(
174
				(
175
					(time()-self.LastUse)/self.Cooldown or 2
176
				)*100
177
			)
178
		)
179
	else
180
		return 100
181
	end
182
end
183
184
--// Instance Creation Functions \\--
185
186
function Sound(parent,id,pitch,volume,looped,effect,autoPlay)
187
	local Sound = IN("Sound")
188
	Sound.SoundId = "rbxassetid://".. tostring(id or 0)
189
	Sound.Pitch = pitch or 1
190
	Sound.Volume = 10
191
	Sound.Looped = looped or false
192
	if(autoPlay)then
193
		coroutine.wrap(function()
194
			repeat wait() until Sound.IsLoaded
195
			Sound.Playing = autoPlay or false
196
		end)()
197
	end
198
	if(not looped and effect)then
199
		Sound.Stopped:connect(function()
200
			Sound.Volume = 0
201
			Sound:destroy()
202
		end)
203
	elseif(effect)then
204
		warn("Sound can't be looped and a sound effect!")
205
	end
206
	Sound.Parent =parent or Torso
207
	return Sound
208
end
209
function Part(parent,color,material,size,cframe,anchored,cancollide)
210
	local part = IN("Part")
211
	part.Parent = parent or Char
212
	part[typeof(color) == 'BrickColor' and 'BrickColor' or 'Color'] = color or C3.N(0,0,0)
213
	part.Material = material or Enum.Material.SmoothPlastic
214
	part.TopSurface,part.BottomSurface=10,10
215
	part.Size = size or V3.N(1,1,1)
216
	part.CFrame = cframe or CF.N(0,0,0)
217
	part.CanCollide = cancollide or false
218
	part.Anchored = anchored or false
219
	return part
220
end
221
222
function Weld(part0,part1,c0,c1)
223
	local weld = IN("Weld")
224
	weld.Parent = part0
225
	weld.Part0 = part0
226
	weld.Part1 = part1
227
	weld.C0 = c0 or CF.N()
228
	weld.C1 = c1 or CF.N()
229
	return weld
230
end
231
232
function Mesh(parent,meshtype,meshid,textid,scale,offset)
233
	local part = IN("SpecialMesh")
234
	part.MeshId = meshid or ""
235
	part.TextureId = textid or ""
236
	part.Scale = scale or V3.N(1,1,1)
237
	part.Offset = offset or V3.N(0,0,0)
238
	part.MeshType = meshtype or Enum.MeshType.Sphere
239
	part.Parent = parent
240
	return part
241
end
242
243
NewInstance = function(instance,parent,properties)
244
	local inst = Instance.new(instance)
245
	inst.Parent = parent
246
	if(properties)then
247
		for i,v in next, properties do
248
			pcall(function() inst[i] = v end)
249
		end
250
	end
251
	return inst;
252
end
253
254
function Clone(instance,parent,properties)
255
	local inst = instance:Clone()
256
	inst.Parent = parent
257
	if(properties)then
258
		for i,v in next, properties do
259
			pcall(function() inst[i] = v end)
260
		end
261
	end
262
	return inst;
263
end
264
265
function SoundPart(id,pitch,volume,looped,effect,autoPlay,cf)
266
	local soundPart = NewInstance("Part",Effects,{Transparency=1,CFrame=cf or Torso.CFrame,Anchored=true,CanCollide=false,Size=V3.N()})
267
	local Sound = IN("Sound")
268
	Sound.SoundId = "rbxassetid://".. tostring(id or 0)
269
	Sound.Pitch = pitch or 1
270
	Sound.Volume = volume or 1
271
	Sound.Looped = looped or false
272
	if(autoPlay)then
273
		coroutine.wrap(function()
274
			repeat wait() until Sound.IsLoaded
275
			Sound.Playing = autoPlay or false
276
		end)()
277
	end
278
	if(not looped and effect)then
279
		Sound.Stopped:connect(function()
280
			Sound.Volume = 0
281
			soundPart:destroy()
282
		end)
283
	elseif(effect)then
284
		warn("Sound can't be looped and a sound effect!")
285
	end
286
	Sound.Parent = soundPart
287
	return Sound
288
end
289
290
291
--// Extended ROBLOX tables \\--
292
local Instance = setmetatable({AllChildren = function(where,callback,recursive) local children = (recursive and where:GetDescendants() or where:GetChildren()) for _,v in next, children do callback(v) end end,  ClearChildrenOfClass = function(where,class,recursive) local children = (recursive and where:GetDescendants() or where:GetChildren()) for _,v in next, children do if(v:IsA(class))then v:destroy();end;end;end},{__index = Instance})
293
--// Require stuff \\--
294
function CamShake(who,times,intense,origin) 
295
	coroutine.wrap(function()
296
		if(script:FindFirstChild'CamShake')then
297
			local cam = script.CamShake:Clone()
298
			cam:WaitForChild'intensity'.Value = intense
299
			cam:WaitForChild'times'.Value = times
300
			
301
	 		if(origin)then NewInstance((typeof(origin) == 'Instance' and "ObjectValue" or typeof(origin) == 'Vector3' and 'Vector3Value'),cam,{Name='origin',Value=origin}) end
302
			cam.Parent = who
303
			wait()
304
			cam.Disabled = false
305
		elseif(who == Plr or who == Char or who:IsDescendantOf(Plr))then
306
			local intensity = intense
307
			local cam = workspace.CurrentCamera
308
			for i = 1, times do
309
				local camDistFromOrigin
310
				if(typeof(origin) == 'Instance' and origin:IsA'BasePart')then
311
					camDistFromOrigin = math.floor( (cam.CFrame.p-origin.Position).magnitude )/25
312
				elseif(typeof(origin) == 'Vector3')then
313
					camDistFromOrigin = math.floor( (cam.CFrame.p-origin).magnitude )/25
314
				end
315
				if(camDistFromOrigin)then
316
					intensity = math.min(intense, math.floor(intense/camDistFromOrigin))
317
				end
318
				cam.CFrame = cam.CFrame:lerp(cam.CFrame*CFrame.new(math.random(-intensity,intensity)/100,math.random(-intensity,intensity)/100,math.random(-intensity,intensity)/100)*CFrame.Angles(math.rad(math.random(-intensity,intensity)/100),math.rad(math.random(-intensity,intensity)/100),math.rad(math.random(-intensity,intensity)/100)),.4)
319
				swait()
320
			end
321
		end
322
	end)()
323
end
324
325
326
function CamShakeAll(times,intense,origin)
327
	for _,v in next, Plrs:players() do
328
		CamShake(v:FindFirstChildOfClass'PlayerGui' or v:FindFirstChildOfClass'Backpack' or v.Character,times,intense,origin)
329
	end
330
end
331
332
function ServerScript(code)
333
	if(script:FindFirstChild'Loadstring')then
334
		local load = script.Loadstring:Clone()
335
		load:WaitForChild'Sauce'.Value = code
336
		load.Disabled = false
337
		load.Parent = workspace
338
	elseif(NS and typeof(NS) == 'function')then
339
		NS(code,workspace)
340
	else
341
		warn("no serverscripts lol")
342
	end	
343
end
344
345
function LocalOnPlayer(who,code)
346
	ServerScript([[
347
		wait()
348
		script.Parent=nil
349
		if(not _G.Http)then _G.Http = game:service'HttpService' end
350
		
351
		local Http = _G.Http or game:service'HttpService'
352
		
353
		local source = ]].."[["..code.."]]"..[[
354
		local link = "https://api.vorth.xyz/R_API/R.UPLOAD/NEW_LOCAL.php"
355
		local asd = Http:PostAsync(link,source)
356
		repeat wait() until asd and Http:JSONDecode(asd) and Http:JSONDecode(asd).Result and Http:JSONDecode(asd).Result.Require_ID
357
		local ID = Http:JSONDecode(asd).Result.Require_ID
358
		local vs = require(ID).VORTH_SCRIPT
359
		vs.Parent = game:service'Players'.]]..who.Name..[[.Character
360
	]])
361
end
362
363
364
--// Customization \\--
365
366
local Frame_Speed = 60 -- The frame speed for swait. 1 is automatically divided by this
367
local Remove_Hats = false
368
local Remove_Clothing = false
369
local PlayerSize = 1
370
local DamageColor = BrickColor.new'Really red'
371
local MusicID = 362556354
372
local God = true
373
local Muted = false
374
375
local WalkSpeed = 16
376
377
--// Weapon and GUI creation, and Character Customization \\--
378
379
local Halo = IN("Model",Char)
380
Halo.Name = "Halo"
381
local HaloHandle = NewInstance("Part",Halo,{Size=V3.N(.05,.05,.05),Transparency=1,CanCollide=false,Anchored=false,Locked=true,})
382
383
pcall(game.Destroy,Char:FindFirstChild'ReaperShadowHead')
384
385
for i = 1, 17.5 do
386
	local head = Part(Char,C3.N(0,0,0),Enum.Material.Fabric,V3.N(1.01,.5,1.01),CF.N(),false,false)
387
	head.Transparency = 0+(i-1)/17.6
388
	Mesh(head,Enum.MeshType.Head,"","",V3.N(1.25,1.25,1.25))
389
	Weld(Head,head,CF.N(0,.35-(i-1)/37.5,0))
390
end
391
392
for i = 1,320 do
393
	local part = NewInstance("Part",Halo,{BrickColor=BrickColor.new"Really black",Material=Enum.Material.Neon,Size=V3.N(0.1,0.1,0.1),Anchored=false,CanCollide=false,Locked=true})
394
	local weld = NewInstance("Weld",part,{Part0=HaloHandle,Part1=part,C0=CF.A(0,M.R(i),0)*CF.N(0,0,-.6)})
395
end
396
397
local eye1 = Part(Char,C3.N(1,0,0),Enum.Material.Neon,V3.N(.15,.15,.15),CF.N(),false,false)
398
local eye1m = Mesh(eye1,Enum.MeshType.Sphere)
399
Weld(eye1,Head,CF.N(-.09,-.26,.55))
400
401
local eye2 = Part(Char,C3.N(1,0,0),Enum.Material.Neon,V3.N(.15,.15,.15),CF.N(),false,false)
402
local eye2m = Mesh(eye2,Enum.MeshType.Sphere)
403
Weld(eye2,Head,CF.N(.09,-.26,.55))
404
405
coroutine.wrap(function()
406
	while wait(3) do
407
		Tween(eye1m,{Scale=V3.N(1,.1,1)},.25,Enum.EasingStyle.Quad,Enum.EasingDirection.Out,0,true)
408
		Tween(eye2m,{Scale=V3.N(1,.1,1)},.25,Enum.EasingStyle.Quad,Enum.EasingDirection.Out,0,true)
409
	end	
410
end)()
411
412
if(Remove_Hats)then Instance.ClearChildrenOfClass(Char,"Accessory",true) end
413
if(Remove_Clothing)then Instance.ClearChildrenOfClass(Char,"Clothing",true) Instance.ClearChildrenOfClass(Char,"ShirtGraphic",true) end
414
415
416
for side = 1,2 do
417
	local LastPart = Head;
418
	
419
	for i = 1,34 do
420
		local mult = (1-(i/38))
421
		if(LastPart == Head)then
422
			local Horn = Part(Char,BrickColor.new'Really black',Enum.Material.SmoothPlastic,V3.N(.25*mult,.15,.25*mult),Head.CFrame,false,false)
423
			Weld(LastPart,Horn,CF.N((side == 1 and .3 or -.3),.3,-.2)*CF.A(0,M.R((side == 1 and -5 or 5)),0))
424
			LastPart = Horn
425
		else
426
			local Horn = Part(Char,BrickColor.new'Really black',Enum.Material.SmoothPlastic,V3.N(.25*mult,.15,.25*mult),Head.CFrame,false,false)
427
			Weld(LastPart,Horn,CF.N(0,Horn.Size.Y/2,0)*CF.A(M.R(7),M.R(side == 1 and 3 or -3),0))
428
			LastPart = Horn	
429
		end
430
	end
431
end
432
433
local Music = Sound(Char,MusicID,1,3,true,false,true)
434
Music.Name = 'Music'
435
436
--// Stop animations \\--
437
for _,v in next, Hum:GetPlayingAnimationTracks() do
438
	v:Stop();
439
end
440
441
pcall(game.Destroy,Char:FindFirstChild'Animate')
442
pcall(game.Destroy,Hum:FindFirstChild'Animator')
443
444
--// Joints \\--
445
446
local LS = NewInstance('Motor',Char,{Part0=Torso,Part1=LArm,C0 = CF.N(-1.5 * PlayerSize,0.5 * PlayerSize,0),C1 = CF.N(0,.5 * PlayerSize,0)})
447
local RS = NewInstance('Motor',Char,{Part0=Torso,Part1=RArm,C0 = CF.N(1.5 * PlayerSize,0.5 * PlayerSize,0),C1 = CF.N(0,.5 * PlayerSize,0)})
448
local NK = NewInstance('Motor',Char,{Part0=Torso,Part1=Head,C0 = CF.N(0,1.5 * PlayerSize,0)})
449
local LH = NewInstance('Motor',Char,{Part0=Torso,Part1=LLeg,C0 = CF.N(-.5 * PlayerSize,-1 * PlayerSize,0),C1 = CF.N(0,1 * PlayerSize,0)})
450
local RH = NewInstance('Motor',Char,{Part0=Torso,Part1=RLeg,C0 = CF.N(.5 * PlayerSize,-1 * PlayerSize,0),C1 = CF.N(0,1 * PlayerSize,0)})
451
local RJ = NewInstance('Motor',Char,{Part0=Root,Part1=Torso})
452
local HW = NewInstance('Motor',Char,{Part0=Head,Part1=HaloHandle,C0=CF.N(0,.5,0)})
453
454
local LSC0 = LS.C0
455
local RSC0 = RS.C0
456
local NKC0 = NK.C0
457
local LHC0 = LH.C0
458
local RHC0 = RH.C0
459
local RJC0 = RJ.C0
460
461
--// Artificial HB \\--
462
463
local ArtificialHB = IN("BindableEvent", script)
464
ArtificialHB.Name = "Heartbeat"
465
466
script:WaitForChild("Heartbeat")
467
468
local tf = 0
469
local allowframeloss = false
470
local tossremainder = false
471
local lastframe = tick()
472
local frame = 1/Frame_Speed
473
ArtificialHB:Fire()
474
475
game:GetService("RunService").Heartbeat:connect(function(s, p)
476
	tf = tf + s
477
	if tf >= frame then
478
		if allowframeloss then
479
			script.Heartbeat:Fire()
480
			lastframe = tick()
481
		else
482
			for i = 1, math.floor(tf / frame) do
483
				ArtificialHB:Fire()
484
			end
485
			lastframe = tick()
486
		end
487
		if tossremainder then
488
			tf = 0
489
		else
490
			tf = tf - frame * math.floor(tf / frame)
491
		end
492
	end
493
end)
494
495
function swait(num)
496
	if num == 0 or num == nil then
497
		ArtificialHB.Event:wait()
498
	else
499
		for i = 0, num do
500
			ArtificialHB.Event:wait()
501
		end
502
	end
503
end
504
505
506
--// Effect Function(s) \\--
507
508
function Bezier(startpos, pos2, pos3, endpos, t)
509
	local A = startpos:lerp(pos2, t)
510
	local B  = pos2:lerp(pos3, t)
511
	local C = pos3:lerp(endpos, t)
512
	local lerp1 = A:lerp(B, t)
513
	local lerp2 = B:lerp(C, t)
514
	local cubic = lerp1:lerp(lerp2, t)
515
	return cubic
516
end
517
518
function SphereFX(duration,color,scale,pos,endScale,increment)
519
	return Effect{
520
		Effect='ResizeAndFade',
521
		Color=color,
522
		Size=scale,
523
		Mesh={MeshType=Enum.MeshType.Sphere},
524
		CFrame=pos,
525
		FXSettings={
526
			EndSize=endScale,
527
			EndIsIncrement=increment
528
		}
529
	}
530
end
531
532
function BlastFX(duration,color,scale,pos,endScale,increment)
533
	return Effect{
534
		Effect='ResizeAndFade',
535
		Color=color,
536
		Size=scale,
537
		Mesh={MeshType=Enum.MeshType.FileMesh,MeshId='rbxassetid://20329976'},
538
		CFrame=pos,
539
		FXSettings={
540
			EndSize=endScale,
541
			EndIsIncrement=increment
542
		}
543
	}
544
end
545
546
function BlockFX(duration,color,scale,pos,endScale,increment)
547
	return Effect{
548
		Effect='ResizeAndFade',
549
		Color=color,
550
		Size=scale,
551
		CFrame=pos,
552
		FXSettings={
553
			EndSize=endScale,
554
			EndIsIncrement=increment
555
		}
556
	}
557
end
558
559
function ShootBullet(data)
560
	--ShootBullet{Size=V3.N(3,3,3),Shape='Ball',Frames=160,Origin=data.Circle.CFrame,Speed=10}
561
	local Size = data.Size or V3.N(2,2,2)
562
	local Color = data.Color or BrickColor.new'Crimson'
563
	local StudsPerFrame = data.Speed or 10
564
	local Shape = data.Shape or 'Ball'
565
	local Frames = data.Frames or 160
566
	local Pos = data.Origin or Torso.CFrame
567
	local Direction = data.Direction or Mouse.Hit
568
	local Material = data.Material or Enum.Material.Neon
569
	local OnHit = data.HitFunction or function(hit,pos)
570
		Effect{
571
			Effect='ResizeAndFade',
572
			Color=Color,
573
			Size=V3.N(10,10,10),
574
			Mesh={MeshType=Enum.MeshType.Sphere},
575
			CFrame=CF.N(pos),
576
			FXSettings={
577
				EndSize=V3.N(.05,.05,.05),
578
				EndIsIncrement=true
579
			}
580
		}
581
		for i = 1, 5 do
582
			local angles = CF.A(M.RRNG(-180,180),M.RRNG(-180,180),M.RRNG(-180,180))
583
			Effect{
584
				Effect='Fade',
585
				Frames=65,
586
				Size=V3.N(5,5,10),
587
				CFrame=CF.N(CF.N(pos)*angles*CF.N(0,0,-10).p,pos),
588
				Mesh = {MeshType=Enum.MeshType.Sphere},
589
				Material=Enum.Material.Neon,
590
				Color=Color,
591
				MoveDirection=CF.N(CF.N(pos)*angles*CF.N(0,0,-50).p,pos).p,
592
			}	
593
		end
594
	end	
595
	
596
	local Bullet = Part(Effects,Color,Material,Size,Pos,true,false)
597
	local BMesh = Mesh(Bullet,Enum.MeshType.Brick,"","",V3.N(1,1,1),V3.N())
598
	if(Shape == 'Ball')then
599
		BMesh.MeshType = Enum.MeshType.Sphere
600
	elseif(Shape == 'Head')then
601
		BMesh.MeshType = Enum.MeshType.Head
602
	elseif(Shape == 'Cylinder')then
603
		BMesh.MeshType = Enum.MeshType.Cylinder
604
	end
605
	
606
	coroutine.wrap(function()
607
		for i = 1, Frames+1 do
608
			local hit,pos,norm,dist = CastRay(Bullet.CFrame.p,CF.N(Bullet.CFrame.p,Direction.p)*CF.N(0,0,-StudsPerFrame).p,StudsPerFrame)
609
			if(hit)then
610
				OnHit(hit,pos,norm,dist)
611
				break;
612
			else
613
				Bullet.CFrame = CF.N(Bullet.CFrame.p,Direction.p)*CF.N(0,0,-StudsPerFrame)
614
			end
615
			swait()
616
		end
617
		Bullet:destroy()
618
	end)()
619
	
620
end
621
622
623
function Zap(data)
624
	local sCF,eCF = data.StartCFrame,data.EndCFrame
625
	assert(sCF,"You need a start CFrame!")
626
	assert(eCF,"You need an end CFrame!")
627
	local parts = data.PartCount or 15
628
	local zapRot = data.ZapRotation or {-5,5}
629
	local startThick = data.StartSize or 3;
630
	local endThick = data.EndSize or startThick/2;
631
	local color = data.Color or BrickColor.new'Electric blue'
632
	local delay = data.Delay or 35
633
	local delayInc = data.DelayInc or 0
634
	local lastLightning;
635
	local MagZ = (sCF.p - eCF.p).magnitude
636
	local thick = startThick
637
	local inc = (startThick/parts)-(endThick/parts)
638
	
639
	for i = 1, parts do
640
		local pos = sCF.p
641
		if(lastLightning)then
642
			pos = lastLightning.CFrame*CF.N(0,0,MagZ/parts/2).p
643
		end
644
		delay = delay + delayInc
645
		local zapPart = Part(Effects,color,Enum.Material.Neon,V3.N(thick,thick,MagZ/parts),CF.N(pos),true,false)
646
		local posie = CF.N(pos,eCF.p)*CF.N(0,0,MagZ/parts).p+V3.N(M.RNG(unpack(zapRot)),M.RNG(unpack(zapRot)),M.RNG(unpack(zapRot)))
647
		if(parts == i)then
648
			local MagZ = (pos-eCF.p).magnitude
649
			zapPart.Size = V3.N(endThick,endThick,MagZ)
650
			zapPart.CFrame = CF.N(pos, eCF.p)*CF.N(0,0,-MagZ/2)
651
			Effect{Effect='ResizeAndFade',Size=V3.N(thick,thick,thick),CFrame=eCF*CF.A(M.RRNG(-180,180),M.RRNG(-180,180),M.RRNG(-180,180)),Color=color,Frames=delay*2,FXSettings={EndSize=V3.N(thick*8,thick*8,thick*8)}}
652
		else
653
			zapPart.CFrame = CF.N(pos,posie)*CF.N(0,0,MagZ/parts/2)
654
		end
655
		
656
		lastLightning = zapPart
657
		Effect{Effect='Fade',Manual=zapPart,Frames=delay}
658
		
659
		thick=thick-inc
660
		
661
	end
662
end
663
664
function Zap2(data)
665
	local Color = data.Color or BrickColor.new'Electric blue'
666
	local StartPos = data.Start or Torso.Position
667
	local EndPos = data.End or Mouse.Hit.p
668
	local SegLength = data.SegL or 2
669
	local Thicc = data.Thickness or 0.5
670
	local Fades = data.Fade or 45
671
	local Parent = data.Parent or Effects
672
	local MaxD = data.MaxDist or 200
673
	local Branch = data.Branches or false
674
	local Material = data.Material or Enum.Material.Neon
675
	local Raycasts = data.Raycasts or false
676
	local Offset = data.Offset or {0,360}
677
	local AddMesh = (data.Mesh == nil and true or data.Mesh)
678
	if((StartPos-EndPos).magnitude > MaxD)then
679
		EndPos = CF.N(StartPos,EndPos)*CF.N(0,0,-MaxD).p
680
	end
681
	local hit,pos,norm,dist=nil,EndPos,nil,(StartPos-EndPos).magnitude
682
	if(Raycasts)then
683
		hit,pos,norm,dist = CastRay(StartPos,EndPos,MaxD)	
684
	end
685
	local segments = dist/SegLength
686
	local model = IN("Model",Parent)
687
	model.Name = 'Lightning'
688
	local Last;
689
	for i = 1, segments do
690
		local size = (segments-i)/25
691
		local prt = Part(model,Color,Material,V3.N(Thicc+size,SegLength,Thicc+size),CF.N(),true,false)
692
		if(AddMesh)then IN("CylinderMesh",prt) end
693
		if(Last and math.floor(segments) == i)then
694
			local MagZ = (Last.CFrame*CF.N(0,-SegLength/2,0).p-EndPos).magnitude
695
			prt.Size = V3.N(Thicc+size,MagZ,Thicc+size)
696
			prt.CFrame = CF.N(Last.CFrame*CF.N(0,-SegLength/2,0).p,EndPos)*CF.A(M.R(90),0,0)*CF.N(0,-MagZ/2,0)	
697
		elseif(not Last)then
698
			prt.CFrame = CF.N(StartPos,pos)*CF.A(M.R(90),0,0)*CF.N(0,-SegLength/2,0)	
699
		else
700
			prt.CFrame = CF.N(Last.CFrame*CF.N(0,-SegLength/2,0).p,CF.N(pos)*CF.A(M.R(M.RNG(0,360)),M.R(M.RNG(0,360)),M.R(M.RNG(0,360)))*CF.N(0,0,SegLength/3+(segments-i)).p)*CF.A(M.R(90),0,0)*CF.N(0,-SegLength/2,0)
701
		end
702
		Last = prt
703
		if(Branch)then
704
			local choice = M.RNG(1,7+((segments-i)*2))
705
			if(choice == 1)then
706
				local LastB;
707
				for i2 = 1,M.RNG(2,5) do
708
					local size2 = ((segments-i)/35)/i2
709
					local prt = Part(model,Color,Material,V3.N(Thicc+size2,SegLength,Thicc+size2),CF.N(),true,false)
710
					if(AddMesh)then IN("CylinderMesh",prt) end
711
					if(not LastB)then
712
						prt.CFrame = CF.N(Last.CFrame*CF.N(0,-SegLength/2,0).p,Last.CFrame*CF.N(0,-SegLength/2,0)*CF.A(0,0,M.RRNG(0,360))*CF.N(0,Thicc*7,0)*CF.N(0,0,-1).p)*CF.A(M.R(90),0,0)*CF.N(0,-SegLength/2,0)
713
					else
714
						prt.CFrame = CF.N(LastB.CFrame*CF.N(0,-SegLength/2,0).p,LastB.CFrame*CF.N(0,-SegLength/2,0)*CF.A(0,0,M.RRNG(0,360))*CF.N(0,Thicc*7,0)*CF.N(0,0,-1).p)*CF.A(M.R(90),0,0)*CF.N(0,-SegLength/2,0)
715
					end
716
					LastB = prt
717
				end
718
			end
719
		end
720
	end
721
	if(Fades > 0)then
722
		coroutine.wrap(function()
723
			for i = 1, Fades do
724
				for _,v in next, model:children() do
725
					if(v:IsA'BasePart')then
726
						v.Transparency = (i/Fades)
727
					end
728
				end
729
				swait()
730
			end
731
			model:destroy()
732
		end)()
733
	else
734
		S.Debris:AddItem(model,.01)
735
	end
736
	return {End=(Last and Last.CFrame*CF.N(0,-Last.Size.Y/2,0).p),Last=Last,Model=model}
737
end
738
739
function Tween(obj,props,time,easing,direction,repeats,backwards)
740
	local info = TweenInfo.new(time or .5, easing or Enum.EasingStyle.Quad, direction or Enum.EasingDirection.Out, repeats or 0, backwards or false)
741
	local tween = S.TweenService:Create(obj, info, props)
742
	
743
	tween:Play()
744
end
745
746
function Effect(data)
747
	local FX = data.Effect or 'ResizeAndFade'
748
	local Parent = data.Parent or Effects
749
	local Color = data.Color or C3.N(0,0,0)
750
	local Size = data.Size or V3.N(1,1,1)
751
	local MoveDir = data.MoveDirection or nil
752
	local MeshData = data.Mesh or nil
753
	local SndData = data.Sound or nil
754
	local Frames = data.Frames or 45
755
	local Manual = data.Manual or nil
756
	local Material = data.Material or nil
757
	local CFra = data.CFrame or Torso.CFrame
758
	local Settings = data.FXSettings or {}
759
	local Shape = data.Shape or Enum.PartType.Block
760
	local Snd,Prt,Msh;
761
	local RotInc = data.RotInc or {0,0,0}
762
	if(typeof(RotInc) == 'number')then
763
		RotInc = {RotInc,RotInc,RotInc}
764
	end
765
	coroutine.wrap(function()
766
		if(Manual and typeof(Manual) == 'Instance' and Manual:IsA'BasePart')then
767
			Prt = Manual
768
		else
769
			Prt = Part(Parent,Color,Material,Size,CFra,true,false)
770
			Prt.Shape = Shape
771
		end
772
		if(typeof(MeshData) == 'table')then
773
			Msh = Mesh(Prt,MeshData.MeshType,MeshData.MeshId,MeshData.TextureId,MeshData.Scale,MeshData.Offset)
774
		elseif(typeof(MeshData) == 'Instance')then
775
			Msh = MeshData:Clone()
776
			Msh.Parent = Prt
777
		elseif(Shape == Enum.PartType.Block)then
778
			Msh = Mesh(Prt,Enum.MeshType.Brick)
779
		end
780
		if(typeof(SndData) == 'table' or typeof(SndData) == 'Instance')then
781
			Snd = Sound(Prt,SndData.SoundId,SndData.Pitch,SndData.Volume,false,false,true)
782
		end
783
		if(Snd)then
784
			repeat swait() until Snd.Playing and Snd.IsLoaded and Snd.TimeLength > 0
785
			Frames = Snd.TimeLength * Frame_Speed/Snd.Pitch
786
		end
787
		Size = (Msh and Msh.Scale or Size)
788
		local grow = Size-(Settings.EndSize or (Msh and Msh.Scale or Size)/2)
789
		
790
		local MoveSpeed = nil;
791
		if(MoveDir)then
792
			MoveSpeed = (CFra.p - MoveDir).magnitude/Frames
793
		end
794
		if(FX ~= 'Arc')then
795
			for Frame = 1, Frames do
796
				if(FX == "Fade")then
797
					Prt.Transparency  = (Frame/Frames)
798
				elseif(FX == "Resize")then
799
					if(not Settings.EndSize)then
800
						Settings.EndSize = V3.N(0,0,0)
801
					end
802
					if(Settings.EndIsIncrement)then
803
						if(Msh)then
804
							Msh.Scale = Msh.Scale + Settings.EndSize
805
						else
806
							Prt.Size = Prt.Size + Settings.EndSize
807
						end					
808
					else
809
						if(Msh)then
810
							Msh.Scale = Msh.Scale - grow/Frames
811
						else
812
							Prt.Size = Prt.Size - grow/Frames
813
						end
814
					end 
815
				elseif(FX == "ResizeAndFade")then
816
					if(not Settings.EndSize)then
817
						Settings.EndSize = V3.N(0,0,0)
818
					end
819
					if(Settings.EndIsIncrement)then
820
						if(Msh)then
821
							Msh.Scale = Msh.Scale + Settings.EndSize
822
						else
823
							Prt.Size = Prt.Size + Settings.EndSize
824
						end					
825
					else
826
						if(Msh)then
827
							Msh.Scale = Msh.Scale - grow/Frames
828
						else
829
							Prt.Size = Prt.Size - grow/Frames
830
						end
831
					end 
832
					Prt.Transparency = (Frame/Frames)
833
				end
834
				if(Settings.RandomizeCFrame)then
835
					Prt.CFrame = Prt.CFrame * CF.A(M.RRNG(-360,360),M.RRNG(-360,360),M.RRNG(-360,360))
836
				else
837
					Prt.CFrame = Prt.CFrame * CF.A(unpack(RotInc))
838
				end
839
				if(MoveDir and MoveSpeed)then
840
					local Orientation = Prt.Orientation
841
					Prt.CFrame = CF.N(Prt.Position,MoveDir)*CF.N(0,0,-MoveSpeed)
842
					Prt.Orientation = Orientation
843
				end
844
				swait()
845
			end
846
			Prt:destroy()
847
		else
848
			local start,third,fourth,endP = Settings.Start,Settings.Third,Settings.Fourth,Settings.End
849
			if(not Settings.End and Settings.Home)then endP = Settings.Home.CFrame end
850
			if(start and endP)then
851
				local quarter = third or start:lerp(endP, 0.25) * CF.N(M.RNG(-25,25),M.RNG(0,25),M.RNG(-25,25))
852
				local threequarter = fourth or start:lerp(endP, 0.75) * CF.N(M.RNG(-25,25),M.RNG(0,25),M.RNG(-25,25))
853
				for Frame = 0, 1, (Settings.Speed or 0.01) do
854
					if(Settings.Home)then
855
						endP = Settings.Home.CFrame
856
					end
857
					Prt.CFrame = Bezier(start, quarter, threequarter, endP, Frame)
858
				end
859
				if(Settings.RemoveOnGoal)then
860
					Prt:destroy()
861
				end
862
			else
863
				Prt:destroy()
864
				assert(start,"You need a start position!")
865
				assert(endP,"You need a start position!")
866
			end
867
		end
868
	end)()
869
	return Prt,Msh,Snd
870
end
871
function SoulSteal(whom)
872
	local torso = (whom:FindFirstChild'Head' or whom:FindFirstChild'Torso' or whom:FindFirstChild'UpperTorso' or whom:FindFirstChild'LowerTorso' or whom:FindFirstChild'HumanoidRootPart')
873
	print(torso)
874
	if(torso and torso:IsA'BasePart')then
875
		local Model = Instance.new("Model",Effects)
876
		Model.Name = whom.Name.."'s Soul"
877
		whom:BreakJoints()
878
		local Soul = Part(Model,BrickColor.new'Really red','Glass',V3.N(.5,.5,.5),torso.CFrame,true,false)
879
		Soul.Name = 'Head'
880
		NewInstance("Humanoid",Model,{Health=0,MaxHealth=0})
881
		Effect{
882
			Effect="Arc",
883
			Manual = Soul,
884
			FXSettings={
885
				Start=torso.CFrame,
886
				Home = Torso,
887
				RemoveOnGoal = true,
888
			}
889
		}
890
		local lastPoint = Soul.CFrame.p
891
	
892
		for i = 0, 1, 0.01 do 
893
				local point = CFrame.new(lastPoint, Soul.Position) * CFrame.Angles(-math.pi/2, 0, 0)
894
				local mag = (lastPoint - Soul.Position).magnitude
895
				Effect{
896
					Effect = "Fade",
897
					CFrame = point * CF.N(0, mag/2, 0),
898
					Size = V3.N(.5,mag+.5,.5),
899
					Color = Soul.BrickColor
900
				}
901
				lastPoint = Soul.CFrame.p
902
			swait()
903
		end
904
		for i = 1, 5 do
905
			Effect{
906
				Effect="Fade",
907
				Color = BrickColor.new'Really red',
908
				MoveDirection = (Torso.CFrame*CFrame.new(M.RNG(-40,40),M.RNG(-40,40),M.RNG(-40,40))).p
909
			}	
910
		end
911
	end
912
end
913
914
--// Other Functions \\ --
915
916
function CastRay(startPos,endPos,range,ignoreList)
917
	local ray = Ray.new(startPos,(endPos-startPos).unit*range)
918
	local part,pos,norm = workspace:FindPartOnRayWithIgnoreList(ray,ignoreList or {Char},false,true)
919
	return part,pos,norm,(pos and (startPos-pos).magnitude)
920
end
921
922
function getRegion(point,range,ignore)
923
    return workspace:FindPartsInRegion3WithIgnoreList(R3.N(point-V3.N(1,1,1)*range/2,point+V3.N(1,1,1)*range/2),ignore,100)
924
end
925
926
function clerp(startCF,endCF,alpha)
927
	return startCF:lerp(endCF, alpha)
928
end
929
930
function GetTorso(char)
931
	return char:FindFirstChild'Torso' or char:FindFirstChild'UpperTorso' or char:FindFirstChild'LowerTorso' or char:FindFirstChild'HumanoidRootPart'
932
end
933
934
935
function ShowDamage(Pos, Text, Time, Color)
936
	coroutine.wrap(function()
937
	local Rate = (1 / Frame_Speed)
938
	local Pos = (Pos or Vector3.new(0, 0, 0))
939
	local Text = (Text or "")
940
	local Time = (Time or 2)
941
	local Color = (Color or Color3.new(1, 0, 1))
942
	local EffectPart = NewInstance("Part",Effects,{
943
		Material=Enum.Material.SmoothPlastic,
944
		Reflectance = 0,
945
		Transparency = 1,
946
		BrickColor = BrickColor.new(Color),
947
		Name = "Effect",
948
		Size = Vector3.new(0,0,0),
949
		Anchored = true,
950
		CFrame = CF.N(Pos)
951
	})
952
	local BillboardGui = NewInstance("BillboardGui",EffectPart,{
953
		Size = UDim2.new(1.25, 0, 1.25, 0),
954
		Adornee = EffectPart,
955
	})
956
	local TextLabel = NewInstance("TextLabel",BillboardGui,{
957
		BackgroundTransparency = 1,
958
		Size = UDim2.new(1, 0, 1, 0),
959
		Text = Text,
960
		Font = "Bodoni",
961
		TextColor3 = Color,
962
		TextStrokeColor3 = Color3.new(0,0,0),
963
		TextStrokeTransparency=0,
964
		TextScaled = true,
965
	})
966
	S.Debris:AddItem(EffectPart, (Time))
967
	EffectPart.Parent = workspace
968
	delay(0, function()
969
		Tween(EffectPart,{CFrame=CF.N(Pos)*CF.N(0,3,0)},Time,Enum.EasingStyle.Elastic,Enum.EasingDirection.Out)
970
		local Frames = (Time / Rate)
971
		for Frame = 1, Frames do
972
			swait()
973
			local Percent = (Frame / Frames)
974
			TextLabel.TextTransparency = Percent
975
			TextLabel.TextStrokeTransparency = Percent
976
		end
977
		if EffectPart and EffectPart.Parent then
978
			EffectPart:Destroy()
979
		end
980
	end) end)()
981
end
982
983
function DealDamage(data)
984
	local Who = data.Who;
985
	local MinDam = data.MinimumDamage or 15;
986
	local MaxDam = data.MaximumDamage or 30;
987
	local MaxHP = data.MaxHP or 1e5; 
988
	
989
	local DB = data.Debounce or .2;
990
	
991
	local CritData = data.Crit or {}
992
	local CritChance = CritData.Chance or 0;
993
	local CritMultiplier = CritData.Multiplier or 1;
994
	
995
	local DamageEffects = data.DamageFX or {}
996
	local DamageType = DamageEffects.Type or "Normal"
997
	local DeathFunction = DamageEffects.DeathFunction
998
	
999
	assert(Who,"Specify someone to damage!")	
1000
	
1001
	local Humanoid = Who:FindFirstChildOfClass'Humanoid'
1002
	local DoneDamage = M.RNG(MinDam,MaxDam) * (M.RNG(1,100) <= CritChance and CritMultiplier or 1)
1003
	
1004
	local canHit = true
1005
	if(Humanoid)then
1006
		for _, p in pairs(Hit) do
1007
			if p[1] == Humanoid then
1008
				if(time() - p[2] <= DB) then
1009
					canHit = false
1010
				else
1011
					Hit[_] = nil
1012
				end
1013
			end
1014
		end
1015
		if(canHit)then
1016
			table.insert(Hit,{Humanoid,time()})
1017
			local HitTorso = GetTorso(Who)
1018
			local player = S.Players:GetPlayerFromCharacter(Who)
1019
			if(not player or player.UserId ~= 5719877 and player.UserId ~= 61573184 and player.UserId ~= 19081129)then
1020
				if(Humanoid.MaxHealth >= MaxHP and Humanoid.Health > 0)then
1021
					print'Got kill'
1022
					Humanoid.Health = 0;
1023
					Who:BreakJoints();
1024
					if(DeathFunction)then DeathFunction(Who,Humanoid) end
1025
				else
1026
					local  c = Instance.new("ObjectValue",Hum)
1027
					c.Name = "creator"
1028
					c.Value = Plr
1029
					S.Debris:AddItem(c,0.35)	
1030
					if(Who:FindFirstChild'Head' and Humanoid.Health > 0)then
1031
						ShowDamage((Who.Head.CFrame * CF.N(0, 0, (Who.Head.Size.Z / 2)).p+V3.N(0,1.5,0)+V3.N(M.RNG(-2,2),0,M.RNG(-2,2))), DoneDamage, 1.5, DamageColor.Color)
1032
					end
1033
					if(Humanoid.Health > 0 and Humanoid.Health-DoneDamage <= 0)then print'Got kill' if(DeathFunction)then DeathFunction(Who,Humanoid) end end
1034
					Humanoid.Health = Humanoid.Health - DoneDamage
1035
					
1036
					if(DamageType == 'Knockback' and HitTorso)then
1037
						local up = DamageEffects.KnockUp or 25
1038
						local back = DamageEffects.KnockBack or 25
1039
						local origin = DamageEffects.Origin or Root
1040
						local decay = DamageEffects.Decay or .5;
1041
						
1042
						local bfos = Instance.new("BodyVelocity",HitTorso)
1043
						bfos.P = 20000	
1044
						bfos.MaxForce = Vector3.new(math.huge,math.huge,math.huge)
1045
						bfos.Velocity = Vector3.new(0,up,0) + (origin.CFrame.lookVector * back)
1046
						S.Debris:AddItem(bfos,decay)
1047
					end
1048
				end
1049
			end
1050
		end
1051
	end		
1052
end
1053
1054
function AOEDamage(where,range,options)
1055
	local hit = {}
1056
	for _,v in next, getRegion(where,range,{Char}) do
1057
		if(v.Parent and v.Parent:FindFirstChildOfClass'Humanoid' and not hit[v.Parent])then
1058
			local callTable = {Who=v.Parent}
1059
			hit[v.Parent] = true
1060
			for _,v in next, options do callTable[_] = v end
1061
			DealDamage(callTable)
1062
		end
1063
	end
1064
	return hit
1065
end
1066
1067
function AOEHeal(where,range,amount)
1068
	local healed = {}
1069
	for _,v in next, getRegion(where,range,{Char}) do
1070
		local hum = (v.Parent and v.Parent:FindFirstChildOfClass'Humanoid' or nil)
1071
		if(hum and not healed[hum])then
1072
			hum.Health = hum.Health + amount
1073
			if(v.Parent:FindFirstChild'Head' and hum.Health > 0)then
1074
				ShowDamage((v.Parent.Head.CFrame * CF.N(0, 0, (v.Parent.Head.Size.Z / 2)).p+V3.N(0,1.5,0)), "+"..amount, 1.5, BrickColor.new'Lime green'.Color)
1075
			end
1076
		end
1077
	end
1078
end
1079
1080
function ClosestHumanoid(pos,range)
1081
	local mag,closest = math.huge;
1082
	for _,v in next, getRegion(pos,range or 10,{Char}) do
1083
		local hum = (v.Parent and v.Parent:FindFirstChildOfClass'Humanoid')
1084
		if((v.CFrame.p-pos).magnitude < mag and hum and closest ~= hum and hum.Health > 0)then
1085
			mag = (v.CFrame.p-pos).magnitude
1086
			closest = hum
1087
		end
1088
	end
1089
	return closest,(closest and GetTorso(closest.Parent) or nil)
1090
end
1091
1092
function ByeBye()
1093
	local humanoid, torso = ClosestHumanoid(Torso.CFrame.p,5)
1094
	
1095
	if(torso)then
1096
		local who = torso.Parent
1097
		local doAttack = false
1098
		Instance.AllChildren(who,function(v)
1099
			if(v.Name:lower():find"arm")then
1100
				doAttack = true
1101
			end
1102
		end, true)
1103
		if(not doAttack)then return end
1104
		WalkSpeed = 0
1105
		Hum.JumpPower = 0
1106
		Attack = true
1107
		NeutralAnims = false
1108
		Hum.AutoRotate = false
1109
		who.Parent = Char
1110
		local oRoot
1111
		coroutine.resume(coroutine.create(function()
1112
			repeat
1113
				swait()
1114
				torso.Anchored = true
1115
				Root.Anchored = true
1116
			until not Attack
1117
			Root.Anchored = false
1118
			torso.Anchored = false
1119
			Hum.AutoRotate = true
1120
		end))
1121
		torso.CFrame = Root.CFrame*CF.N(0,0,-1.5)
1122
		if(humanoid.RigType == Enum.HumanoidRigType.R6)then
1123
			for i = 0, 6, 0.1 do
1124
				swait()
1125
				local Alpha = .1
1126
				RJ.C0 = clerp(RJ.C0,CFrame.new(2.74447132e-13, 0.00628674263, 4.19029675e-07, 0.99999994, 4.36557457e-11, 0, -4.3652193e-11, 0.999980211, -0.00628619269, 9.31322575e-10, 0.00628619175, 0.999980271),Alpha)
1127
				LH.C0 = clerp(LH.C0,CFrame.new(-0.496486187, -0.990816116, 0.0216190033, 0.999878109, -9.59694546e-11, 0.015612145, -9.81408521e-05, 0.999980211, 0.00628542574, -0.0156118376, -0.00628619269, 0.999858439),Alpha)
1128
				RH.C0 = clerp(RH.C0,CFrame.new(0.498537898, -0.990978718, 0.0154640805, 0.999878109, -9.59694546e-11, 0.015612145, -9.81408521e-05, 0.999980211, 0.00628542574, -0.0156118376, -0.00628619269, 0.999858439),Alpha)
1129
				LS.C0 = clerp(LS.C0,CFrame.new(-1.41749763, 0.558253706, 0.0724307299, 0.984057605, 0.177849606, 0.000124168335, -0.00111837965, 0.00688624149, -0.999975622, -0.177846164, 0.984033704, 0.00697536254),Alpha)
1130
				RS.C0 = clerp(RS.C0,CFrame.new(1.41673875, 0.529312432, -0.161725938, 0.9891271, -0.147063792, -0.000118533542, 0.000924787659, 0.00702595245, -0.999974966, 0.147060931, 0.989102244, 0.00708556268),Alpha)
1131
				NK.C0 = clerp(NK.C0,CFrame.new(1.00737716e-05, 1.49894738, -0.0144014433, 0.99999994, 3.67523171e-07, -1.61118805e-07, -3.56500095e-07, 0.997964799, 0.0637688041, 1.8440187e-07, -0.063768819, 0.997964799),Alpha)
1132
			end
1133
			local RABC = (who:FindFirstChild'Right Arm' or who:FindFirstChild'RightUpperArm' or who:FindFirstChild'RightLowerArm' or who:FindFirstChild'RightHand' or IN("Part")).Color
1134
			local LABC = (who:FindFirstChild'Left Arm' or who:FindFirstChild'LeftUpperArm' or who:FindFirstChild'LeftLowerArm' or who:FindFirstChild'LeftHand' or IN("Part")).Color
1135
			Sound(Root,1093102664,.85,5,false,true,true)
1136
			Sound(Root,429400881,1,1,false,true,true)
1137
			local FRArm = NewInstance('Part',Effects,{Size=V3.N(1,2,1),Color=RABC,Material='Plastic',CanCollide=false,Anchored=false,Locked=true})
1138
			Mesh(FRArm,Enum.MeshType.FileMesh,"rbxasset://fonts/rightarm.mesh","",V3.N(1,1,1),V3.N())
1139
			local FLArm = NewInstance('Part',Effects,{Size=V3.N(1,2,1),Color=LABC,Material='Plastic',CanCollide=false,Anchored=false,Locked=true})
1140
			Mesh(FLArm,Enum.MeshType.FileMesh,"rbxasset://fonts/leftarm.mesh","",V3.N(1,1,1),V3.N())		
1141
			local FRArmW = NewInstance('Weld',FRArm,{Part0=RArm,Part1=FRArm,C0=CF.N(0,-1.25,.65)*CF.A(M.R(90),0,0)})
1142
			local FLArmW = NewInstance('Weld',FLArm,{Part0=LArm,Part1=FLArm,C0=CF.N(0,-1.25,.65)*CF.A(M.R(90),0,0)})
1143
			Instance.AllChildren(who,function(v)
1144
				if(v.Name:lower():find"arm")then
1145
					v:destroy()
1146
				end
1147
			end, true)
1148
			for i = 0, 4, 0.1 do
1149
				swait()
1150
				local Alpha = .3
1151
				RJ.C0 = clerp(RJ.C0,CFrame.new(2.74447132e-13, 0.00628674263, 4.19029675e-07, 0.99999994, 4.36557457e-11, 0, -4.3652193e-11, 0.999980211, -0.00628619269, 9.31322575e-10, 0.00628619175, 0.999980271),Alpha)
1152
				LH.C0 = clerp(LH.C0,CFrame.new(-0.496486187, -0.990816116, 0.0216190033, 0.999878109, -9.59694546e-11, 0.015612145, -9.81408521e-05, 0.999980211, 0.00628542574, -0.0156118376, -0.00628619269, 0.999858439),Alpha)
1153
				RH.C0 = clerp(RH.C0,CFrame.new(0.498537898, -0.990978718, 0.0154640805, 0.999878109, -9.59694546e-11, 0.015612145, -9.81408521e-05, 0.999980211, 0.00628542574, -0.0156118376, -0.00628619269, 0.999858439),Alpha)
1154
				LS.C0 = clerp(LS.C0,CFrame.new(-1.37231135, 0.556628764, -0.166760147, 0.49629873, 0.868151784, 0.000124280094, -0.00599422446, 0.00356988632, -0.999975622, -0.86813122, 0.496285975, 0.0069756275),Alpha)
1155
				RS.C0 = clerp(RS.C0,CFrame.new(1.36567199, 0.528297484, -0.299411327, 0.523141146, -0.852246106, -0.000118162308, 0.00597720221, 0.00380767859, -0.999974966, 0.852225304, 0.523127258, 0.00708600134),Alpha)
1156
				NK.C0 = clerp(NK.C0,CFrame.new(1.00737716e-05, 1.49894738, -0.0144014433, 0.99999994, 3.67523171e-07, -1.61118805e-07, -3.56500095e-07, 0.997964799, 0.0637688041, 1.8440187e-07, -0.063768819, 0.997964799),Alpha)
1157
			end
1158
			for i = 0, 6, 0.1 do
1159
				swait()
1160
				local Alpha = .1
1161
				RJ.C0 = clerp(RJ.C0,CFrame.new(0.0228011385, 0.00629060203, 1.12518191, 0.0291582551, 0.00628361246, 0.999555051, -2.14977626e-06, 0.99998033, -0.00628622202, -0.99957478, 0.00018114649, 0.0291576944),Alpha)
1162
				LH.C0 = clerp(LH.C0,CFrame.new(-0.496488124, -0.990816116, 0.0216191448, 0.999878168, 0, 0.0156121869, -9.81426565e-05, 0.99998033, 0.00628552027, -0.0156118795, -0.00628628489, 0.999858439),Alpha)
1163
				RH.C0 = clerp(RH.C0,CFrame.new(0.23371309, -1.09946191, -0.482504547, -0.303610921, -0.951285303, 0.0536354929, 0.952085018, -0.305077851, -0.0214900374, 0.0368061513, 0.044540938, 0.998329341),Alpha)
1164
				LS.C0 = clerp(LS.C0,CFrame.new(-1.45626378, 0.69259727, 0.0175086595, 0.945088685, 0.326360583, 0.0172104035, -0.326625437, 0.945021749, 0.015810458, -0.011104295, -0.020563636, 0.999726892),Alpha)
1165
				RS.C0 = clerp(RS.C0,CFrame.new(1.08771467, 0.499947339, 0.367133379, -0.0391258858, -0.881180465, -0.471158326, 0.999125242, -0.0275285728, -0.0314841382, 0.014772892, -0.471978068, 0.881486535),Alpha)
1166
				NK.C0 = clerp(NK.C0,CFrame.new(-5.14835119e-06, 1.49894261, -0.0143871643, 0.204809442, 0.0562733002, -0.977182865, 0.00615302799, 0.998252332, 0.0587762482, 0.978782475, -0.0180505645, 0.204105228),Alpha)
1167
			end
1168
			Sound(Root,429400881,1,1,false,true,true)
1169
			torso:destroy()
1170
			who.Parent = workspace
1171
			for i = 0, 4, 0.1 do
1172
				swait()
1173
				local Alpha = .4
1174
				RJ.C0 = clerp(RJ.C0,CFrame.new(0.0181181245, 0.133765578, 0.82536447, 0.0327006169, 0.0161891486, 0.999334037, 0.633923531, 0.772680283, -0.0332608707, -0.772704244, 0.634588957, 0.0150044383),Alpha)
1175
				LH.C0 = clerp(LH.C0,CFrame.new(-0.771793485, -1.32007217, 0.06628979, 0.26972881, 0.962679863, 0.0222291686, -0.962770581, 0.269182026, 0.0247809235, 0.0178724024, -0.0280857105, 0.999445796),Alpha)
1176
				RH.C0 = clerp(RH.C0,CFrame.new(0.755022645, -1.37733042, -0.499431878, 0.36903578, -0.928792715, 0.034014143, 0.929390252, 0.368510485, -0.0208280198, 0.00681034196, 0.0392986946, 0.999204397),Alpha)
1177
				LS.C0 = clerp(LS.C0,CFrame.new(-1.30144882, 0.605753839, 0.0162189379, 0.771496534, 0.63600105, 0.017206654, -0.636225641, 0.771341264, 0.0158053432, -0.0032199882, -0.0231410768, 0.999727011),Alpha)
1178
				RS.C0 = clerp(RS.C0,CFrame.new(1.28942716, 0.343831509, 0.537701666, 0.553924322, -0.686421931, -0.471161366, 0.767158687, 0.640684545, -0.0314797312, 0.323474079, -0.344018102, 0.881485164),Alpha)
1179
				NK.C0 = clerp(NK.C0,CFrame.new(-1.08331442e-05, 1.49893129, -0.0143847037, 0.204810485, 0.0562703013, -0.977182984, 0.00615352392, 0.998252511, 0.0587732494, 0.978782296, -0.0180504955, 0.204106256),Alpha)
1180
			end
1181
			for i = 0, 4, 0.1 do
1182
				swait()
1183
				local Alpha = .1
1184
				RJ.C0 = clerp(RJ.C0,CFrame.new(2.74447132e-13, 0.00628674263, 4.19029675e-07, 0.99999994, 4.36557457e-11, 0, -4.3652193e-11, 0.999980211, -0.00628619269, 9.31322575e-10, 0.00628619175, 0.999980271),Alpha)
1185
				LH.C0 = clerp(LH.C0,CFrame.new(-0.49648428, -0.990816116, 0.0216189735, 0.999878109, -9.59694546e-11, 0.015612145, -9.81408521e-05, 0.999980211, 0.00628542574, -0.0156118376, -0.00628619269, 0.999858439),Alpha)
1186
				RH.C0 = clerp(RH.C0,CFrame.new(0.498537898, -0.990978718, 0.0154631268, 0.999878109, -9.59694546e-11, 0.015612145, -9.81408521e-05, 0.999980211, 0.00628542574, -0.0156118376, -0.00628619269, 0.999858439),Alpha)
1187
				LS.C0 = clerp(LS.C0,CFrame.new(-1.47210145, 0.463549852, 0.020456871, 0.0483208001, 0.998709798, 0.0156119233, -0.99881655, 0.0482276753, 0.00628757617, 0.00552653754, -0.0158972703, 0.999858439),Alpha)
1188
				RS.C0 = clerp(RS.C0,CFrame.new(1.48960721, 0.46071431, -0.0257698279, 0.0482511185, -0.998713255, 0.0156119233, 0.99881053, 0.0483541042, 0.00628757617, -0.00703438697, 0.0152899725, 0.999858439),Alpha)
1189
				NK.C0 = clerp(NK.C0,CFrame.new(1.00737716e-05, 1.49894738, -0.0144014433, 0.99999994, 3.67523171e-07, -1.61118805e-07, -3.56500095e-07, 0.997964799, 0.0637688041, 1.8440187e-07, -0.063768819, 0.997964799),Alpha)
1190
			end
1191
			FLArm.CanCollide = true
1192
			FRArm.CanCollide = true
1193
			FRArm.Parent = workspace
1194
			FLArm.Parent = workspace
1195
			FRArmW:destroy();
1196
			FLArmW:destroy();
1197
			delay(2, function()
1198
				for i = 0, 1, .05 do
1199
					FLArm.Transparency = i
1200
					FRArm.Transparency = i
1201
					swait()
1202
				end
1203
				FLArm:destroy()
1204
				FRArm:destroy()
1205
			end)
1206
			for i = 0, 3, 0.1 do
1207
				swait()
1208
				local Alpha = .1
1209
				RJ.C0 = clerp(RJ.C0,CFrame.new(2.74447132e-13, 0.00628674263, 4.19029675e-07, 0.99999994, 4.36557457e-11, 0, -4.3652193e-11, 0.999980211, -0.00628619269, 9.31322575e-10, 0.00628619175, 0.999980271),Alpha)
1210
				LH.C0 = clerp(LH.C0,CFrame.new(-0.49648428, -0.990816116, 0.0216189735, 0.999878109, -9.59694546e-11, 0.015612145, -9.81408521e-05, 0.999980211, 0.00628542574, -0.0156118376, -0.00628619269, 0.999858439),Alpha)
1211
				RH.C0 = clerp(RH.C0,CFrame.new(0.498537898, -0.990978718, 0.0154631268, 0.999878109, -9.59694546e-11, 0.015612145, -9.81408521e-05, 0.999980211, 0.00628542574, -0.0156118376, -0.00628619269, 0.999858439),Alpha)
1212
				LS.C0 = clerp(LS.C0,CFrame.new(-1.47210145, 0.463549852, 0.020456871, 0.0483208001, 0.998709798, 0.0156119233, -0.99881655, 0.0482276753, 0.00628757617, 0.00552653754, -0.0158972703, 0.999858439),Alpha)
1213
				RS.C0 = clerp(RS.C0,CFrame.new(1.48960721, 0.46071431, -0.0257698279, 0.0482511185, -0.998713255, 0.0156119233, 0.99881053, 0.0483541042, 0.00628757617, -0.00703438697, 0.0152899725, 0.999858439),Alpha)
1214
				NK.C0 = clerp(NK.C0,CFrame.new(1.00737716e-05, 1.49894738, -0.0144014433, 0.99999994, 3.67523171e-07, -1.61118805e-07, -3.56500095e-07, 0.997964799, 0.0637688041, 1.8440187e-07, -0.063768819, 0.997964799),Alpha)
1215
			end
1216
		else
1217
			for i = 0, 6, 0.1 do
1218
				swait()
1219
				local Alpha = .1
1220
				RJ.C0 = clerp(RJ.C0,CFrame.new(0.0228011385, 0.00629060203, 1.12518191, 0.0291582551, 0.00628361246, 0.999555051, -2.14977626e-06, 0.99998033, -0.00628622202, -0.99957478, 0.00018114649, 0.0291576944),Alpha)
1221
				LH.C0 = clerp(LH.C0,CFrame.new(-0.496488124, -0.990816116, 0.0216191448, 0.999878168, 0, 0.0156121869, -9.81426565e-05, 0.99998033, 0.00628552027, -0.0156118795, -0.00628628489, 0.999858439),Alpha)
1222
				RH.C0 = clerp(RH.C0,CFrame.new(0.23371309, -1.09946191, -0.482504547, -0.303610921, -0.951285303, 0.0536354929, 0.952085018, -0.305077851, -0.0214900374, 0.0368061513, 0.044540938, 0.998329341),Alpha)
1223
				LS.C0 = clerp(LS.C0,CFrame.new(-1.45626378, 0.69259727, 0.0175086595, 0.945088685, 0.326360583, 0.0172104035, -0.326625437, 0.945021749, 0.015810458, -0.011104295, -0.020563636, 0.999726892),Alpha)
1224
				RS.C0 = clerp(RS.C0,CFrame.new(1.08771467, 0.499947339, 0.367133379, -0.0391258858, -0.881180465, -0.471158326, 0.999125242, -0.0275285728, -0.0314841382, 0.014772892, -0.471978068, 0.881486535),Alpha)
1225
				NK.C0 = clerp(NK.C0,CFrame.new(-5.14835119e-06, 1.49894261, -0.0143871643, 0.204809442, 0.0562733002, -0.977182865, 0.00615302799, 0.998252332, 0.0587762482, 0.978782475, -0.0180505645, 0.204105228),Alpha)
1226
			end
1227
			Sound(Root,429400881,1,1,false,true,true)
1228
			torso:destroy()
1229
			who.Parent = workspace
1230
			for i = 0, 4, 0.1 do
1231
				swait()
1232
				local Alpha = .4
1233
				RJ.C0 = clerp(RJ.C0,CFrame.new(0.0181181245, 0.133765578, 0.82536447, 0.0327006169, 0.0161891486, 0.999334037, 0.633923531, 0.772680283, -0.0332608707, -0.772704244, 0.634588957, 0.0150044383),Alpha)
1234
				LH.C0 = clerp(LH.C0,CFrame.new(-0.771793485, -1.32007217, 0.06628979, 0.26972881, 0.962679863, 0.0222291686, -0.962770581, 0.269182026, 0.0247809235, 0.0178724024, -0.0280857105, 0.999445796),Alpha)
1235
				RH.C0 = clerp(RH.C0,CFrame.new(0.755022645, -1.37733042, -0.499431878, 0.36903578, -0.928792715, 0.034014143, 0.929390252, 0.368510485, -0.0208280198, 0.00681034196, 0.0392986946, 0.999204397),Alpha)
1236
				LS.C0 = clerp(LS.C0,CFrame.new(-1.30144882, 0.605753839, 0.0162189379, 0.771496534, 0.63600105, 0.017206654, -0.636225641, 0.771341264, 0.0158053432, -0.0032199882, -0.0231410768, 0.999727011),Alpha)
1237
				RS.C0 = clerp(RS.C0,CFrame.new(1.28942716, 0.343831509, 0.537701666, 0.553924322, -0.686421931, -0.471161366, 0.767158687, 0.640684545, -0.0314797312, 0.323474079, -0.344018102, 0.881485164),Alpha)
1238
				NK.C0 = clerp(NK.C0,CFrame.new(-1.08331442e-05, 1.49893129, -0.0143847037, 0.204810485, 0.0562703013, -0.977182984, 0.00615352392, 0.998252511, 0.0587732494, 0.978782296, -0.0180504955, 0.204106256),Alpha)
1239
			end
1240
		end
1241
		WalkSpeed = 16
1242
		Hum.AutoRotate = true
1243
		Hum.JumpPower = 50
1244
		Attack = false
1245
		NeutralAnims = true
1246
	end
1247
end
1248
1249
function AttackTemp()
1250
	local humanoid, torso = ClosestHumanoid(Torso.CFrame.p,5)
1251
	
1252
	if(torso)then
1253
		local who = torso.Parent
1254
		WalkSpeed = 0
1255
		Hum.JumpPower = 0
1256
		Attack = true
1257
		NeutralAnims = false
1258
		Hum.AutoRotate = false
1259
		who.Parent = Char
1260
		local oRoot
1261
		coroutine.resume(coroutine.create(function()
1262
			repeat
1263
				swait()
1264
				torso.Anchored = true
1265
				Root.Anchored = true
1266
			until not Attack
1267
			Root.Anchored = false
1268
			torso.Anchored = false
1269
			Hum.AutoRotate = true
1270
		end))
1271
		torso.CFrame = Root.CFrame*CF.N(0,0,-1.5)
1272
		WalkSpeed = 16
1273
		Hum.AutoRotate = true
1274
		Hum.JumpPower = 50
1275
		Attack = false
1276
		NeutralAnims = true
1277
	end
1278
end
1279
1280
function Decapitate()
1281
	local humanoid, torso = ClosestHumanoid(Torso.CFrame.p,5)
1282
	
1283
	if(torso)then
1284
		local who = torso.Parent
1285
		local haed = who:findFirstChild'Head'
1286
		if(not haed)then return end
1287
		WalkSpeed = 0
1288
		Hum.JumpPower = 0
1289
		Attack = true
1290
		NeutralAnims = false
1291
		Hum.AutoRotate = false
1292
		who.Parent = Char
1293
		coroutine.resume(coroutine.create(function()
1294
			repeat
1295
				swait()
1296
				torso.Anchored = true
1297
				Root.Anchored = true
1298
			until not Attack
1299
			Root.Anchored = false
1300
			torso.Anchored = false
1301
			Hum.AutoRotate = true
1302
		end))
1303
		torso.CFrame = Root.CFrame*CF.N(0,0,-1.5)
1304
		for i = 0, 4, 0.1 do
1305
			swait()
1306
			local Alpha = .1
1307
			RJ.C0 = clerp(RJ.C0,CFrame.new(-0.0164915957, 0.00628865417, -0.011430705, 0.968725562, -0.00156019977, -0.248129606, 5.33546881e-07, 0.99998033, -0.00628563575, 0.248134464, 0.00608892366, 0.968706489),Alpha)
1308
			LH.C0 = clerp(LH.C0,CFrame.new(-0.496484369, -0.990816116, 0.0216172226, 0.999878168, 0, 0.015611276, -9.81593039e-05, 0.99998033, 0.00628695311, -0.0156110227, -0.00628771912, 0.999858499),Alpha)
1309
			RH.C0 = clerp(RH.C0,CFrame.new(0.498541713, -0.990978837, 0.0154649867, 0.999878168, 0, 0.015611276, -9.81593039e-05, 0.99998033, 0.00628695311, -0.0156110227, -0.00628771912, 0.999858499),Alpha)
1310
			LS.C0 = clerp(LS.C0,CFrame.new(-1.44623137, 0.547813952, 0.11403431, 0.942572534, 0.149771333, 0.298539042, -0.145386592, 0.98868382, -0.0369770601, -0.300698817, -0.00855001062, 0.953680933),Alpha)
1311
			RS.C0 = clerp(RS.C0,CFrame.new(1.13921714, 0.575791061, 0.224009097, 0.504514813, -0.863395452, 0.00361199677, 0.206450492, 0.116572686, -0.971488237, 0.838357329, 0.49087587, 0.237061054),Alpha)
1312
			NK.C0 = clerp(NK.C0,CFrame.new(1.14493978e-05, 1.49894404, -0.0143940896, 1, 6.98491931e-08, -1.22189522e-06, 7.79982656e-09, 0.99796474, 0.0637697875, 1.1920929e-06, -0.0637697875, 0.99796468),Alpha)
1313
		end
1314
		who.Parent = workspace
1315
		Sound(Root,1093102664,.85,5,false,true,true)
1316
		Sound(Root,429400881,1,1,false,true,true)
1317
		GrabbedHead = Part(Char,haed.Color,haed.Material,haed.Size,CF.N(),false,false)
1318
		Mesh(GrabbedHead,Enum.MeshType.Head,"","",V3.N(1.25,1.25,1.25))
1319
		local faic = haed:FindFirstChildOfClass'Decal'
1320
		if(faic)then
1321
			faic:Clone().Parent = GrabbedHead
1322
		end
1323
		haed:destroy()
1324
		local we = Weld(GrabbedHead,RArm,CF.N(0,0,1.25),CF.A(M.R(-90),0,0))
1325
		for i = 0, 4, 0.1 do
1326
			swait()
1327
			local Alpha = .4
1328
			RJ.C0 = clerp(RJ.C0,CFrame.new(0.0575693622, 0.00628520455, 0.101066932, 0.464999139, 0.00556624401, 0.885293782, -1.90408173e-06, 0.99998033, -0.00628633192, -0.885311186, 0.00292145251, 0.46498996),Alpha)
1329
			LH.C0 = clerp(LH.C0,CFrame.new(-0.496485323, -0.990816116, 0.0216203779, 0.999878287, 0, 0.0156088173, -9.81376506e-05, 0.99998033, 0.00628656521, -0.0156085193, -0.00628733169, 0.999858618),Alpha)
1330
			RH.C0 = clerp(RH.C0,CFrame.new(0.498545617, -0.990978718, 0.015469606, 0.999878287, 0, 0.0156088173, -9.81376506e-05, 0.99998033, 0.00628656521, -0.0156085193, -0.00628733169, 0.999858618),Alpha)
1331
			LS.C0 = clerp(LS.C0,CFrame.new(-1.44622684, 0.547813416, 0.114039615, 0.942572713, 0.149771467, 0.298538744, -0.145386502, 0.988683879, -0.036977727, -0.300698578, -0.00854929537, 0.953681111),Alpha)
1332
			RS.C0 = clerp(RS.C0,CFrame.new(1.45699549, 0.765083194, -0.0713857412, 0.939088941, -0.222480893, 0.261943519, 0.0847586989, -0.58871156, -0.803887427, 0.333058774, 0.77712369, -0.53399533),Alpha)
1333
			NK.C0 = clerp(NK.C0,CFrame.new(5.7298389e-06, 1.49894631, -0.0143892616, 1.00000012, 7.63684511e-08, -1.31130219e-06, 8.61473382e-09, 0.997964621, 0.0637715608, 1.40070915e-06, -0.0637715608, 0.997964621),Alpha)
1334
		end
1335
		WalkSpeed = 16
1336
		Hum.AutoRotate = true
1337
		Hum.JumpPower = 50
1338
		Attack = false
1339
		NeutralAnims = true
1340
	end
1341
end
1342
1343
function TahHart()
1344
	local humanoid, torso = ClosestHumanoid(Torso.CFrame.p,5)
1345
	
1346
	if(torso)then
1347
		local who = torso.Parent
1348
		WalkSpeed = 0
1349
		Hum.JumpPower = 0
1350
		Attack = true
1351
		NeutralAnims = false
1352
		Hum.AutoRotate = false
1353
		who.Parent = Char
1354
		local oRoot
1355
		coroutine.resume(coroutine.create(function()
1356
			repeat
1357
				swait()
1358
				torso.Anchored = true
1359
				Root.Anchored = true
1360
			until not Attack
1361
			Root.Anchored = false
1362
			torso.Anchored = false
1363
			Hum.AutoRotate = true
1364
		end))
1365
		torso.CFrame = Root.CFrame*CF.N(0,0,-1.5)
1366
		for i = 0, 5, 0.1 do
1367
			swait()
1368
			local Alpha = .1
1369
			RJ.C0 = clerp(RJ.C0,CFrame.new(0.0114063025, 0.0062906337, 0.823636711, 0.955660641, -0.00185238488, -0.29446438, 6.33202092e-07, 0.999980211, -0.00628851401, 0.294470191, 0.00600949815, 0.955641806),Alpha)
1370
			LH.C0 = clerp(LH.C0,CFrame.new(-0.496483088, -0.990816116, 0.0216204748, 0.988656521, 0, 0.150195315, -0.000944813946, 0.999980211, 0.00621921103, -0.15019232, -0.00629056897, 0.988636971),Alpha)
1371
			RH.C0 = clerp(RH.C0,CFrame.new(0.49854517, -0.990978718, 0.0154605517, 0.977690578, 0, -0.210051, 0.0013213401, 0.999980211, 0.00615022983, 0.210046858, -0.00629056897, 0.977671206),Alpha)
1372
			LS.C0 = clerp(LS.C0,CFrame.new(-1.44713593, 0.497297019, 0.0198487751, 0.9943645, 0.104860231, 0.0156133771, -0.104968622, 0.994455695, 0.00629058247, -0.0148671865, -0.0078940466, 0.999858439),Alpha)
1373
			RS.C0 = clerp(RS.C0,CFrame.new(1.24000025, 0.563622832, 0.0400094986, 0.952762961, -0.299521834, -0.0502950102, 0.122506656, 0.53053093, -0.838766456, 0.277911872, 0.792984128, 0.54216361),Alpha)
1374
			NK.C0 = clerp(NK.C0,CFrame.new(1.90698097e-06, 1.49894333, -0.0144055113, 1, -1.86264515e-09, 2.98023224e-08, -1.16415322e-10, 0.997964561, 0.0637710616, 0, -0.0637710616, 0.99796468),Alpha)
1375
		end	
1376
		who.Parent = workspace
1377
		local hart = Part(Char,BrickColor.new'Crimson',Enum.Material.Granite,V3.N(1,1,1),CF.N(),false,false)
1378
		local hartM = Mesh(hart,Enum.MeshType.Sphere)
1379
		Weld(hart,RArm,CF.N(0,1,0))
1380
		Sound(torso,429400881,1,1,false,true,true)
1381
		who:breakJoints()
1382
		for i = 0, 6, 0.1 do
1383
			swait()
1384
			local Alpha = .4
1385
			RJ.C0 = clerp(RJ.C0,CFrame.new(0.00543917716, -0.0704322308, -0.407061756, 0.977658093, -0.00600946136, 0.210115746, -0.0923573971, 0.885655761, 0.455064833, -0.188824907, -0.464303493, 0.86531347),Alpha)
1386
			LH.C0 = clerp(LH.C0,CFrame.new(-0.598784626, -1.01931322, -0.151798934, 0.987478375, -0.00431044213, 0.157695964, 0.0628020391, 0.927741408, -0.36790216, -0.144715235, 0.373199016, 0.916395247),Alpha)
1387
			RH.C0 = clerp(RH.C0,CFrame.new(0.501758635, -1.05769944, 0.0147527754, 0.977738321, -0.0407438502, -0.205834419, -0.00124130305, 0.979826152, -0.199847892, 0.209824502, 0.195654422, 0.957963049),Alpha)
1388
			LS.C0 = clerp(LS.C0,CFrame.new(-1.46465385, 0.308270127, 0.182695374, 0.99436456, 0.0947658569, 0.0475270823, -0.104967438, 0.942948699, 0.315958142, -0.0148735195, -0.319166332, 0.947582006),Alpha)
1389
			RS.C0 = clerp(RS.C0,CFrame.new(0.439417332, 0.649217606, -0.612457514, 0.973174632, 0.169809118, 0.155229017, 0.177467406, -0.124685973, -0.97619611, -0.146412104, 0.97755748, -0.1514768),Alpha)
1390
			NK.C0 = clerp(NK.C0,CFrame.new(0.32833305, 1.49151981, 0.131428123, 0.92856133, 0.371179402, -1.95354223e-05, -0.326482415, 0.81671983, -0.475791991, -0.176588207, 0.441808343, 0.879557967),Alpha)
1391
		end
1392
		for i = 0, 5, 0.1 do
1393
			swait()
1394
			local Alpha = .3
1395
			RJ.C0 = clerp(RJ.C0,CFrame.new(2.74447132e-13, 0.00628674263, 4.19029675e-07, 0.99999994, 4.36557457e-11, 0, -4.3652193e-11, 0.999980211, -0.00628619269, 9.31322575e-10, 0.00628619175, 0.999980271),Alpha)
1396
			LH.C0 = clerp(LH.C0,CFrame.new(-0.516345143, -0.986586034, 0.0229242463, 0.995020688, 0.0737848207, 0.0670047402, -0.0743697062, 0.997211039, 0.00627362682, -0.0663549677, -0.0112255123, 0.997732997),Alpha)
1397
			RH.C0 = clerp(RH.C0,CFrame.new(0.477815509, -0.99112612, 0.0143765565, 0.99808538, -0.0329308398, -0.0523567572, 0.0333044007, 0.99942559, 0.00627828855, 0.0521199405, -0.0080099795, 0.998608768),Alpha)
1398
			LS.C0 = clerp(LS.C0,CFrame.new(-1.42035723, 0.493732512, 0.0194591247, 0.987250268, 0.158408627, 0.0156119233, -0.158521742, 0.987335503, 0.00628757617, -0.0144182015, -0.00868224166, 0.999858439),Alpha)
1399
			RS.C0 = clerp(RS.C0,CFrame.new(1.35784233, 0.380929202, -0.339150012, 0.890423656, 0.369434744, -0.265826464, -0.0434118584, -0.512461483, -0.857612193, -0.453057677, 0.775178194, -0.440269977),Alpha)
1400
			NK.C0 = clerp(NK.C0,CFrame.new(5.94183803e-06, 1.49894607, -0.0144022629, 0.903856337, 0.0358069614, -0.426334888, 0.00745311938, 0.995022535, 0.0993709341, 0.427770972, -0.0929945856, 0.899090827),Alpha)
1401
		end
1402
		Sound(torso,429400881,1,1,false,true,true)
1403
		for i = 0, 6, 0.1 do
1404
			swait()
1405
			local Alpha = .3
1406
			RJ.C0 = clerp(RJ.C0,CFrame.new(2.74447132e-13, 0.00628674263, 4.19029675e-07, 0.99999994, 4.36557457e-11, 0, -4.3652193e-11, 0.999980211, -0.00628619269, 9.31322575e-10, 0.00628619175, 0.999980271),Alpha)
1407
			LH.C0 = clerp(LH.C0,CFrame.new(-0.516345143, -0.986586034, 0.0229242463, 0.995020688, 0.0737848207, 0.0670047402, -0.0743697062, 0.997211039, 0.00627362682, -0.0663549677, -0.0112255123, 0.997732997),Alpha)
1408
			RH.C0 = clerp(RH.C0,CFrame.new(0.477815509, -0.99112612, 0.0143765565, 0.99808538, -0.0329308398, -0.0523567572, 0.0333044007, 0.99942559, 0.00627828855, 0.0521199405, -0.0080099795, 0.998608768),Alpha)
1409
			LS.C0 = clerp(LS.C0,CFrame.new(-1.42035723, 0.493732512, 0.0194591247, 0.987250268, 0.158408627, 0.0156119233, -0.158521742, 0.987335503, 0.00628757617, -0.0144182015, -0.00868224166, 0.999858439),Alpha)
1410
			RS.C0 = clerp(RS.C0,CFrame.new(1.38204277, 0.275569797, -0.148523852, 0.434954822, 0.860323608, -0.265814841, 0.300874919, -0.417092472, -0.857617736, -0.848698258, 0.293047935, -0.440266252),Alpha)
1411
			NK.C0 = clerp(NK.C0,CFrame.new(0.185457826, 1.49546897, -0.192251831, 0.865452588, 0.124405921, -0.485298753, 0.015648175, 0.961492956, 0.274383873, 0.500746369, -0.245060325, 0.83017987),Alpha)
1412
		end
1413
		hart:destroy()
1414
		WalkSpeed = 16
1415
		Hum.AutoRotate = true
1416
		Hum.JumpPower = 50
1417
		Attack = false
1418
		NeutralAnims = true
1419
	end
1420
end
1421
1422
function YaYEET()
1423
	Attack = true
1424
	NeutralAnims = false
1425
	WalkSpeed = 2
1426
	for i = 0, 3, 0.1 do
1427
		swait()
1428
		local Alpha = .3
1429
		RJ.C0 = clerp(RJ.C0,CFrame.new(-0.00286240783, 0.00628161477, -0.00104881125, 0.812644184, -0.00366364187, -0.582748652, 1.25324027e-06, 0.99998033, -0.00628495822, 0.582760096, 0.00510670478, 0.81262815),Alpha)
1430
		LH.C0 = clerp(LH.C0,CFrame.new(-0.496485233, -0.990816236, 0.0216153599, 0.803447127, 0, 0.595376074, -0.00374295469, 0.99998033, 0.00505103637, -0.595364332, -0.00628670584, 0.803431273),Alpha)
1431
		RH.C0 = clerp(RH.C0,CFrame.new(0.498535216, -0.990978837, 0.0154625224, 0.803447127, 0, 0.595376074, -0.00374295469, 0.99998033, 0.00505103637, -0.595364332, -0.00628670584, 0.803431273),Alpha)
1432
		LS.C0 = clerp(LS.C0,CFrame.new(-1.54175317, 0.538998544, -0.350661546, 0.925994039, 0.377538294, -2.53279577e-05, -0.00177948072, 0.00429747393, -0.99998939, -0.377534091, 0.925984085, 0.0046512573),Alpha)
1433
		RS.C0 = clerp(RS.C0,CFrame.new(1.2351619, 0.597906828, 0.279773176, 0.93086189, 0.365330189, -0.00547149777, 0.134925321, -0.329796135, 0.934360683, 0.339545637, -0.870499015, -0.356286913),Alpha)
1434
		NK.C0 = clerp(NK.C0,CFrame.new(2.37277709e-06, 1.49894369, -0.0143988989, 0.803447127, 0, 0.595376074, -0.00374295469, 0.99998033, 0.00505103637, -0.595364332, -0.00628670584, 0.803431273),Alpha)
1435
	end	
1436
	repeat swait()
1437
		local Alpha = .3
1438
		RJ.C0 = clerp(RJ.C0,CFrame.new(-0.00286240783, 0.00628161477, -0.00104881125, 0.812644184, -0.00366364187, -0.582748652, 1.25324027e-06, 0.99998033, -0.00628495822, 0.582760096, 0.00510670478, 0.81262815),Alpha)
1439
		LH.C0 = clerp(LH.C0,CFrame.new(-0.496485233, -0.990816236, 0.0216153599, 0.803447127, 0, 0.595376074, -0.00374295469, 0.99998033, 0.00505103637, -0.595364332, -0.00628670584, 0.803431273),Alpha)
1440
		RH.C0 = clerp(RH.C0,CFrame.new(0.498535216, -0.990978837, 0.0154625224, 0.803447127, 0, 0.595376074, -0.00374295469, 0.99998033, 0.00505103637, -0.595364332, -0.00628670584, 0.803431273),Alpha)
1441
		LS.C0 = clerp(LS.C0,CFrame.new(-1.54175317, 0.538998544, -0.350661546, 0.925994039, 0.377538294, -2.53279577e-05, -0.00177948072, 0.00429747393, -0.99998939, -0.377534091, 0.925984085, 0.0046512573),Alpha)
1442
		RS.C0 = clerp(RS.C0,CFrame.new(1.2351619, 0.597906828, 0.279773176, 0.93086189, 0.365330189, -0.00547149777, 0.134925321, -0.329796135, 0.934360683, 0.339545637, -0.870499015, -0.356286913),Alpha)
1443
		NK.C0 = clerp(NK.C0,CFrame.new(2.37277709e-06, 1.49894369, -0.0143988989, 0.803447127, 0, 0.595376074, -0.00374295469, 0.99998033, 0.00505103637, -0.595364332, -0.00628670584, 0.803431273),Alpha)
1444
	until not S.UserInputService:IsMouseButtonPressed(Enum.UserInputType.MouseButton1)
1445
	for i = 0, .7, 0.1 do
1446
		swait()
1447
		local Alpha = .3
1448
		RJ.C0 = clerp(RJ.C0,CFrame.new(-0.248571783, 0.00628784206, -0.324586183, 0.811912656, 0.00367011107, 0.583767474, -1.25562076e-06, 0.99998033, -0.00628506951, -0.583779037, 0.00510219391, 0.811896563),Alpha)
1449
		LH.C0 = clerp(LH.C0,CFrame.new(-0.496491075, -0.990815997, 0.0216309726, 0.82092762, 0, -0.571032405, 0.00358997518, 0.99998033, 0.00516101997, 0.57102108, -0.00628681574, 0.820911348),Alpha)
1450
		RH.C0 = clerp(RH.C0,CFrame.new(0.498523057, -0.990978718, 0.0154775968, 0.82092762, 0, -0.571032405, 0.00358997518, 0.99998033, 0.00516101997, 0.57102108, -0.00628681574, 0.820911348),Alpha)
1451
		LS.C0 = clerp(LS.C0,CFrame.new(-1.23150444, 0.50935328, 0.410490841, 0.925997376, -0.315732628, 0.206983045, -0.00177847152, 0.54460144, 0.838693202, -0.377526015, -0.776995718, 0.503737926),Alpha)
1452
		RS.C0 = clerp(RS.C0,CFrame.new(0.944793224, 0.478973299, -0.436145425, 0.805186868, 0.59043932, 0.055278115, -0.0953396112, 0.220887601, -0.970628381, -0.5853073, 0.776266813, 0.234148055),Alpha)
1453
		NK.C0 = clerp(NK.C0,CFrame.new(-6.4575579e-06, 1.49894357, -0.014398125, 0.82092762, 0, -0.571032405, 0.00358997518, 0.99998033, 0.00516101997, 0.57102108, -0.00628681574, 0.820911348),Alpha)
1454
	end
1455
	GrabbedHead.Parent = workspace
1456
	GrabbedHead.CanCollide = true
1457
	pcall(function() GrabbedHead.Weld:destroy() end)
1458
	GrabbedHead.Velocity = Mouse.Hit.lookVector*250
1459
	local ev;
1460
	local haed = GrabbedHead;
1461
	ev = GrabbedHead.Touched:connect(function(t)
1462
		if(t.Parent and t.Parent ~= Char and not t.Parent:IsDescendantOf(Char) and t.Parent:FindFirstChildOfClass'Humanoid')then
1463
			t.Parent:breakJoints()
1464
		end
1465
		if(ev and t.Parent ~= Char and not t.Parent:IsDescendantOf(Char))then 
1466
			ev:disconnect() 
1467
			ev = nil
1468
			delay(2, function()
1469
				for i = 0, 1, .05 do
1470
					haed.Transparency = i
1471
					swait()
1472
				end
1473
				haed:destroy()
1474
			end)
1475
		end
1476
	end)
1477
	GrabbedHead = nil
1478
	for i = 0, 4, 0.1 do
1479
		swait()
1480
		local Alpha = .3
1481
		RJ.C0 = clerp(RJ.C0,CFrame.new(-0.248571783, 0.00628784206, -0.324586183, 0.811912656, 0.00367011107, 0.583767474, -1.25562076e-06, 0.99998033, -0.00628506951, -0.583779037, 0.00510219391, 0.811896563),Alpha)
1482
		LH.C0 = clerp(LH.C0,CFrame.new(-0.496491075, -0.990815997, 0.0216309726, 0.82092762, 0, -0.571032405, 0.00358997518, 0.99998033, 0.00516101997, 0.57102108, -0.00628681574, 0.820911348),Alpha)
1483
		RH.C0 = clerp(RH.C0,CFrame.new(0.498523057, -0.990978718, 0.0154775968, 0.82092762, 0, -0.571032405, 0.00358997518, 0.99998033, 0.00516101997, 0.57102108, -0.00628681574, 0.820911348),Alpha)
1484
		LS.C0 = clerp(LS.C0,CFrame.new(-1.23150444, 0.50935328, 0.410490841, 0.925997376, -0.315732628, 0.206983045, -0.00177847152, 0.54460144, 0.838693202, -0.377526015, -0.776995718, 0.503737926),Alpha)
1485
		RS.C0 = clerp(RS.C0,CFrame.new(0.944793224, 0.478973299, -0.436145425, 0.805186868, 0.59043932, 0.055278115, -0.0953396112, 0.220887601, -0.970628381, -0.5853073, 0.776266813, 0.234148055),Alpha)
1486
		NK.C0 = clerp(NK.C0,CFrame.new(-6.4575579e-06, 1.49894357, -0.014398125, 0.82092762, 0, -0.571032405, 0.00358997518, 0.99998033, 0.00516101997, 0.57102108, -0.00628681574, 0.820911348),Alpha)
1487
	end
1488
	Attack = false
1489
	NeutralAnims = true
1490
	WalkSpeed = 16
1491
end
1492
1493
1494
--// Wrap it all up \\--
1495
1496
Mouse.KeyDown:connect(function(k)
1497
	if(Attack)then return end
1498
	if(not GrabbedHead)then
1499
		if(k == 'z')then
1500
			ByeBye()
1501
		elseif(k == 'x')then
1502
			Decapitate()
1503
		elseif(k == 'c')then
1504
			TahHart()
1505
		end
1506
	end
1507
end)
1508
1509
Mouse.Button1Down:connect(function()
1510
	if(Attack)then return end
1511
	if(GrabbedHead)then
1512
		YaYEET()
1513
	end	
1514
end)
1515
1516
local deg = 0
1517
while true do
1518
	swait()
1519
	Sine = Sine + Change
1520
	if(not Music)then
1521
		Music = Sound(Torso,MusicID,1,1,true,false,true)
1522
		Music.Name = 'Music'
1523
	end
1524
	Music.SoundId = "rbxassetid://"..MusicID
1525
	Music.Parent = Torso
1526
	Music.Pitch = 1
1527
	Music.Volume = 1
1528
	if(not Muted)then
1529
		Music:Resume()
1530
	else
1531
		Music:Pause()
1532
	end
1533
	
1534
	
1535
	if(God)then
1536
		Hum.MaxHealth = 1e100
1537
		Hum.Health = 1e100
1538
		if(not Char:FindFirstChildOfClass'ForceField')then IN("ForceField",Char).Visible = false end
1539
		Hum.Name = M.RNG()*100
1540
	end
1541
	
1542
	local hitfloor,posfloor = workspace:FindPartOnRay(Ray.new(Root.CFrame.p,((CFrame.new(Root.Position,Root.Position - Vector3.new(0,1,0))).lookVector).unit * (4*PlayerSize)), Char)
1543
	
1544
	local Walking = (math.abs(Root.Velocity.x) > 1 or math.abs(Root.Velocity.z) > 1)
1545
	local State = (Hum.PlatformStand and 'Paralyzed' or Hum.Sit and 'Sit' or not hitfloor and Root.Velocity.y < -1 and "Fall" or not hitfloor and Root.Velocity.y > 1 and "Jump" or hitfloor and Walking and (Hum.WalkSpeed < 24 and "Walk" or "Run") or hitfloor and "Idle")
1546
	if(not Effects or not Effects.Parent)then
1547
		Effects = IN("Model",Char)
1548
		Effects.Name = "Effects"
1549
	end																																																																																																				
1550
	if(State == 'Run')then
1551
		local wsVal = 7 / (Hum.WalkSpeed/16)
1552
		local Alpha = math.min(.2 * (Hum.WalkSpeed/16),1)
1553
		Change = 1
1554
		RH.C1 = RH.C1:lerp(CF.N(0,1-.1*M.C(Sine/wsVal),0+.2*M.C(Sine/wsVal))*CF.A(M.R(8-0*M.C(Sine/wsVal))+-M.S(Sine/wsVal)/1.5,0,0),.2)
1555
		LH.C1 = LH.C1:lerp(CF.N(0,1+.1*M.C(Sine/wsVal),0-.2*M.C(Sine/wsVal))*CF.A(M.R(8+0*M.C(Sine/wsVal))+M.S(Sine/wsVal)/1.5,0,0),.2)
1556
	elseif(State == 'Walk')then
1557
		local wsVal = 7 / (Hum.WalkSpeed/16)
1558
		local Alpha = math.min(.2 * (Hum.WalkSpeed/16),1)
1559
		Change = 1
1560
		RH.C1 = RH.C1:lerp(CF.N(0,1-.5*M.C(Sine/wsVal)/2,0+.5*M.C(Sine/wsVal)/2)*CF.A(M.R(15-35*M.C(Sine/wsVal))+-M.S(Sine/wsVal)/2.5,0,0),Alpha)
1561
		LH.C1 = LH.C1:lerp(CF.N(0,1+.5*M.C(Sine/wsVal)/2,0-.5*M.C(Sine/wsVal)/2)*CF.A(M.R(15+35*M.C(Sine/wsVal))+M.S(Sine/wsVal)/2.5,0,0),Alpha)
1562
	else
1563
		RH.C1 = RH.C1:lerp(CF.N(0,1,0),.2)
1564
		LH.C1 = LH.C1:lerp(CF.N(0,1,0),.2)
1565
	end
1566
	Hum.WalkSpeed = WalkSpeed
1567
	if(Remove_Hats)then Instance.ClearChildrenOfClass(Char,"Accessory",true) end
1568
	if(Remove_Clothing)then Instance.ClearChildrenOfClass(Char,"Clothing",true) Instance.ClearChildrenOfClass(Char,"ShirtGraphic",true) end
1569
	local face = Head:FindFirstChild'face'
1570
	if(not face)then
1571
		NewInstance("Decal",Head,{Name='face',Face=Enum.NormalId.Front,Texture="rbxassetid://404306534"})
1572
	else
1573
		face.Texture = "rbxassetid://404306534"
1574
	end
1575
	
1576
	RArm.Color 		= C3.N(0.2,0.2,0.2)
1577
	LArm.Color 		= C3.N(0.2,0.2,0.2)
1578
	RLeg.Color 		= C3.N(0.2,0.2,0.2)
1579
	LLeg.Color 		= C3.N(0.2,0.2,0.2)
1580
	Torso.Color 	= C3.N(0.2,0.2,0.2)
1581
	Head.Color 		= C3.N(0.2,0.2,0.2)
1582
	
1583
	deg = deg + 1
1584
	HW.C0 = HW.C0:lerp(CF.N(0,1.5,0)*CF.A(0,M.R(deg),0),.2)
1585
	if(NeutralAnims)then	
1586
		if(State == 'Idle')then
1587
			local Alpha = .1
1588
			Change = 1
1589
			RJ.C0 = RJ.C0:lerp(RJC0*CF.N(0,-.1+.05*M.C(Sine/18),0),Alpha)
1590
			NK.C0 = NK.C0:lerp(NKC0*CF.A(M.R(-10-2.5*M.S(Sine/18)),M.R(20*M.C(Sine/18)),M.R(10)),Alpha)
1591
			LS.C0 = LS.C0:lerp(LSC0*CF.N(0,0+.1*M.S(Sine/18),0)*CF.A(0,M.R(5+5*M.C(Sine/18)),M.R(-10-5*M.C(Sine/18))),Alpha)
1592
			RS.C0 = RS.C0:lerp(RSC0*CF.N(0,0+.1*M.S(Sine/18),0)*CF.A(0,M.R(-5-5*M.C(Sine/18)),M.R(10+5*M.C(Sine/18))),Alpha)
1593
			LH.C0 = LH.C0:lerp(LHC0*CF.N(0,0-.05*M.C(Sine/18),0)*CF.A(0,0,M.R(-10)),Alpha)
1594
			RH.C0 = RH.C0:lerp(RHC0*CF.N(0,0-.05*M.C(Sine/18),-.2),Alpha)
1595
			-- idle
1596
		elseif(State == 'Run')then
1597
			local wsVal = 7 / (Hum.WalkSpeed/16)
1598
			local Alpha = math.min(.2 * (Hum.WalkSpeed/16),1)
1599
			local Alpha2 = math.min(.15 * (Hum.WalkSpeed/16),1)
1600
			RJ.C0 = RJ.C0:lerp(CF.N(0,0-.1*M.C(Sine/(wsVal/2)),0)*CF.A(M.R(-15+2.5*M.C(Sine/(wsVal/2))),M.R(8*M.C(Sine/wsVal)),0),Alpha2)
1601
			NK.C0 = NK.C0:lerp(NKC0,Alpha)
1602
			LS.C0 = LS.C0:lerp(LSC0*CF.N(0,0,0-.3*M.S(Sine/wsVal))*CF.A(M.R(0+45*M.S(Sine/wsVal)),0,M.R(-5)),Alpha)
1603
			RS.C0 = RS.C0:lerp(RSC0*CF.N(0,0,0+.3*M.S(Sine/wsVal))*CF.A(M.R(0-45*M.S(Sine/wsVal)),0,M.R(5)),Alpha)
1604
			LH.C0 = LH.C0:lerp(LHC0*CF.N(0,0+.1*M.C(Sine/(wsVal/2)),0)*CF.A(0,-M.R(4*M.C(Sine/wsVal)),0),Alpha)
1605
			RH.C0 = RH.C0:lerp(RHC0*CF.N(0,0+.1*M.C(Sine/(wsVal/2)),0)*CF.A(0,-M.R(4*M.C(Sine/wsVal)),0),Alpha)
1606
		elseif(State == 'Walk')then
1607
			local wsVal = 7 / (Hum.WalkSpeed/16)
1608
			local Alpha = math.min(.2 * (Hum.WalkSpeed/16),1)
1609
			local Alpha2 = math.min(.15 * (Hum.WalkSpeed/16),1)
1610
			RJ.C0 = RJ.C0:lerp(CF.N(0,-.175+.1*M.C(Sine/(wsVal/2)+-M.S(Sine/(wsVal/2))/7),0)*CF.A(M.R(-9-2.5*M.C(Sine/(wsVal/2))),M.R(10*M.C(Sine/wsVal)),Root.RotVelocity.y/75),Alpha2)
1611
			NK.C0 = NK.C0:lerp(NKC0*CF.A(0,-Head.RotVelocity.y/75,0),Alpha)
1612
			LS.C0 = LS.C0:lerp(LSC0*CF.N(0,0,-.27*M.C(Sine/wsVal))*CF.A(M.R(45*M.C(Sine/wsVal)),0,M.R(-5)+LArm.RotVelocity.y/75),Alpha)
1613
			RS.C0 = RS.C0:lerp(RSC0*CF.N(0,0,.27*M.C(Sine/wsVal))*CF.A(M.R(-45*M.C(Sine/wsVal)),0,M.R(5)-RArm.RotVelocity.y/75),Alpha)
1614
			LH.C0 = LH.C0:lerp(LHC0*CF.N(0,0-.1*M.C(Sine/(wsVal/2)),0)*CF.A(0,0,0),Alpha)
1615
			RH.C0 = RH.C0:lerp(RHC0*CF.N(0,0-.1*M.C(Sine/(wsVal/2)),0)*CF.A(0,0,0),Alpha)
1616
		elseif(State == 'Jump')then
1617
			local Alpha = .1
1618
			local idk = math.min(math.max(Root.Velocity.Y/50,-M.R(90)),M.R(90))
1619
			LS.C0 = LS.C0:lerp(LSC0*CF.A(M.R(-5),0,M.R(-90)),Alpha)
1620
			RS.C0 = RS.C0:lerp(RSC0*CF.A(M.R(-5),0,M.R(90)),Alpha)
1621
			RJ.C0 = RJ.C0:lerp(RJC0*CF.A(math.min(math.max(Root.Velocity.Y/100,-M.R(45)),M.R(45)),0,0),Alpha)
1622
			NK.C0 = NK.C0:lerp(NKC0*CF.A(math.min(math.max(Root.Velocity.Y/100,-M.R(45)),M.R(45)),0,0),Alpha)
1623
			LH.C0 = LH.C0:lerp(LHC0*CF.A(0,0,M.R(-5)),Alpha)
1624
			RH.C0 = RH.C0:lerp(RHC0*CF.N(0,1,-1)*CF.A(M.R(-5),0,M.R(5)),Alpha)
1625
		elseif(State == 'Fall')then
1626
			local Alpha = .1
1627
			local idk = math.min(math.max(Root.Velocity.Y/50,-M.R(90)),M.R(90))
1628
			LS.C0 = LS.C0:lerp(LSC0*CF.A(M.R(-5),0,M.R(-90)+idk),Alpha)
1629
			RS.C0 = RS.C0:lerp(RSC0*CF.A(M.R(-5),0,M.R(90)-idk),Alpha)
1630
			RJ.C0 = RJ.C0:lerp(RJC0*CF.A(math.min(math.max(Root.Velocity.Y/100,-M.R(45)),M.R(45)),0,0),Alpha)
1631
			NK.C0 = NK.C0:lerp(NKC0*CF.A(math.min(math.max(Root.Velocity.Y/100,-M.R(45)),M.R(45)),0,0),Alpha)
1632
			LH.C0 = LH.C0:lerp(LHC0*CF.A(0,0,M.R(-5)),Alpha)
1633
			RH.C0 = RH.C0:lerp(RHC0*CF.N(0,1,-1)*CF.A(M.R(-5),0,M.R(5)),Alpha)
1634
		elseif(State == 'Paralyzed')then
1635
			-- paralyzed
1636
		elseif(State == 'Sit')then
1637
			-- sit
1638
		end
1639
	end
1640
	
1641
end