View difference between Paste ID: UiKWQBeQ and 73FE1F49
SHOW: | | - or go back to the newest paste.
1
--//====================================================\\--
2
--||  CREATED BY SHACKLUSTER
3
--\\====================================================//--
4
5
-- This script has been converted to FE by iPxter
6
7
8
if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
9
local Player,Mouse,mouse,UserInputService,ContextActionService = owner
10
do
11
	print("FE Compatibility code by Mokiros | Translated to FE by iPxter")
12
	script.Parent = Player.Character
13
14
	--RemoteEvent for communicating
15
	local Event = Instance.new("RemoteEvent")
16
	Event.Name = "UserInput_Event"
17
18
	--Fake event to make stuff like Mouse.KeyDown work
19
	local function fakeEvent()
20
		local t = {_fakeEvent=true,Connect=function(self,f)self.Function=f end}
21
		t.connect = t.Connect
22
		return t
23
	end
24
25
	--Creating fake input objects with fake variables
26
    local m = {Target=nil,Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent()}
27
	local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()}
28
	local CAS = {Actions={},BindAction=function(self,name,fun,touch,...)
29
		CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil
30
	end}
31
	--Merged 2 functions into one by checking amount of arguments
32
	CAS.UnbindAction = CAS.BindAction
33
34
	--This function will trigger the events that have been :Connect()'ed
35
	local function te(self,ev,...)
36
		local t = m[ev]
37
		if t and t._fakeEvent and t.Function then
38
			t.Function(...)
39
		end
40
	end
41
	m.TrigEvent = te
42
	UIS.TrigEvent = te
43
44
	Event.OnServerEvent:Connect(function(plr,io)
45
	    if plr~=Player then return end
46
		if io.isMouse then
47
			m.Target = io.Target
48
			m.Hit = io.Hit
49
		else
50
			local b = io.UserInputState == Enum.UserInputState.Begin
51
			if io.UserInputType == Enum.UserInputType.MouseButton1 then
52
				return m:TrigEvent(b and "Button1Down" or "Button1Up")
53
			end
54
			for _,t in pairs(CAS.Actions) do
55
				for _,k in pairs(t.Keys) do
56
					if k==io.KeyCode then
57
						t.Function(t.Name,io.UserInputState,io)
58
					end
59
				end
60
			end
61
			m:TrigEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower())
62
			UIS:TrigEvent(b and "InputBegan" or "InputEnded",io,false)
63
	    end
64
	end)
65
	Event.Parent = NLS([==[
66
	local Player = game:GetService("Players").LocalPlayer
67
	local Event = script:WaitForChild("UserInput_Event")
68
69
	local UIS = game:GetService("UserInputService")
70
	local input = function(io,a)
71
		if a then return end
72
		--Since InputObject is a client-side instance, we create and pass table instead
73
		Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState})
74
	end
75
	UIS.InputBegan:Connect(input)
76
	UIS.InputEnded:Connect(input)
77
78
	local Mouse = Player:GetMouse()
79
	local h,t
80
	--Give the server mouse data 30 times every second, but only if the values changed
81
	--If player is not moving their mouse, client won't fire events
82
	while wait(1/30) do
83
		if h~=Mouse.Hit or t~=Mouse.Target then
84
			h,t=Mouse.Hit,Mouse.Target
85
			Event:FireServer({isMouse=true,Target=t,Hit=h})
86
		end
87
	end]==],Player.Character)
88
	Mouse,mouse,UserInputService,ContextActionService = m,m,UIS,CAS
89
end
90
91
wait(0.2)
92
93
Player = owner
94
PlayerGui = Player.PlayerGui
95
Cam = workspace.CurrentCamera
96
Backpack = Player.Backpack
97
Character = Player.Character
98
Humanoid = Character.Humanoid
99
Mouse = Player:GetMouse()
100
RootPart = Character["HumanoidRootPart"]
101
Torso = Character["Torso"]
102
Head = Character["Head"]
103
RightArm = Character["Right Arm"]
104
LeftArm = Character["Left Arm"]
105
RightLeg = Character["Right Leg"]
106
LeftLeg = Character["Left Leg"]
107
RootJoint = RootPart["RootJoint"]
108
Neck = Torso["Neck"]
109
RightShoulder = Torso["Right Shoulder"]
110
LeftShoulder = Torso["Left Shoulder"]
111
RightHip = Torso["Right Hip"]
112
LeftHip = Torso["Left Hip"]
113
local sick = Instance.new("Sound",Character)
114
sick.SoundId = "rbxassetid://143884682"
115
sick.Looped = true
116
sick.Pitch = 0.9
117
sick.Volume = 10
118
sick:Play()
119
120
Character.Shirt.ShirtTemplate = "http://www.roblox.com/asset/?id=1050773670" -- everything went in an unexpected manner
121
Character.Pants.PantsTemplate = "http://www.roblox.com/asset/?id=785471273"
122
123
for i,v in pairs(Character:children()) do
124
    if v:IsA("Accessory") then
125
        v:Destroy()
126
    end
127
end
128
129
Hair7 = Instance.new("Part")
130
Hair7.Parent = Player.Character
131
Hair7.Name = "Hair"
132
Hair7.CanCollide = false
133
Hair7.Locked = true
134
Hair7.TopSurface = "Smooth"
135
Hair7.BottomSurface = "Smooth"
136
Hair7.formFactor = "Symmetric"
137
Hair7.Material = "Metal"
138
Hair7.BrickColor = BrickColor.new("Navy blue")
139
Hair7.CFrame = Player.Character.Torso.CFrame
140
Hair7.Size = Vector3.new(1, 1, 1)
141
Hair7.Transparency = 0
142
143
Weld1 = Instance.new("Weld")
144
Weld1.Parent = Player.Character.Head
145
Weld1.Part0 = Player.Character.Head
146
Weld1.Part1 = Hair7
147
Weld1.C0 = CFrame.new(0, 1, 0)
148
149
Mesh = Instance.new("SpecialMesh")
150
Mesh.Offset = Vector3.new(0, -0.2, 0)
151
Mesh.Parent = Hair7
152
Mesh.Scale = Vector3.new(1.2, 1.2, 1.2)
153
Mesh.MeshType = "FileMesh"
154
Mesh.MeshId = "http://www.roblox.com/asset/?id=163989519"
155
Mesh.TextureId = "http://www.roblox.com/asset/?id=163989706"
156
157
158
Hair77 = Instance.new("Part")
159
Hair77.Parent = Player.Character
160
Hair77.Name = "Hair"
161
Hair77.CanCollide = false
162
Hair77.Locked = true
163
Hair77.TopSurface = "Smooth"
164
Hair77.BottomSurface = "Smooth"
165
Hair77.formFactor = "Symmetric"
166
Hair77.Material = "Metal"
167
Hair77.BrickColor = BrickColor.new("Deep blue")
168
Hair77.CFrame = Player.Character.Torso.CFrame
169
Hair77.Size = Vector3.new(1, 1, 1)
170
Hair77.Transparency = 0.5
171
172
Weld1 = Instance.new("Weld")
173
Weld1.Parent = Player.Character.Head
174
Weld1.Part0 = Player.Character.Head
175
Weld1.Part1 = Hair77
176
Weld1.C0 = CFrame.new(0, 1, 0)
177
178
Mesh2 = Instance.new("SpecialMesh")
179
Mesh2.Offset = Vector3.new(0, -1.5, 0)
180
Mesh2.Parent = Hair77
181
Mesh2.Scale = Vector3.new(1.2, 1.2, 1.2)
182
Mesh2.MeshType = "FileMesh"
183
Mesh2.MeshId = "http://www.roblox.com/asset/?id=1254392112"
184
Mesh2.TextureId = ""
185
186
local naeeym2 = Instance.new("BillboardGui",Character)
187
naeeym2.AlwaysOnTop = true
188
naeeym2.Size = UDim2.new(5,35,2,35)
189
naeeym2.StudsOffset = Vector3.new(0,3,0)
190
naeeym2.Adornee = Character.Head
191
naeeym2.Name = "Name"
192
--naeeym2.PlayerToHideFrom = Player
193
naeeym2.MaxDistance = 200
194
local tecks2 = Instance.new("TextLabel",naeeym2)
195
tecks2.BackgroundTransparency = 1
196
tecks2.TextScaled = true
197
tecks2.BorderSizePixel = 0
198
tecks2.Text = "Necro the Ice Dragon"
199
tecks2.Font = "SciFi"
200
tecks2.TextSize = 30
201
tecks2.TextStrokeTransparency = 1
202
tecks2.TextColor3 = Color3.new(0,0,255)
203
tecks2.TextStrokeColor3 = Color3.new(0,0,0)
204
tecks2.Size = UDim2.new(1,0,0.5,0)
205
tecks2.Parent = naeeym2
206
207
IT = Instance.new
208
CF = CFrame.new
209
VT = Vector3.new
210
RAD = math.rad
211
C3 = Color3.new
212
UD2 = UDim2.new
213
BRICKC = BrickColor.new
214
ANGLES = CFrame.Angles
215
EULER = CFrame.fromEulerAnglesXYZ
216
COS = math.cos
217
ACOS = math.acos
218
SIN = math.sin
219
ASIN = math.asin
220
ABS = math.abs
221
MRANDOM = math.random
222
FLOOR = math.floor
223
224
function CreateMesh(MESH, PARENT, MESHTYPE, MESHID, TEXTUREID, SCALE, OFFSET)
225
	local NEWMESH = IT(MESH)
226
	if MESH == "SpecialMesh" then
227
		NEWMESH.MeshType = MESHTYPE
228
		if MESHID ~= "nil" and MESHID ~= "" then
229
			NEWMESH.MeshId = "http://www.roblox.com/asset/?id="..MESHID
230
		end
231
		if TEXTUREID ~= "nil" and TEXTUREID ~= "" then
232
			NEWMESH.TextureId = "http://www.roblox.com/asset/?id="..TEXTUREID
233
		end
234
	end
235
	NEWMESH.Offset = OFFSET or VT(0, 0, 0)
236
	NEWMESH.Scale = SCALE
237
	NEWMESH.Parent = PARENT
238
	return NEWMESH
239
end
240
241
function CreatePart(FORMFACTOR, PARENT, MATERIAL, REFLECTANCE, TRANSPARENCY, BRICKCOLOR, NAME, SIZE)
242
	local NEWPART = IT("Part")
243
	NEWPART.formFactor = FORMFACTOR
244
	NEWPART.Reflectance = REFLECTANCE
245
	NEWPART.Transparency = TRANSPARENCY
246
	NEWPART.CanCollide = false
247
	NEWPART.Locked = true
248
	NEWPART.BrickColor = BRICKC(tostring(BRICKCOLOR))
249
	NEWPART.Name = NAME
250
	NEWPART.Size = SIZE
251
	NEWPART.Position = Torso.Position
252
	NEWPART.Material = MATERIAL
253
	NEWPART:BreakJoints()
254
	NEWPART.Parent = PARENT
255
	return NEWPART
256
end
257
258
259
--//=================================\\
260
--||		  CUSTOMIZATION
261
--\\=================================//
262
263
Class_Name = "₱Ɽł₴₥.exe"
264
Weapon_Name = "Add-ons"
265
266
Custom_Colors = {
267
	Custom_Color_1 = BRICKC("Toothpaste"); --1st color for the weapon.
268
	Custom_Color_2 = BRICKC("Deep blue"); --2nd color for the weapon.
269
270
	Custom_Color_3 = BRICKC("Toothpaste"); --Color for the abilities.
271
	Custom_Color_4 = BRICKC("Toothpaste"); --Color for the secondary bar.
272
	Custom_Color_5 = BRICKC("Toothpaste"); --Color for the mana bar.
273
	Custom_Color_6 = BRICKC("Toothpastee"); --Color for the health bar.
274
	Custom_Color_7 = BRICKC("Toothpaste"); --Color for the stun bar.
275
276
	Custom_Color_8 = BRICKC("Deep blue"); --Background for the mana bar.
277
	Custom_Color_9 = BRICKC("Deep blue"); --Background for the secondary mana bar.
278
	Custom_Color_10 = BRICKC("Deep blue"); --Background for the stun bar.
279
	Custom_Color_11 = BRICKC("Deep blue"); --Background for the health bar.
280
	Custom_Color_12 = BRICKC("Deep blue"); --Background for the abilities.
281
}
282
283
284
Player_Size = 1 --Size of the player.
285
Animation_Speed = 3
286
Frame_Speed = 1 / 60 -- (1 / 30) OR (1 / 60)
287
288
local Speed = 10
289
Character.Humanoid.WalkSpeed = 10
290
local Effects2 = {}
291
292
--//=================================\\
293
--|| 	  END OF CUSTOMIZATION
294
--\\=================================//
295
296
	local function weldBetween(a, b)
297
	    local weldd = Instance.new("ManualWeld")
298
	    weldd.Part0 = a
299
	    weldd.Part1 = b
300
	    weldd.C0 = CFrame.new()
301
	    weldd.C1 = b.CFrame:inverse() * a.CFrame
302
	    weldd.Parent = a
303
	    return weldd
304
	end
305
306
function createaccessory(attachmentpart,mesh,texture,scale,offset,color)
307
local acs = Instance.new("Part")
308
acs.CanCollide = false
309
acs.Anchored = false
310
acs.Size = Vector3.new(0,0,0)
311
acs.CFrame = attachmentpart.CFrame
312
acs.Parent = Character
313
acs.BrickColor = color
314
    local meshs = Instance.new("SpecialMesh")
315
    meshs.MeshId = mesh
316
    meshs.TextureId = texture
317
    meshs.Parent = acs
318
    meshs.Scale = scale
319
    meshs.Offset = offset
320
weldBetween(attachmentpart,acs)
321
end
322
323
function createbodypart(TYPE,COLOR,PART,OFFSET,SIZE)
324
if TYPE == "Gem" then
325
	local acs = CreatePart(3, Character, "Neon", 0, 0, COLOR, "Part", VT(0,0,0))
326
	acs.Anchored = false
327
    acs.CanCollide = false
328
	acs.CFrame = PART.CFrame
329
	local acs2 = CreateMesh("SpecialMesh", acs, "FileMesh", "9756362", "", SIZE, OFFSET)
330
weldBetween(PART,acs)
331
elseif TYPE == "Skull" then
332
	local acs = CreatePart(3, Character, "Neon", 0, 0, COLOR, "Part", VT(0,0,0))
333
	acs.Anchored = false
334
    acs.CanCollide = false
335
	acs.CFrame = PART.CFrame
336
	local acs2 = CreateMesh("SpecialMesh", acs, "FileMesh", "4770583", "", SIZE, OFFSET)
337
weldBetween(PART,acs)
338
elseif TYPE == "Eye" then
339
    local acs = CreatePart(3, Character, "Neon", 0, 0, COLOR, "Part", VT(0,0,0))
340
    acs.Anchored = false
341
    acs.CanCollide = false
342
    acs.CFrame = PART.CFrame
343
    local acs2 = CreateMesh("SpecialMesh", acs, "Sphere", "", "", SIZE, OFFSET)
344
weldBetween(PART,acs)
345
end
346
end
347
348
--//=================================\\
349
--|| 	      USEFUL VALUES
350
--\\=================================//
351
352
local ROOTC0 = CF(0, 0, 0) * ANGLES(RAD(-90), RAD(0), RAD(180))
353
local NECKC0 = CF(0, 1, 0) * ANGLES(RAD(-90), RAD(0), RAD(180))
354
local RIGHTSHOULDERC0 = CF(-0.5, 0, 0) * ANGLES(RAD(0), RAD(90), RAD(0))
355
local LEFTSHOULDERC0 = CF(0.5, 0, 0) * ANGLES(RAD(0), RAD(-90), RAD(0))
356
local CO1 = 0
357
local CO2 = 0
358
local CO3 = 0
359
local CO4 = 0
360
local CHANGEDEFENSE = 0
361
local CHANGEDAMAGE = 0
362
local CHANGEMOVEMENT = 0
363
local ANIM = "Idle"
364
local ATTACK = false
365
local EQUIPPED = false
366
local HOLD = false
367
local COMBO = 1
368
local LASTPOINT = nil
369
local BLCF = nil
370
local SCFR = nil
371
local STAGGERHITANIM = false
372
local STAGGERANIM = false
373
local STUNANIM = false
374
local CRITCHANCENUMBER = 0
375
local IDLENUMBER = 0
376
local DONUMBER = 0
377
local HANDIDLE = false
378
local SINE = 0
379
local CHANGE = 2 / Animation_Speed
380
local WALKINGANIM = false
381
local WALK = 0
382
local KEYHOLD = false
383
local DISABLEJUMPING = false
384
local HASBEENBLOCKED = false
385
local STUNDELAYNUMBER = 0
386
local MANADELAYNUMBER = 0
387
local SECONDARYMANADELAYNUMBER = 0
388
local ROBLOXIDLEANIMATION = IT("Animation")
389
ROBLOXIDLEANIMATION.Name = "Roblox Idle Animation"
390
ROBLOXIDLEANIMATION.AnimationId = "http://www.roblox.com/asset/?id=180435571"
391
--ROBLOXIDLEANIMATION.Parent = Humanoid
392
local WEAPONGUI = IT("ScreenGui", nil)
393
WEAPONGUI.Name = "Weapon GUI"
394
local WEAPONTOOL = IT("HopperBin", nil)
395
WEAPONTOOL.Name = Weapon_Name
396
local Weapon = IT("Model")
397
Weapon.Name = Weapon_Name
398
local Effects = IT("Folder", Weapon)
399
Effects.Name = "Effects"
400
local ANIMATOR = Humanoid.Animator
401
local ANIMATE = Character.Animate
402
local HITPLAYERSOUNDS = {--[["199149137", "199149186", "199149221", "199149235", "199149269", "199149297"--]]"263032172", "263032182", "263032200", "263032221", "263032252", "263033191"}
403
local HITARMORSOUNDS = {"199149321", "199149338", "199149367", "199149409", "199149452"}
404
local HITWEAPONSOUNDS = {"199148971", "199149025", "199149072", "199149109", "199149119"}
405
local HITBLOCKSOUNDS = {"199148933", "199148947"}
406
local CUTSOUNDS = {"645750958","645747150"}
407
local VICIOUSWOOSH = "658941933"
408
local RELEASESOUND = "565538688"
409
local CHARGESOUND = "565538601"
410
local UNANCHOR = true
411
local MAGICPARTICLE = "1229782954"
412
413
--//=================================\\
414
--\\=================================//
415
416
--//=================================\\
417
--||			  STATS
418
--\\=================================//
419
420
if Character:FindFirstChild("Stats") ~= nil then
421
Character:FindFirstChild("Stats").Parent = nil
422
end
423
424
local Stats = IT("Folder", nil)
425
Stats.Name = "Stats"
426
local ChangeStat = IT("Folder", Stats)
427
ChangeStat.Name = "ChangeStat"
428
local Defense = IT("NumberValue", Stats)
429
Defense.Name = "Defense"
430
Defense.Value = 1
431
local Movement = IT("NumberValue", Stats)
432
Movement.Name = "Movement"
433
Movement.Value = 1
434
local Damage = IT("NumberValue", Stats)
435
Damage.Name = "Damage"
436
Damage.Value = 1
437
local Mana = IT("NumberValue", Stats)
438
Mana.Name = "Mana"
439
Mana.Value = 0
440
local SecondaryMana = IT("NumberValue", Stats)
441
SecondaryMana.Name = "SecondaryMana"
442
SecondaryMana.Value = 0
443
local CanCrit = IT("BoolValue", Stats)
444
CanCrit.Name = "CanCrit"
445
CanCrit.Value = false
446
local CritChance = IT("NumberValue", Stats)
447
CritChance.Name = "CritChance"
448
CritChance.Value = 20
449
local CanPenetrateArmor = IT("BoolValue", Stats)
450
CanPenetrateArmor.Name = "CanPenetrateArmor"
451
CanPenetrateArmor.Value = false
452
local AntiTeamKill = IT("BoolValue", Stats)
453
AntiTeamKill.Name = "AntiTeamKill"
454
AntiTeamKill.Value = false
455
local Rooted = IT("BoolValue", Stats)
456
Rooted.Name = "Rooted"
457
Rooted.Value = false
458
local Block = IT("BoolValue", Stats)
459
Block.Name = "Block"
460
Block.Value = false
461
local RecentEnemy = IT("ObjectValue", Stats)
462
RecentEnemy.Name = "RecentEnemy"
463
RecentEnemy.Value = nil
464
local StaggerHit = IT("BoolValue", Stats)
465
StaggerHit.Name = "StaggerHit"
466
StaggerHit.Value = false
467
local Stagger = IT("BoolValue", Stats)
468
Stagger.Name = "Stagger"
469
Stagger.Value = false
470
local Stun = IT("BoolValue", Stats)
471
Stun.Name = "Stun"
472
Stun.Value = false
473
local StunValue = IT("NumberValue", Stats)
474
StunValue.Name = "StunValue"
475
StunValue.Value = 0
476
477
478
--//=================================\\
479
--\\=================================//
480
481
482
483
484
485
--//=================================\\
486
--|| 	     DEBUFFS / BUFFS
487
--\\=================================//
488
489
local DEFENSECHANGE1 = IT("NumberValue", ChangeStat)
490
DEFENSECHANGE1.Name = "ChangeDefense"
491
DEFENSECHANGE1.Value = 0
492
493
local MOVEMENTCHANGE1 = IT("NumberValue", nil)
494
MOVEMENTCHANGE1.Name = "ChangeMovement"
495
MOVEMENTCHANGE1.Value = 0
496
497
--//=================================\\
498
--\\=================================//
499
500
501
502
503
504
--//=================================\\
505
--|| SAZERENOS' ARTIFICIAL HEARTBEAT
506
--\\=================================//
507
508
ArtificialHB = Instance.new("BindableEvent", script)
509
ArtificialHB.Name = "ArtificialHB"
510
511
script:WaitForChild("ArtificialHB")
512
513
frame = Frame_Speed
514
tf = 0
515
allowframeloss = false
516
tossremainder = false
517
lastframe = tick()
518
script.ArtificialHB:Fire()
519
520
game:GetService("RunService").Heartbeat:connect(function(s, p)
521
	tf = tf + s
522
	if tf >= frame then
523
		if allowframeloss then
524
			script.ArtificialHB:Fire()
525
			lastframe = tick()
526
		else
527
			for i = 1, math.floor(tf / frame) do
528
				script.ArtificialHB:Fire()
529
			end
530
		lastframe = tick()
531
		end
532
		if tossremainder then
533
			tf = 0
534
		else
535
			tf = tf - frame * math.floor(tf / frame)
536
		end
537
	end
538
end)
539
540
--//=================================\\
541
--\\=================================//
542
543
544
545
546
547
--//=================================\\
548
--|| 	      SOME FUNCTIONS
549
--\\=================================//
550
551
function Raycast(POSITION, DIRECTION, RANGE, IGNOREDECENDANTS)
552
	return workspace:FindPartOnRay(Ray.new(POSITION, DIRECTION.unit * RANGE), IGNOREDECENDANTS)
553
end
554
555
function PositiveAngle(NUMBER)
556
	if NUMBER >= 0 then
557
		NUMBER = 0
558
	end
559
	return NUMBER
560
end
561
562
function NegativeAngle(NUMBER)
563
	if NUMBER <= 0 then
564
		NUMBER = 0
565
	end
566
	return NUMBER
567
end
568
569
function Swait(NUMBER)
570
	if NUMBER == 0 or NUMBER == nil then
571
		ArtificialHB.Event:wait()
572
	else
573
		for i = 1, NUMBER do
574
			ArtificialHB.Event:wait()
575
		end
576
	end
577
end
578
579
function QuaternionFromCFrame(cf)
580
	local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components()
581
	local trace = m00 + m11 + m22
582
	if trace > 0 then 
583
		local s = math.sqrt(1 + trace)
584
		local recip = 0.5 / s
585
		return (m21 - m12) * recip, (m02 - m20) * recip, (m10 - m01) * recip, s * 0.5
586
	else
587
		local i = 0
588
		if m11 > m00 then
589
			i = 1
590
		end
591
		if m22 > (i == 0 and m00 or m11) then
592
			i = 2
593
		end
594
		if i == 0 then
595
			local s = math.sqrt(m00 - m11 - m22 + 1)
596
			local recip = 0.5 / s
597
			return 0.5 * s, (m10 + m01) * recip, (m20 + m02) * recip, (m21 - m12) * recip
598
		elseif i == 1 then
599
			local s = math.sqrt(m11 - m22 - m00 + 1)
600
			local recip = 0.5 / s
601
			return (m01 + m10) * recip, 0.5 * s, (m21 + m12) * recip, (m02 - m20) * recip
602
		elseif i == 2 then
603
			local s = math.sqrt(m22 - m00 - m11 + 1)
604
			local recip = 0.5 / s return (m02 + m20) * recip, (m12 + m21) * recip, 0.5 * s, (m10 - m01) * recip
605
		end
606
	end
607
end
608
 
609
function QuaternionToCFrame(px, py, pz, x, y, z, w)
610
	local xs, ys, zs = x + x, y + y, z + z
611
	local wx, wy, wz = w * xs, w * ys, w * zs
612
	local xx = x * xs
613
	local xy = x * ys
614
	local xz = x * zs
615
	local yy = y * ys
616
	local yz = y * zs
617
	local zz = z * zs
618
	return CFrame.new(px, py, pz, 1 - (yy + zz), xy - wz, xz + wy, xy + wz, 1 - (xx + zz), yz - wx, xz - wy, yz + wx, 1 - (xx + yy))
619
end
620
 
621
function QuaternionSlerp(a, b, t)
622
	local cosTheta = a[1] * b[1] + a[2] * b[2] + a[3] * b[3] + a[4] * b[4]
623
	local startInterp, finishInterp;
624
	if cosTheta >= 0.0001 then
625
		if (1 - cosTheta) > 0.0001 then
626
			local theta = ACOS(cosTheta)
627
			local invSinTheta = 1 / SIN(theta)
628
			startInterp = SIN((1 - t) * theta) * invSinTheta
629
			finishInterp = SIN(t * theta) * invSinTheta
630
		else
631
			startInterp = 1 - t
632
			finishInterp = t
633
		end
634
	else
635
		if (1 + cosTheta) > 0.0001 then
636
			local theta = ACOS(-cosTheta)
637
			local invSinTheta = 1 / SIN(theta)
638
			startInterp = SIN((t - 1) * theta) * invSinTheta
639
			finishInterp = SIN(t * theta) * invSinTheta
640
		else
641
			startInterp = t - 1
642
			finishInterp = t
643
		end
644
	end
645
	return a[1] * startInterp + b[1] * finishInterp, a[2] * startInterp + b[2] * finishInterp, a[3] * startInterp + b[3] * finishInterp, a[4] * startInterp + b[4] * finishInterp
646
end
647
648
function Clerp(a, b, t)
649
	local qa = {QuaternionFromCFrame(a)}
650
	local qb = {QuaternionFromCFrame(b)}
651
	local ax, ay, az = a.x, a.y, a.z
652
	local bx, by, bz = b.x, b.y, b.z
653
	local _t = 1 - t
654
	return QuaternionToCFrame(_t * ax + t * bx, _t * ay + t * by, _t * az + t * bz, QuaternionSlerp(qa, qb, t))
655
end
656
657
function CreateFrame(PARENT, TRANSPARENCY, BORDERSIZEPIXEL, POSITION, SIZE, COLOR, BORDERCOLOR, NAME)
658
	local frame = IT("Frame")
659
	frame.BackgroundTransparency = TRANSPARENCY
660
	frame.BorderSizePixel = BORDERSIZEPIXEL
661
	frame.Position = POSITION
662
	frame.Size = SIZE
663
	frame.BackgroundColor3 = COLOR
664
	frame.BorderColor3 = BORDERCOLOR
665
	frame.Name = NAME
666
	frame.Parent = PARENT
667
	return frame
668
end
669
670
function CreateLabel(PARENT, TEXT, TEXTCOLOR, TEXTFONTSIZE, TEXTFONT, TRANSPARENCY, BORDERSIZEPIXEL, STROKETRANSPARENCY, NAME)
671
	local label = IT("TextLabel")
672
	label.BackgroundTransparency = 1
673
	label.Size = UD2(1, 0, 1, 0)
674
	label.Position = UD2(0, 0, 0, 0)
675
	label.TextColor3 = C3(255, 255, 255)
676
	label.TextStrokeTransparency = STROKETRANSPARENCY
677
	label.TextTransparency = TRANSPARENCY
678
	label.FontSize = TEXTFONTSIZE
679
	label.Font = TEXTFONT
680
	label.BorderSizePixel = BORDERSIZEPIXEL
681
	label.TextScaled = true
682
	label.Text = TEXT
683
	label.Name = NAME
684
	label.Parent = PARENT
685
	return label
686
end
687
688
function NoOutlines(PART)
689
	PART.TopSurface, PART.BottomSurface, PART.LeftSurface, PART.RightSurface, PART.FrontSurface, PART.BackSurface = 10, 10, 10, 10, 10, 10
690
end
691
692
693
function CreateWeldOrSnapOrMotor(TYPE, PARENT, PART0, PART1, C0, C1)
694
	local NEWWELD = IT(TYPE)
695
	NEWWELD.Part0 = PART0
696
	NEWWELD.Part1 = PART1
697
	NEWWELD.C0 = C0
698
	NEWWELD.C1 = C1
699
	NEWWELD.Parent = PARENT
700
	return NEWWELD
701
end
702
703
function CreateSound(ID, PARENT, VOLUME, PITCH, DOESLOOP)
704
	local NEWSOUND = nil
705
	coroutine.resume(coroutine.create(function()
706
		NEWSOUND = IT("Sound", PARENT)
707
		NEWSOUND.Volume = VOLUME
708
		NEWSOUND.Pitch = PITCH
709
		NEWSOUND.SoundId = "http://www.roblox.com/asset/?id="..ID
710
		--Swait()
711
		NEWSOUND:play()
712
		if DOESLOOP == false then
713
			repeat Swait() until NEWSOUND.Playing == false
714
			NEWSOUND:remove()
715
		elseif DOESLOOP == true then
716
			NEWSOUND.Looped = true
717
		end
718
	end))
719
	return NEWSOUND
720
end
721
722
function CFrameFromTopBack(at, top, back)
723
	local right = top:Cross(back)
724
	return CF(at.x, at.y, at.z, right.x, top.x, back.x, right.y, top.y, back.y, right.z, top.z, back.z)
725
end
726
727
function CreateWave(inair,size,doesrotate,rotatedirection,waitt,part,offset,color)
728
	local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(color), "Effect", VT(0,0,0))
729
	local mesh = IT("SpecialMesh",wave)
730
	mesh.MeshType = "FileMesh"
731
	wave.Anchored = true
732
	mesh.MeshId = "http://www.roblox.com/asset/?id=20329976"
733
	mesh.Scale = VT(size,size,size)
734
	mesh.Offset = VT(0,0,-size/8)
735
	wave.CFrame = CF(part.p) * CF(0,offset,0) * ANGLES(RAD(inair),RAD(0),RAD(0))
736
	coroutine.resume(coroutine.create(function(PART)
737
		for i = 1, waitt do
738
			Swait()
739
			mesh.Scale = mesh.Scale + VT(size/5,0,size/5)
740
			mesh.Offset = VT(0,0,-(mesh.Scale.X/8))
741
			if doesrotate == true then
742
				wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(0, rotatedirection, 0)
743
			end
744
			wave.Transparency = wave.Transparency + (0.5/waitt)
745
			if wave.Transparency > 0.99 then
746
				wave:remove()
747
			end
748
		end
749
	end))
750
end
751
752
function CreateSwirl(inair,size,doesrotate,rotatedirection,waitt,part,offset,color)
753
	local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(color), "Effect", VT(0,0,0))
754
	local mesh = IT("SpecialMesh",wave)
755
	mesh.MeshType = "FileMesh"
756
	wave.Anchored = true
757
	mesh.MeshId = "http://www.roblox.com/asset/?id=1051557"
758
	mesh.Scale = VT(size,size,size)
759
	wave.CFrame = CF(part.Position) * CF(0,offset,0) * ANGLES(RAD(inair),RAD(0),RAD(0))
760
	coroutine.resume(coroutine.create(function(PART)
761
		for i = 1, waitt do
762
			Swait()
763
			mesh.Scale = mesh.Scale + VT(size/5,size/5,size/5)
764
			if doesrotate == true then
765
				wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(0, rotatedirection, 0)
766
			end
767
			wave.Transparency = wave.Transparency + (0.5/waitt)
768
			if wave.Transparency > 0.99 then
769
				wave:remove()
770
			end
771
		end
772
	end))
773
end
774
775
function CreateTornado(inair,size,doesrotate,rotatedirection,waitt,part,offset,color)
776
	local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(color), "Effect", VT(0,0,0))
777
	local mesh = IT("SpecialMesh",wave)
778
	mesh.MeshType = "FileMesh"
779
	wave.Anchored = true
780
	mesh.MeshId = "http://www.roblox.com/asset/?id=102638417"
781
	mesh.Scale = VT(size,size,size)
782
	wave.CFrame = CF(part.Position) * CF(0,offset,0) * ANGLES(RAD(inair),RAD(0),RAD(0))
783
	coroutine.resume(coroutine.create(function(PART)
784
		for i = 1, waitt do
785
			Swait()
786
			mesh.Scale = mesh.Scale + VT(size/5,0,size/5)
787
			if doesrotate == true then
788
				wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(0, rotatedirection, 0)
789
			end
790
			wave.Transparency = wave.Transparency + (0.5/waitt)
791
			if wave.Transparency > 0.99 then
792
				wave:remove()
793
			end
794
		end
795
	end))
796
end
797
798
function CreateRing(inair,size,doesrotate,rotatedirection,waitt,part,offset,spin1,spin2,color)
799
	local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(color), "Effect", VT(0,0,0))
800
	local mesh = IT("SpecialMesh",wave)
801
	mesh.MeshType = "FileMesh"
802
	mesh.MeshId = "http://www.roblox.com/asset/?id=3270017"
803
	mesh.Scale = VT(size,size,size)
804
	wave.Anchored = true
805
	mesh.Offset = VT(0,0,0)
806
	wave.CFrame = CF(part.Position) * CF(0,offset,0) * ANGLES(RAD(inair),RAD(0),RAD(0))
807
	coroutine.resume(coroutine.create(function(PART)
808
		for i = 1, waitt do
809
			Swait()
810
			mesh.Scale = mesh.Scale + VT(size/5,size/5,size/5)
811
			if doesrotate == true then
812
				wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(spin2, rotatedirection, spin1)
813
			end
814
			wave.Transparency = wave.Transparency + (0.5/waitt)
815
			if wave.Transparency > 0.99 then
816
				wave:remove()
817
			end
818
		end
819
	end))
820
end
821
822
function MagicSphere(size,waitt,part,color)
823
	local wave = CreatePart(3, Effects, "Neon", 0, 0, BRICKC(color), "Effect", VT(0,0,0))
824
	local mesh = IT("SpecialMesh",wave)
825
	mesh.MeshType = "Sphere"
826
	wave.Anchored = true
827
	mesh.Scale = VT(size,size,size)
828
	mesh.Offset = VT(0,0,0)
829
	wave.CFrame = part * ANGLES(RAD(0),RAD(0),RAD(0))
830
	coroutine.resume(coroutine.create(function(PART)
831
		for i = 1, waitt do
832
			Swait()
833
			mesh.Scale = mesh.Scale + VT(size/5,size/5,size/5)
834
			wave.Transparency = wave.Transparency + (1/waitt)
835
			if wave.Transparency > 0.99 then
836
				wave:remove()
837
			end
838
		end
839
	end))
840
end
841
842
function MagicBlock(size,waitt,part,offset,color)
843
	local wave = CreatePart(3, Effects, "Neon", 0, 0, BRICKC(color), "Effect", VT(size,size,size))
844
	local mesh = IT("BlockMesh",wave)
845
	wave.Anchored = true
846
	wave.CFrame = CF(part.Position) * CF(0,offset,0) * ANGLES(RAD(0),RAD(0),RAD(0))
847
	coroutine.resume(coroutine.create(function(PART)
848
		for i = 1, waitt do
849
			Swait()
850
			mesh.Scale = mesh.Scale + VT(size/5,size/5,size/5)
851
			wave.CFrame = CF(wave.Position) * ANGLES(RAD(math(-360,360)),RAD(math(-360,360)),RAD(math(-360,360)))
852
			wave.Transparency = wave.Transparency + (1/waitt)
853
			if wave.Transparency > 0.99 then
854
				wave:remove()
855
			end
856
		end
857
	end))
858
end
859
860
local EyeSizes={
861
	NumberSequenceKeypoint.new(0,0.5,0),
862
	NumberSequenceKeypoint.new(1,0.2,0)
863
}
864
local EyeTrans={
865
	NumberSequenceKeypoint.new(0,0,0),
866
	NumberSequenceKeypoint.new(1,1,0)
867
}
868
local PE=Instance.new("ParticleEmitter")
869
PE.LightEmission=0.3
870
PE.Size=NumberSequence.new(EyeSizes)
871
PE.Transparency=NumberSequence.new(EyeTrans)
872
PE.Rotation=NumberRange.new(0,360)
873
PE.LockedToPart = false
874
PE.Speed = NumberRange.new(0,0,0)
875
PE.ZOffset = 0.3
876
PE.Rate = 999
877
PE.Name = "Particles"
878
879
function CreateParticles(art,text,accel,drag,lifetime,type,isenabledbydefault,locked)
880
	local particle = nil
881
	coroutine.resume(coroutine.create(function(PART)
882
		particle = PE:Clone()
883
		Swait()
884
		particle.Rate = 999
885
		particle.Parent = art
886
		particle.Acceleration = accel
887
		if type == "Fire" then
888
			local EyeSizes={
889
				NumberSequenceKeypoint.new(0,0.5,0.3),
890
				NumberSequenceKeypoint.new(1,0.2,0.2)
891
			}
892
			particle.Size = NumberSequence.new(EyeSizes)
893
		elseif type == "Smoke" then
894
			local EyeSizes={
895
				NumberSequenceKeypoint.new(0,0.5,0),
896
				NumberSequenceKeypoint.new(1,5,0.5)
897
			}
898
			particle.Size = NumberSequence.new(EyeSizes)
899
		elseif type == "Solid" then
900
			local EyeSizes={
901
				NumberSequenceKeypoint.new(0,0.5,0),
902
				NumberSequenceKeypoint.new(1,0.5,0)
903
			}
904
			particle.Size = NumberSequence.new(EyeSizes)
905
		end
906
		particle.Lifetime=NumberRange.new(lifetime)
907
		particle.Drag = drag
908
		if locked == true then
909
			particle.LockedToPart = true
910
		end
911
		particle.Texture = "http://www.roblox.com/asset/?id="..text
912
		particle.Enabled = isenabledbydefault
913
	end))
914
return particle
915
end
916
917
local EyeSizes={
918
	NumberSequenceKeypoint.new(0,0.5,0),
919
	NumberSequenceKeypoint.new(1,0.2,0)
920
}
921
local EyeTrans={
922
	NumberSequenceKeypoint.new(0,0,0),
923
	NumberSequenceKeypoint.new(1,1,0)
924
}
925
local PE2=Instance.new("ParticleEmitter")
926
PE2.LightEmission=0.8
927
PE2.Size=NumberSequence.new(EyeSizes)
928
PE2.Transparency=NumberSequence.new(EyeTrans)
929
PE2.Rotation=NumberRange.new(0,360)
930
PE2.LockedToPart = false
931
PE2.Speed = NumberRange.new(0,0,0)
932
PE2.ZOffset = 0.3
933
PE2.Rate = 999
934
PE2.VelocitySpread = 90000
935
PE2.Name = "Particles"
936
937
function CreateParticles2(art,accel,drag,lifetime,type,isenabledbydefault,locked,size,speed)
938
	local particle = nil
939
	coroutine.resume(coroutine.create(function(PART)
940
		particle = PE2:Clone()
941
		Swait()
942
		particle.Rate = 999
943
		particle.Parent = art
944
		particle.Acceleration = accel
945
		if type == "Fire" then
946
			local EyeSizes={
947
				NumberSequenceKeypoint.new(0,size,size/2),
948
				NumberSequenceKeypoint.new(1,size/4,size/8)
949
			}
950
			particle.Size = NumberSequence.new(EyeSizes)
951
		elseif type == "Smoke" then
952
			local EyeSizes={
953
				NumberSequenceKeypoint.new(0,0.5,0),
954
				NumberSequenceKeypoint.new(1,5,0.5)
955
			}
956
			particle.Size = NumberSequence.new(EyeSizes)
957
		elseif type == "Solid" then
958
			local EyeSizes={
959
				NumberSequenceKeypoint.new(0,0.5,0),
960
				NumberSequenceKeypoint.new(1,0.5,0)
961
			}
962
			particle.Size = NumberSequence.new(EyeSizes)
963
		end
964
		particle.Lifetime=NumberRange.new(lifetime)
965
		particle.Drag = drag
966
		if locked == true then
967
			particle.LockedToPart = true
968
		end
969
		particle.Speed = NumberRange.new(speed,speed,speed)
970
		particle.Texture = "http://www.roblox.com/asset/?id="..MAGICPARTICLE
971
		particle.Enabled = isenabledbydefault
972
		--particle.Color = ColorSequence.new(Color3.new(0, 0, 255))
973
	end))
974
return particle
975
end
976
977
local Decal = IT("Decal")
978
979
function CreateMagicCircle(size,doesrotate,rotatedirection,waitt,cframe,alwaysfade)
980
	local sinkhole = IT("Part")
981
	sinkhole.Size = VT(size,0,size)
982
	sinkhole.CFrame = cframe
983
	--sinkhole.Orientation = VT(0,0,0)
984
	sinkhole.Parent = Effects
985
	sinkhole.Material = "Neon"
986
	sinkhole.Color = C3(0, 0, 255)
987
	sinkhole.Anchored = true
988
	sinkhole.CanCollide = false
989
	sinkhole.Transparency = 1
990
	local decal = Decal:Clone()
991
	decal.Parent = sinkhole
992
	decal.Face = "Top"
993
	decal.Texture = "http://www.roblox.com/asset/?id=1226241606"
994
	local decal2 = Decal:Clone()
995
	decal2.Parent = sinkhole
996
	decal2.Face = "Bottom"
997
	decal2.Texture = "http://www.roblox.com/asset/?id=1226241606"
998
	coroutine.resume(coroutine.create(function(PART)
999
		for i = 1, waitt do
1000
			Swait()
1001
			if doesrotate == true then
1002
				sinkhole.CFrame = sinkhole.CFrame * CFrame.fromEulerAnglesXYZ(0, rotatedirection, 0)
1003
			end
1004
			if alwaysfade == true then
1005
				decal.Transparency = decal.Transparency + (1/waitt)
1006
				decal2.Transparency = decal.Transparency + (1/waitt)
1007
			end
1008
			if i > waitt-11 and (alwaysfade ~= true) then
1009
				decal.Transparency = decal.Transparency + 0.1
1010
				decal2.Transparency = decal.Transparency + 0.1
1011
			end
1012
		end
1013
		sinkhole.Parent = nil
1014
	end))
1015
	return sinkhole
1016
end
1017
1018
--//=================================\\
1019
--\\=================================//
1020
1021
1022
--//=================================\\
1023
--||	     WEAPON CREATION
1024
--\\=================================//
1025
1026
if Player_Size ~= 1 then
1027
	for _, v in pairs (Weapon:GetChildren()) do
1028
		if v.ClassName == "Motor" or v.ClassName == "Weld" or v.ClassName == "Snap" then
1029
			local p1 = v.Part1
1030
			v.Part1 = nil
1031
			local cf1, cf2, cf3, cf4, cf5, cf6, cf7, cf8, cf9, cf10, cf11, cf12 = v.C1:components()
1032
			v.C1 = CF(cf1 * Player_Size, cf2 * Player_Size, cf3 * Player_Size, cf4, cf5, cf6, cf7, cf8, cf9, cf10, cf11, cf12)
1033
			v.Part1 = p1
1034
		elseif v.ClassName == "Part" then
1035
			for _, b in pairs (v:GetChildren()) do
1036
				if b.ClassName == "SpecialMesh" or b.ClassName == "BlockMesh" then
1037
					b.Scale = VT(b.Scale.x * Player_Size, b.Scale.y * Player_Size, b.Scale.z * Player_Size)
1038
				end
1039
			end
1040
		end
1041
	end
1042
end
1043
1044
Swait()
1045
1046
local Plate = IT("Part",Weapon)
1047
Plate.Size = VT(1,0.1,1)
1048
Plate.Transparency = 1
1049
Plate.CanCollide = false
1050
Plate.CFrame = LeftLeg.CFrame * CF(0,-1.1,0)
1051
CreateParticles(Plate,MAGICPARTICLE,VT(0,2,0),2,2,"Fire",true,true)
1052
weldBetween(LeftLeg,Plate)
1053
1054
local Plate = IT("Part",Weapon)
1055
Plate.Size = VT(1,0.1,1)
1056
Plate.Transparency = 1
1057
Plate.CanCollide = false
1058
Plate.CFrame = RightLeg.CFrame * CF(0,-1.1,0)
1059
CreateParticles(Plate,MAGICPARTICLE,VT(0,2,0),2,2,"Fire",true,true)
1060
weldBetween(RightLeg,Plate)
1061
1062
local Plate = IT("Part",Weapon)
1063
Plate.Size = VT(1,0.1,1)
1064
Plate.Transparency = 1
1065
Plate.CanCollide = false
1066
Plate.CFrame = RightArm.CFrame * CF(0,-1.1,0)
1067
CreateParticles(Plate,MAGICPARTICLE,VT(0,2,0),2,2,"Fire",true,true)
1068
weldBetween(RightArm,Plate)
1069
1070
local Plate = IT("Part",Weapon)
1071
Plate.Size = VT(1,0.1,1)
1072
Plate.Transparency = 1
1073
Plate.CanCollide = false
1074
Plate.CFrame = LeftArm.CFrame * CF(0,-1.1,0)
1075
CreateParticles(Plate,MAGICPARTICLE,VT(0,2,0),2,2,"Fire",true,true)
1076
weldBetween(LeftArm,Plate)
1077
1078
local eye = IT("Part",Weapon)
1079
eye.Size = VT(0.2,0.2,0.2)
1080
eye.Shape = "Ball"
1081
eye.CFrame = Head.CFrame * CF(0.125,0.2,-0.55)
1082
eye.Material = "Neon"
1083
eye.BrickColor = BRICKC("Institutional white")
1084
weldBetween(Head,eye)
1085
1086
1087
1088
for _, c in pairs(Weapon:GetChildren()) do
1089
	if c.ClassName == "Part" then
1090
		c.CustomPhysicalProperties = PhysicalProperties.new(0, 0, 0, 0, 0)
1091
	end
1092
end
1093
1094
Weapon.Parent = Character
1095
1096
Humanoid.Died:connect(function()
1097
	ATTACK = true
1098
end)
1099
1100
print(Class_Name.." loaded.")
1101
1102
--//=================================\\
1103
--\\=================================//
1104
1105
1106
1107
1108
1109
--//=================================\\
1110
--||	     DAMAGE FUNCTIONS
1111
--\\=================================//
1112
1113
function StatLabel(LABELTYPE, CFRAME, TEXT, COLOR)
1114
	local STATPART = CreatePart(3, Effects, "Neon", 0, 1, "Institutional white", "Effect", VT())
1115
	STATPART.CFrame = CF(CFRAME.p + VT(0, 1.5, 0))
1116
	local BODYGYRO = IT("BodyGyro", STATPART)
1117
	local BODYPOSITION = IT("BodyPosition", STATPART)
1118
	BODYPOSITION.P = 2000
1119
	BODYPOSITION.D = 100
1120
	BODYPOSITION.maxForce = VT(math.huge, math.huge, math.huge)
1121
	if LABELTYPE == "Normal" then
1122
		BODYPOSITION.position = STATPART.Position + VT(MRANDOM(-2, 2), 6, MRANDOM(-2, 2))
1123
	elseif LABELTYPE == "Debuff" then
1124
		BODYPOSITION.position = STATPART.Position + VT(MRANDOM(-2, 2), 8, MRANDOM(-2, 2))
1125
	elseif LABELTYPE == "Interruption" then
1126
		BODYPOSITION.position = STATPART.Position + VT(MRANDOM(-2,2), 8, MRANDOM(-2, 2))
1127
	end
1128
	game:GetService("Debris"):AddItem(STATPART ,5)
1129
	local BILLBOARDGUI = Instance.new("BillboardGui", STATPART)
1130
	BILLBOARDGUI.Adornee = STATPART
1131
	BILLBOARDGUI.Size = UD2(2.5, 0, 2.5 ,0)
1132
	BILLBOARDGUI.StudsOffset = VT(-2, 2, 0)
1133
	BILLBOARDGUI.AlwaysOnTop = false
1134
	local TEXTLABEL = Instance.new("TextLabel", BILLBOARDGUI)
1135
	TEXTLABEL.BackgroundTransparency = 1
1136
	TEXTLABEL.Size = UD2(2.5, 0, 2.5, 0)
1137
	TEXTLABEL.Text = TEXT
1138
	TEXTLABEL.Font = "SciFi"
1139
	TEXTLABEL.FontSize="Size42"
1140
	TEXTLABEL.TextColor3 = COLOR
1141
	TEXTLABEL.TextStrokeTransparency = 1
1142
	TEXTLABEL.TextScaled = true
1143
	TEXTLABEL.TextWrapped = true
1144
	coroutine.resume(coroutine.create(function(THEPART, THEBODYPOSITION, THETEXTLABEL)
1145
		wait(0.2)
1146
		for i=1, 5 do
1147
			wait()
1148
			THEBODYPOSITION.Position = THEPART.Position - VT(0, 0.5 ,0)
1149
		end
1150
		wait(1.2)
1151
		for i=1, 5 do
1152
			wait()
1153
			THETEXTLABEL.TextTransparency = THETEXTLABEL.TextTransparency + 0.2
1154
			THETEXTLABEL.TextStrokeTransparency = THETEXTLABEL.TextStrokeTransparency + 0.2
1155
			THEBODYPOSITION.position = THEPART.Position + VT(0, 0.5, 0)
1156
		end
1157
		THEPART.Parent = nil
1158
	end),STATPART, BODYPOSITION, TEXTLABEL)
1159
end
1160
1161
1162
--//=================================\\
1163
--||			DAMAGING
1164
--\\=================================//
1165
1166
function dealdamage(hit,min,max,maxstrength,beserk,critrate,critmultiplier)
1167
	if hit.Parent:FindFirstChildOfClass("Humanoid") and hit.Parent:FindFirstChild("HitBy"..Player.Name) == nil then
1168
		local humanoid = hit.Parent:FindFirstChildOfClass("Humanoid")
1169
		local dmg = math.random(min,max)
1170
		if humanoid.Health > 0 then
1171
			if beserk == true then
1172
				humanoid.Health = 0
1173
			else
1174
				CreateSound("260430060", hit, 1.2, MRANDOM(7, 12) / 10)
1175
				hit.Velocity = CFrame.new(Torso.Position,hit.Position).lookVector*5*maxstrength
1176
				if math.random(1,100) < critrate+1 then
1177
					humanoid.Health = humanoid.Health - dmg*critmultiplier
1178
					StatLabel("Normal", hit.CFrame * CF(0, 0 + (hit.Size.z - 1), 0), "CRIT/"..dmg*critmultiplier, C3(255/255, 0, 0))
1179
				else
1180
					humanoid.Health = humanoid.Health - dmg
1181
					StatLabel("Normal", hit.CFrame * CF(0, 0 + (hit.Size.z - 1), 0), dmg, C3(0, 0, 0))
1182
				end
1183
				local defence = Instance.new("BoolValue",hit.Parent)
1184
				defence.Name = ("HitBy"..Player.Name)
1185
				game:GetService("Debris"):AddItem(defence, 0.5)
1186
			end
1187
		end
1188
	end
1189
end
1190
1191
function AoEDamage(position,radius,min,max,maxstrength,beserk,critrate,critmultiplier,CanBeDodgedByJumping)
1192
	local dmg = math.random(min,max)
1193
	for i,v in ipairs(workspace:GetChildren()) do
1194
	if v:FindFirstChild("HitBy"..Player.Name) == nil then
1195
		local body = v:GetChildren()
1196
			for part = 1, #body do
1197
				if(v:FindFirstChild("HitBy"..Player.Name) == nil and (body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character) then
1198
					if(body[part].Position - position).Magnitude < radius then
1199
						if v.ClassName == "Model" then
1200
							if v:FindFirstChild("Humanoid") then
1201
								if v.Humanoid.Health ~= 0 then
1202
									if CanBeDodgedByJumping == true then
1203
										if body[part].Position.Y < position.Y+5 then
1204
											if math.random(1,100) < critrate+1 then
1205
												v.Humanoid.Health = v.Humanoid.Health - dmg*critmultiplier
1206
												StatLabel("Normal", body[part].CFrame * CF(0, 0 + (body[part].Size.z - 1), 0), "CRIT/"..dmg*critmultiplier, C3(255/255, 0, 0))
1207
											else
1208
												v.Humanoid.Health = v.Humanoid.Health - dmg
1209
												StatLabel("Normal", body[part].CFrame * CF(0, 0 + (body[part].Size.z - 1), 0), dmg, C3(0, 0, 0))
1210
											end
1211
											local defence = Instance.new("BoolValue",v)
1212
											defence.Name = ("HitBy"..Player.Name)
1213
											game:GetService("Debris"):AddItem(defence, 0.5)
1214
										end
1215
									else
1216
										if beserk == true then
1217
											v.Humanoid.Health = 0
1218
										end
1219
										if math.random(1,100) < critrate+1 then
1220
											v.Humanoid.Health = v.Humanoid.Health - dmg*critmultiplier
1221
											StatLabel("Normal", body[part].CFrame * CF(0, 0 + (body[part].Size.z - 1), 0), "CRIT/"..dmg*critmultiplier, C3(255/255, 0, 0))
1222
										else
1223
											v.Humanoid.Health = v.Humanoid.Health - dmg
1224
											StatLabel("Normal", body[part].CFrame * CF(0, 0 + (body[part].Size.z - 1), 0), dmg, C3(0, 0, 0))
1225
										end
1226
										local defence = Instance.new("BoolValue",v)
1227
										defence.Name = ("HitBy"..Player.Name)
1228
										game:GetService("Debris"):AddItem(defence, 0.5)
1229
									end
1230
								end
1231
							end
1232
						end
1233
						body[part].Velocity = CFrame.new(position,body[part].Position).lookVector*5*maxstrength
1234
					end
1235
				end
1236
			end
1237
			if v.ClassName == "Part" then
1238
				if v.Anchored == false and (v.Position - position).Magnitude < radius then
1239
					v.Velocity = CFrame.new(position,v.Position).lookVector*5*maxstrength
1240
				end
1241
			end
1242
		end
1243
	end
1244
end
1245
1246
function attractnearest(postype,position,range,maxstrength,last)
1247
	if postype == "Vector" then
1248
		for i,v in ipairs(workspace:GetChildren()) do
1249
		local body = v:GetChildren()
1250
			for part = 1, #body do
1251
				if((body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character) then
1252
					if(body[part].Position - position).Magnitude < range then
1253
						if body[part]:FindFirstChild("ATTRACT") == nil then
1254
							local bv = Instance.new("BodyVelocity") 
1255
							bv.maxForce = Vector3.new(1e9, 1e9, 1e9)
1256
							bv.velocity = CF(body[part].Position,position).lookVector*maxstrength
1257
							bv.Parent = body[part]
1258
							bv.Name = "ATTRACT"
1259
						else
1260
							coroutine.resume(coroutine.create(function()
1261
								for i = 1, last/5 do
1262
									Swait(5)
1263
									body[part].ATTRACT.velocity = CF(body[part].Position,position).lookVector*maxstrength	
1264
								end		
1265
								body[part].ATTRACT:remove()				
1266
							end))
1267
						end
1268
					end
1269
				end
1270
			end
1271
			if v.ClassName == "Part" then
1272
				if v.Anchored == false and (v.Position - position).Magnitude < range then
1273
					if v:FindFirstChild("ATTRACT") == nil then
1274
						local bv = Instance.new("BodyVelocity") 
1275
						bv.maxForce = Vector3.new(1e9, 1e9, 1e9)
1276
						bv.velocity = CF(v.Position,position).lookVector*maxstrength
1277
						bv.Parent = v
1278
						bv.Name = "ATTRACT"
1279
					else
1280
						coroutine.resume(coroutine.create(function()
1281
							for i = 1, last/5 do
1282
								Swait(5)
1283
								v.ATTRACT.velocity = CF(v.Position,position).lookVector*maxstrength	
1284
							end		
1285
							v.ATTRACT:remove()				
1286
						end))
1287
					end
1288
				end
1289
			end
1290
		end
1291
	elseif postype == "Part" then
1292
		for i,v in ipairs(workspace:GetChildren()) do
1293
		local body = v:GetChildren()
1294
			for part = 1, #body do
1295
				if((body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character) then
1296
					if(body[part].Position - position.Position).Magnitude < range then
1297
						if body[part]:FindFirstChild("ATTRACT") == nil then
1298
							local bv = Instance.new("BodyVelocity") 
1299
							bv.maxForce = Vector3.new(1e9, 1e9, 1e9)
1300
							bv.velocity = CF(body[part].Position,position.Position).lookVector*maxstrength
1301
							bv.Parent = body[part]
1302
							bv.Name = "ATTRACT"
1303
						else
1304
							coroutine.resume(coroutine.create(function()
1305
								for i = 1, last/5 do
1306
									Swait(5)
1307
									body[part].ATTRACT.velocity = CF(body[part].Position,position.Position).lookVector*maxstrength	
1308
								end		
1309
								body[part].ATTRACT:remove()				
1310
							end))
1311
						end
1312
					end
1313
				end
1314
			end
1315
			if v.ClassName == "Part" then
1316
				if v.Anchored == false and (v.Position - position.Position).Magnitude < range then
1317
					if v:FindFirstChild("ATTRACT") == nil then
1318
						local bv = Instance.new("BodyVelocity") 
1319
						bv.maxForce = Vector3.new(1e9, 1e9, 1e9)
1320
						bv.velocity = CF(v.Position,position.Position).lookVector*maxstrength
1321
						bv.Parent = v
1322
						bv.Name = "ATTRACT"
1323
					else
1324
						coroutine.resume(coroutine.create(function()
1325
							for i = 1, last/5 do
1326
								Swait(5)
1327
								v.ATTRACT.velocity = CF(v.Position,position.Position).lookVector*maxstrength	
1328
							end		
1329
							v.ATTRACT:remove()				
1330
						end))
1331
					end
1332
				end
1333
			end
1334
		end
1335
	end
1336
end
1337
1338
function killnearest(position,range,maxstrength,candestroy)
1339
	for i,v in ipairs(workspace:GetChildren()) do
1340
	local body = v:GetChildren()
1341
		for part = 1, #body do
1342
			if((body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character) then
1343
				if(body[part].Position - position).Magnitude < range then
1344
					if v.ClassName == "Model" then
1345
						v:BreakJoints()
1346
					end
1347
					if candestroy == true then
1348
						table.insert(Effects2,{body[part],"Disappear",0.02,2,2,2,2})
1349
					end
1350
					body[part].Velocity = CFrame.new(position,body[part].Position).lookVector*5*maxstrength
1351
				end
1352
			end
1353
		end
1354
		if v.ClassName == "Part" then
1355
			if v.Anchored == false and (v.Position - position).Magnitude < range then
1356
				if candestroy == true then
1357
					table.insert(Effects2,{v,"Disappear",0.02,2,2,2,2})
1358
				end
1359
				v.Velocity = CFrame.new(position,v.Position).lookVector*5*maxstrength
1360
			end
1361
		end
1362
	end
1363
end
1364
1365
--//=================================\\
1366
--||	ATTACK FUNCTIONS AND STUFF
1367
--\\=================================//
1368
1369
function CheckTableForString(Table, String)
1370
	for i, v in pairs(Table) do
1371
		if string.find(string.lower(String), string.lower(v)) then
1372
			return true
1373
		end
1374
	end
1375
	return false
1376
end
1377
1378
function CheckIntangible(Hit)
1379
	local ProjectileNames = {"Water", "Arrow", "Projectile", "Effect", "Rail", "Lightning", "Bullet"}
1380
	if Hit and Hit.Parent then
1381
		if ((not Hit.CanCollide or CheckTableForString(ProjectileNames, Hit.Name)) and not Hit.Parent:FindFirstChild("Humanoid")) then
1382
			return true
1383
		end
1384
	end
1385
	return false
1386
end
1387
1388
Debris = game:GetService("Debris")
1389
1390
function CastZapRay(StartPos, Vec, Length, Ignore, DelayIfHit)
1391
	local Direction = CFrame.new(StartPos, Vec).lookVector
1392
	local Ignore = ((type(Ignore) == "table" and Ignore) or {Ignore})
1393
	local RayHit, RayPos, RayNormal = game:GetService("Workspace"):FindPartOnRayWithIgnoreList(Ray.new(StartPos, Direction * Length), Ignore)
1394
	if RayHit and CheckIntangible(RayHit) then
1395
		if DelayIfHit then
1396
			wait()
1397
		end
1398
		RayHit, RayPos, RayNormal = CastZapRay((RayPos + (Vec * 0.01)), Vec, (Length - ((StartPos - RayPos).magnitude)), Ignore, DelayIfHit)
1399
	end
1400
	return RayHit, RayPos, RayNormal
1401
end
1402
1403
function turnto(pos)
1404
	RootPart.CFrame = CF(RootPart.Position,VT(pos.X,RootPart.Position.Y,pos.Z))
1405
end
1406
1407
function GraviBomb()
1408
	ATTACK = true
1409
	for i=0, 1, 0.1 / Animation_Speed do
1410
		Swait()
1411
		RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0 * Player_Size, 0 * Player_Size, 0.7 * Player_Size) * ANGLES(RAD(5), RAD(0), RAD(-40)), 0.4 / Animation_Speed)
1412
		Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(0), RAD(0), RAD(35)) * ANGLES(RAD(2.5), RAD(0), RAD(0)), 0.4 / Animation_Speed)
1413
		RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(70), RAD(0), RAD(45)) * RIGHTSHOULDERC0, 0.4 / Animation_Speed)
1414
		LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.75 * Player_Size, -0.5 * Player_Size) * ANGLES(RAD(90), RAD(0), RAD(50)) * ANGLES(RAD(80), RAD(-20), RAD(-30)) * LEFTSHOULDERC0, 0.4 / Animation_Speed)
1415
		RightHip.C0 = Clerp(RightHip.C0, CF(1 * Player_Size, -0.3 * Player_Size, -1 * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(-20)), 0.2 / Animation_Speed)
1416
		LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -1 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(10)), 0.2 / Animation_Speed)
1417
	end
1418
	MagicSphere(25,25,LeftArm.CFrame*CF(0,-1,0),"Institutional white")
1419
	MagicSphere(20,25,LeftArm.CFrame*CF(0,-1,0),"Institutional white")
1420
	coroutine.resume(coroutine.create(function()
1421
		local cframe = CF(Mouse.Hit.p)
1422
		local circle = CreateMagicCircle(75,true,0.05,120,cframe,false)
1423
		for i = 1, 5 do
1424
			CreateSound(CUTSOUNDS[MRANDOM(1, #CUTSOUNDS)], Effects, 2, 1)
1425
			local sphere = IT("Part",Effects)
1426
			sphere.Shape = "Ball"
1427
			sphere.Size = VT(50,50,50)
1428
			sphere.Anchored = true
1429
			sphere.CanCollide = false
1430
			sphere.Material = "Neon"
1431
			sphere.BrickColor = BRICKC("Toothpaste")
1432
			sphere.Transparency = 0
1433
			sphere.CFrame = cframe
1434
			for i = 1, 10 do
1435
				Swait(2)
1436
				attractnearest("Vector",cframe.p,75,50,10)
1437
				sphere.CFrame = cframe
1438
				sphere.Size = sphere.Size - VT(5,5,5)
1439
				sphere.CFrame = cframe
1440
			end
1441
			sphere:remove()
1442
		end
1443
		local scale = 5
1444
		coroutine.resume(coroutine.create(function()
1445
			CreateSound(RELEASESOUND, Effects, 2, 1)
1446
			MagicSphere(100,125,cframe,"Institutional white")
1447
			MagicSphere(75,125,cframe,"Institutional white")
1448
			CreateSwirl(180,6,true,0.3,225,circle,0,"Institutional white")
1449
			CreateSwirl(180,4,true,0.3,225,circle,0,"Institutional white")
1450
			CreateSwirl(180,2,true,0.3,225,circle,0,"Institutional white")
1451
			for i = 1, 15 do
1452
				Swait()
1453
				killnearest(cframe.p,25,150)
1454
			end
1455
		end))
1456
	end))
1457
	for i=0, 1, 0.1 / Animation_Speed do
1458
		Swait()
1459
		RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0 * Player_Size, 0 * Player_Size, 0.7 * Player_Size) * ANGLES(RAD(5), RAD(0), RAD(-30)), 0.4 / Animation_Speed)
1460
		Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(0), RAD(0), RAD(25)) * ANGLES(RAD(5), RAD(0), RAD(0)), 0.4 / Animation_Speed)
1461
		RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(70), RAD(0), RAD(45)) * RIGHTSHOULDERC0, 0.4 / Animation_Speed)
1462
		LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.25 * Player_Size, -0.25 * Player_Size) * ANGLES(RAD(90), RAD(0), RAD(-20 + MRANDOM(-2.5, 2.5))) * ANGLES(RAD(70 + MRANDOM(-2.5, 2.5)), RAD(40), RAD(0)) * LEFTSHOULDERC0, 0.4 / Animation_Speed)
1463
		RightHip.C0 = Clerp(RightHip.C0, CF(1 * Player_Size, -0.3 * Player_Size, -1 * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(-20)), 0.2 / Animation_Speed)
1464
		LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -1 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(10)), 0.2 / Animation_Speed)
1465
	end
1466
	ATTACK = false
1467
end
1468
1469
function GraviSpear()
1470
	ATTACK = true
1471
	for i=0, 1.5, 0.1 / Animation_Speed do
1472
		Swait()
1473
		turnto(Mouse.Hit.p)
1474
		RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0 * Player_Size, 0 * Player_Size, 0.7 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(75)), 0.4 / Animation_Speed)
1475
		Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(0), RAD(0), RAD(-75)), 0.2 / Animation_Speed)
1476
		RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(90)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed)
1477
		LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(25), RAD(-25)) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
1478
		RightHip.C0 = Clerp(RightHip.C0, CF(1 * Player_Size, -0.3 * Player_Size, -1 * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(-20)), 0.2 / Animation_Speed)
1479
		LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -1 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(10)), 0.2 / Animation_Speed)
1480
	end
1481
	local spear = IT("Part",Effects)
1482
	spear.Anchored = true
1483
	spear.CanCollide = false
1484
	spear.Shape = "Ball"
1485
	spear.Size = VT(0,0,0)
1486
	spear.Material = "Neon"
1487
	spear.Transparency = 0.2
1488
	spear.BrickColor = BRICKC("Toothpaste")
1489
	spear.CFrame = RightArm.CFrame * CF(0,-4,0)
1490
	local inner = spear:Clone()
1491
	inner.Parent = spear
1492
	inner.Size = VT(0,0,0)
1493
	inner.BrickColor = BRICKC("Toothpaste")
1494
	inner.CFrame = spear.CFrame
1495
	for i = 1, 10 do
1496
		Swait()
1497
		turnto(Mouse.Hit.p)
1498
		spear.CFrame = RightArm.CFrame * CF(0,-4,0)
1499
		inner.CFrame = spear.CFrame
1500
		spear.Size = spear.Size + VT(0.4,0.4,0.4)
1501
		inner.Size = inner.Size + VT(0.35,0.35,0.35)
1502
	end
1503
	CreateParticles2(inner,VT(0,0,0),5,1,"Smoke",true,true,1,8)
1504
	MagicSphere(25,25,RightArm.CFrame*CF(0,-1,0),"Institutional white")
1505
	MagicSphere(20,25,RightArm.CFrame*CF(0,-1,0),"Institutional white")
1506
	CreateSound(CUTSOUNDS[MRANDOM(1, #CUTSOUNDS)], RightArm, 6, 1)
1507
	local bv = Instance.new("BodyVelocity") 
1508
	bv.maxForce = Vector3.new(1e9, 1e9, 1e9)
1509
	bv.velocity = CF(spear.Position,Mouse.Hit.p).lookVector*65
1510
	bv.Parent = spear
1511
	bv.Name = "MOVE"
1512
	weldBetween(spear,inner)
1513
	spear.Anchored = false
1514
	inner.Anchored = false
1515
	local harm = spear.Touched:Connect(function(hit)
1516
		if hit.Parent ~= Character and hit.Parent ~= Weapon and hit.Parent ~= Effects then
1517
			local cframe = spear.CFrame
1518
			coroutine.resume(coroutine.create(function()
1519
				spear.Parent = nil
1520
				coroutine.resume(coroutine.create(function()
1521
					CreateSound(RELEASESOUND, Effects, 2, 1)
1522
					MagicSphere(60,125,cframe,"Institutional white")
1523
					MagicSphere(50,125,cframe,"Institutional white")
1524
					CreateSwirl(0,6,true,0.3,125,spear,0,"Institutional white")
1525
					CreateSwirl(0,4,true,0.3,125,spear,0,"Institutional white")
1526
					CreateSwirl(0,2,true,0.3,125,spear,0,"Institutional white")
1527
					for i = 1, 15 do
1528
						Swait()
1529
						killnearest(cframe.p,15,150)
1530
					end
1531
				end))
1532
			end))
1533
		end
1534
	end)
1535
	coroutine.resume(coroutine.create(function()
1536
		repeat
1537
			Swait()
1538
			CreateSwirl(0,2,true,0.3,25,spear,0,"Institutional white")
1539
			attractnearest("Part",spear,65,70,5)
1540
		until spear.Parent == nil
1541
	end))
1542
	ATTACK = false
1543
end
1544
1545
function WarpSpear()
1546
	ATTACK = true
1547
	for i=0, 1.5, 0.1 / Animation_Speed do
1548
		Swait()
1549
		turnto(Mouse.Hit.p)
1550
		RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0 * Player_Size, 0 * Player_Size, 0.7 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(75)), 0.4 / Animation_Speed)
1551
		Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(0), RAD(0), RAD(-75)), 0.2 / Animation_Speed)
1552
		RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(90)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed)
1553
		LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(25), RAD(-25)) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
1554
		RightHip.C0 = Clerp(RightHip.C0, CF(1 * Player_Size, -0.3 * Player_Size, -1 * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(-20)), 0.2 / Animation_Speed)
1555
		LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -1 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(10)), 0.2 / Animation_Speed)
1556
	end
1557
	local spear = IT("Part",Effects)
1558
	spear.Anchored = true
1559
	spear.CanCollide = false
1560
	spear.Shape = "Ball"
1561
	spear.Size = VT(0,0,0)
1562
	spear.Material = "Neon"
1563
	spear.Transparency = 0.2
1564
	spear.BrickColor = BRICKC("Toothpaste")
1565
	spear.CFrame = RightArm.CFrame * CF(0,-4,0)
1566
	local inner = spear:Clone()
1567
	inner.Parent = spear
1568
	inner.Size = VT(0,0,0)
1569
	inner.BrickColor = BRICKC("Toothpaste")
1570
	inner.CFrame = spear.CFrame
1571
	for i = 1, 5 do
1572
		Swait()
1573
		turnto(Mouse.Hit.p)
1574
		spear.CFrame = RightArm.CFrame * CF(0,-4,0)
1575
		inner.CFrame = spear.CFrame
1576
		spear.Size = spear.Size + VT(0.4,0.4,0.4)
1577
		inner.Size = inner.Size + VT(0.35,0.35,0.35)
1578
	end
1579
	MagicSphere(25,25,RightArm.CFrame*CF(0,-1,0),"Institutional white")
1580
	MagicSphere(20,25,RightArm.CFrame*CF(0,-1,0),"Institutional white")
1581
	CreateSound(CUTSOUNDS[MRANDOM(1, #CUTSOUNDS)], RightArm, 6, 1)
1582
	local bv = Instance.new("BodyVelocity") 
1583
	bv.maxForce = Vector3.new(1e9, 1e9, 1e9)
1584
	bv.velocity = CF(spear.Position,Mouse.Hit.p).lookVector*100
1585
	bv.Parent = spear
1586
	bv.Name = "MOVE"
1587
	weldBetween(spear,inner)
1588
	spear.Anchored = false
1589
	inner.Anchored = false
1590
	local HIT = false
1591
	local harm = spear.Touched:Connect(function(hit)
1592
		if HIT == false and hit.Parent ~= Character and hit.Parent ~= Weapon and hit.Parent ~= Effects then
1593
			local cframe = spear.CFrame
1594
			HIT = true
1595
			coroutine.resume(coroutine.create(function()
1596
				spear.Parent = nil
1597
				RootPart.CFrame = CF(spear.Position,Mouse.Hit.p)
1598
				coroutine.resume(coroutine.create(function()
1599
					CreateSound(RELEASESOUND, Effects, 2, 1.5)
1600
					MagicSphere(30,105,cframe,"Institutional white")
1601
					MagicSphere(25,105,cframe,"Institutional white")
1602
					for i = 1, 15 do
1603
						Swait()
1604
						killnearest(cframe.p,7.5,150)
1605
					end
1606
				end))
1607
			end))
1608
		end
1609
	end)
1610
	coroutine.resume(coroutine.create(function()
1611
		Swait(75)
1612
		if HIT == false then
1613
			local cframe = spear.CFrame
1614
			HIT = true
1615
			coroutine.resume(coroutine.create(function()
1616
				spear.Parent = nil
1617
				RootPart.CFrame = CF(spear.Position,Mouse.Hit.p)
1618
				coroutine.resume(coroutine.create(function()
1619
					CreateSound(RELEASESOUND, Effects, 2, 1.5)
1620
					MagicSphere(30,105,cframe,"Institutional white")
1621
					MagicSphere(25,105,cframe,"Institutional white")
1622
					for i = 1, 15 do
1623
						Swait()
1624
						killnearest(cframe.p,7.5,150)
1625
					end
1626
				end))
1627
			end))
1628
		end
1629
	end))
1630
	coroutine.resume(coroutine.create(function()
1631
		local loop = 0
1632
		repeat
1633
			Swait()
1634
			loop = loop + 1
1635
			if loop == 4 then
1636
				MagicSphere(25,15,spear.CFrame,"Institutional white")
1637
			end
1638
			if loop == 7 then
1639
				loop = 0
1640
				MagicSphere(25,15,spear.CFrame,"Institutional white")
1641
			end
1642
			attractnearest("Part",spear,12.5,50,5)
1643
		until spear.Parent == nil
1644
	end))
1645
	ATTACK = false
1646
end
1647
1648
function GravityGlobe()
1649
	ATTACK = true
1650
	Rooted = true
1651
	for i=0, 1, 0.1 / Animation_Speed do
1652
		Swait()
1653
		RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0 * Player_Size, 0 * Player_Size, 0.7 * Player_Size) * ANGLES(RAD(5), RAD(0), RAD(-40)), 0.4 / Animation_Speed)
1654
		Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(0), RAD(0), RAD(35)) * ANGLES(RAD(2.5), RAD(0), RAD(0)), 0.4 / Animation_Speed)
1655
		RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(70), RAD(0), RAD(45)) * RIGHTSHOULDERC0, 0.4 / Animation_Speed)
1656
		LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.75 * Player_Size, -0.5 * Player_Size) * ANGLES(RAD(90), RAD(0), RAD(50)) * ANGLES(RAD(80), RAD(-20), RAD(-30)) * LEFTSHOULDERC0, 0.4 / Animation_Speed)
1657
		RightHip.C0 = Clerp(RightHip.C0, CF(1 * Player_Size, -0.3 * Player_Size, -1 * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(-20)), 0.2 / Animation_Speed)
1658
		LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -1 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(10)), 0.2 / Animation_Speed)
1659
	end
1660
	coroutine.resume(coroutine.create(function()
1661
		CreateMagicCircle(100,true,0.02,50,CF(RootPart.Position) * CF(0,-2.8,0),true)
1662
		local cframe = RootPart.CFrame
1663
		CreateSound(RELEASESOUND, Effects, 2, 1)
1664
		local sphere = IT("Part",Effects)
1665
		sphere.Shape = "Ball"
1666
		sphere.Size = VT(0,0,0)
1667
		sphere.Anchored = true
1668
		sphere.CanCollide = false
1669
		sphere.Material = "Neon"
1670
		sphere.Transparency = 0.5
1671
		sphere.BrickColor = BRICKC("Toothpaste")
1672
		sphere.CFrame = cframe
1673
		local sphere2 = IT("Part",Effects)
1674
		sphere2.Shape = "Ball"
1675
		sphere2.Size = VT(0,0,0)
1676
		sphere2.Anchored = true
1677
		sphere2.CanCollide = false
1678
		sphere2.Material = "Neon"
1679
		sphere2.Transparency = 0.3
1680
		sphere2.BrickColor = BRICKC("Toothpaste")
1681
		sphere2.CFrame = cframe
1682
		for i = 1, 10 do
1683
			Swait(2)
1684
			attractnearest("Vector",cframe.p,50,50,10)
1685
			sphere.CFrame = cframe
1686
			sphere.Size = sphere.Size + VT(4,4,4)
1687
			sphere2.CFrame = cframe
1688
			sphere2.Size = sphere2.Size + VT(3.5,3.5,3.5)
1689
			killnearest(cframe.p,15,0)
1690
		end
1691
		local scale = 0.2
1692
		local mode = "shrink"
1693
		for i = 1, 350 do
1694
			Swait()
1695
			if mode == "shrink" then
1696
				scale = scale + scale
1697
				if scale >= - 65 then
1698
					mode = "grow"
1699
				end
1700
			elseif mode == "grow" then
1701
				scale = scale + -scale*2
1702
				if scale <= - 65 then
1703
					mode = "shrink"
1704
				end
1705
			end
1706
			CreateRing(180,5,true,0,50,sphere,0,scale,scale,"Institutional white")
1707
			sphere.Size = sphere.Size + VT(scale,scale,scale)
1708
			attractnearest("Vector",cframe.p,50,50,5)
1709
			killnearest(cframe.p,15,0)
1710
		end
1711
		for i = 1, 10 do
1712
			Swait(2)
1713
			sphere.CFrame = cframe
1714
			sphere.Size = sphere.Size - VT(5,5,5)
1715
			sphere.CFrame = cframe
1716
			sphere2.CFrame = cframe
1717
			sphere2.Size = sphere2.Size - VT(3.5,3.5,3.5)
1718
		end
1719
		sphere:remove()
1720
		sphere2:remove()
1721
	end))
1722
	for i=0, 1, 0.1 / Animation_Speed do
1723
		Swait()
1724
		RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0 * Player_Size, 0 * Player_Size, 0.7 * Player_Size) * ANGLES(RAD(5), RAD(0), RAD(-30)), 0.4 / Animation_Speed)
1725
		Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(0), RAD(0), RAD(25)) * ANGLES(RAD(5), RAD(0), RAD(0)), 0.4 / Animation_Speed)
1726
		RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(70), RAD(0), RAD(45)) * RIGHTSHOULDERC0, 0.4 / Animation_Speed)
1727
		LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.25 * Player_Size, -0.25 * Player_Size) * ANGLES(RAD(90), RAD(0), RAD(-20 + MRANDOM(-2.5, 2.5))) * ANGLES(RAD(70 + MRANDOM(-2.5, 2.5)), RAD(40), RAD(0)) * LEFTSHOULDERC0, 0.4 / Animation_Speed)
1728
		RightHip.C0 = Clerp(RightHip.C0, CF(1 * Player_Size, -0.3 * Player_Size, -1 * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(-20)), 0.2 / Animation_Speed)
1729
		LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -1 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(10)), 0.2 / Animation_Speed)
1730
	end
1731
	Rooted = false
1732
	ATTACK = false
1733
end
1734
1735
function GravityBeam()
1736
	ATTACK = true
1737
	Rooted = true
1738
	for i=0, 1.5, 0.1 / Animation_Speed do
1739
		Swait()
1740
		turnto(Mouse.Hit.p)
1741
		RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0 * Player_Size, 0 * Player_Size, 0.7 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(75)), 0.4 / Animation_Speed)
1742
		Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(0), RAD(0), RAD(-75)), 0.2 / Animation_Speed)
1743
		RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(90)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed)
1744
		LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(25), RAD(-25)) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
1745
		RightHip.C0 = Clerp(RightHip.C0, CF(1 * Player_Size, -0.3 * Player_Size, -1 * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(-20)), 0.2 / Animation_Speed)
1746
		LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -1 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(10)), 0.2 / Animation_Speed)
1747
	end
1748
	local startpos = RightArm.CFrame*CF(0,-1.5,0).p
1749
	local loop = 0
1750
	local loopsound = CreateSound(CHARGESOUND, RightArm, 10, 1, true)
1751
	local loopsound2 = CreateSound("487214658", Effects, 1, 0, true)
1752
	local pos = nil
1753
	repeat
1754
		if loop < 150 then
1755
			Swait()
1756
			loop = loop + 1
1757
			turnto(Mouse.Hit.p)
1758
			MagicSphere(15,25,RightArm.CFrame*CF(0,-1,0),"Institutional white")
1759
			MagicSphere(12,25,RightArm.CFrame*CF(0,-1,0),"Institutional white")
1760
		else
1761
			loopsound2.Pitch = 1
1762
			loopsound:Stop()
1763
			startpos = RightArm.CFrame*CF(0,-1.5,0).p
1764
			turnto(Mouse.Hit.p)
1765
			MagicSphere(35,25,CF(startpos),"Institutional white")
1766
			MagicSphere(32,25,CF(startpos),"Institutional white")
1767
			local RayHit, RayPos, RayNormal = CastZapRay(startpos, Mouse.Hit.p, 150, Character, false)
1768
			local distance = (startpos - RayPos).magnitude
1769
			local laser = Instance.new("Part",Effects)
1770
			laser.Transparency = 0.5
1771
			laser.CanCollide = false
1772
			laser.Anchored = true
1773
			laser.BrickColor = BrickColor.new("Toothpaste")
1774
       	 	laser.Material = "Neon" 
1775
			laser.formFactor    = Enum.FormFactor.Custom
1776
			laser.Size          = Vector3.new(2.5, 2.5, distance)
1777
			laser.CFrame        = CFrame.new(startpos, RayPos) * CFrame.new(0, 0, -distance/2)
1778
			local laser2 = Instance.new("Part",Effects)
1779
			laser2.Transparency = 0
1780
			laser2.CanCollide = false
1781
			laser2.Anchored = true
1782
			laser2.BrickColor = BrickColor.new("Toothpaste")
1783
       	 	laser2.Material = "Neon" 
1784
			laser2.formFactor    = Enum.FormFactor.Custom
1785
			laser2.Size          = Vector3.new(2, 2, distance)
1786
			laser2.CFrame        = CFrame.new(startpos, RayPos) * CFrame.new(0, 0, -distance/2)
1787
			killnearest(RayPos,5,150,true)
1788
			MagicSphere(350,2,CF(RayPos),"Toothpaste")
1789
			MagicSphere(320,2,CF(RayPos),"Toothpastee")
1790
			if RayHit ~= nil then
1791
				CreateWave(0,5,false,0,25,CF(RayPos),0,"Toothpaste")
1792
			end
1793
			attractnearest("Vector",RayPos,40,50,10)
1794
			pos = RayPos
1795
			Swait()
1796
			laser2:remove()
1797
			laser:remove()
1798
		end
1799
	until KEYHOLD == false
1800
	if loop == 150 then
1801
		local cframe = CF(pos)
1802
		coroutine.resume(coroutine.create(function()
1803
			coroutine.resume(coroutine.create(function()
1804
				CreateSound(RELEASESOUND, Effects, 2, 1)
1805
				MagicSphere(500,55,cframe,"Institutional white")
1806
				MagicSphere(450,55,cframe,"Institutional white")
1807
				for i = 1, 15 do
1808
					Swait()
1809
					killnearest(cframe.p,75,150)
1810
				end
1811
			end))
1812
		end))
1813
	end
1814
	loopsound2:remove()
1815
	loopsound:remove()
1816
	Rooted = false
1817
	ATTACK = false
1818
end
1819
1820
--//=================================\\
1821
--||	  ASSIGN THINGS TO KEYS
1822
--\\=================================//
1823
1824
Humanoid.Changed:connect(function(Jump)
1825
	if Jump == "Jump" and (Disable_Jump == true or DISABLEJUMPING == true) then
1826
		Humanoid.Jump = false
1827
	end
1828
end)
1829
1830
function MouseDown(Mouse)
1831
	if ATTACK == false then
1832
	end
1833
end
1834
1835
function MouseUp(Mouse)
1836
HOLD = false
1837
end
1838
1839
function KeyDown(Key)
1840
	KEYHOLD = true
1841
	if Key == "q" and ATTACK == false then
1842
		GraviBomb()
1843
	end
1844
1845
	if Key == "e" and ATTACK == false then
1846
		GraviSpear()
1847
	end
1848
1849
	if Key == "r" and ATTACK == false then
1850
		GravityGlobe()
1851
	end
1852
1853
	if Key == "g" and ATTACK == false then
1854
		GravityBeam()
1855
	end
1856
1857
	if Key == "x" and ATTACK == false then
1858
	end
1859
1860
	if Key == "c" and ATTACK == false then
1861
		WarpSpear()
1862
	end
1863
1864
	if Key == "t" and ATTACK == false then
1865
		CreateSound("305685800", Head, 10, 1 ,false)
1866
	end
1867
end
1868
1869
function KeyUp(Key)
1870
	KEYHOLD = false
1871
end
1872
--this part always causes scripting issues
1873-
local Mouse = Player:GetMouse()
1873+
1874
		MouseDown(NEWKEY)
1875
	end)
1876
	Mouse.Button1Up:connect(function(NEWKEY)
1877
		MouseUp(NEWKEY)
1878
	end)
1879
	Mouse.KeyDown:connect(function(NEWKEY)
1880
		KeyDown(NEWKEY)
1881
	end)
1882
	Mouse.KeyUp:connect(function(NEWKEY)
1883
		KeyUp(NEWKEY)
1884
	end)
1885
1886
--//=================================\\
1887
--\\=================================//
1888
1889
1890
function unanchor()
1891
	if UNANCHOR == true then
1892
		g = Character:GetChildren()
1893
		for i = 1, #g do
1894
			if g[i].ClassName == "Part" then
1895
				g[i].Anchored = false
1896
			end
1897
		end
1898
	end
1899
end
1900
1901
1902
--//=================================\\
1903
--||	WRAP THE WHOLE SCRIPT UP
1904
--\\=================================//
1905
1906
Humanoid.Changed:connect(function(Jump)
1907
	if Jump == "Jump" and (Disable_Jump == true or DISABLEJUMPING == true) then
1908
		Humanoid.Jump = false
1909
	end
1910
end)
1911
1912
		ANIMATE.Parent = nil
1913
		local IDLEANIMATION = Humanoid:LoadAnimation(ROBLOXIDLEANIMATION)
1914
		IDLEANIMATION:Play()
1915
1916
while true do
1917
	Swait()
1918
	SINE = SINE + CHANGE
1919
	local TORSOVELOCITY = (RootPart.Velocity * VT(1, 0, 1)).magnitude
1920
	local TORSOVERTICALVELOCITY = RootPart.Velocity.y
1921
	local LV = Torso.CFrame:pointToObjectSpace(Torso.Velocity - Torso.Position)
1922
	local HITFLOOR = Raycast(RootPart.Position, (CF(RootPart.Position, RootPart.Position + VT(0, -1, 0))).lookVector, 4 * Player_Size, Character)
1923
	local WALKSPEEDVALUE = 6 / (Humanoid.WalkSpeed / 16)
1924
		if ANIM == "Walk" and TORSOVELOCITY > 1 then
1925
			RootJoint.C1 = Clerp(RootJoint.C1, ROOTC0 * CF(0, 0, -0.1 * COS(SINE / (WALKSPEEDVALUE / 2)) * Player_Size) * ANGLES(RAD(0), RAD(0) - RootPart.RotVelocity.Y / 75, RAD(0)), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
1926
			Neck.C1 = Clerp(Neck.C1, CF(0 * Player_Size, -0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(-90), RAD(0), RAD(180)) * ANGLES(RAD(2.5 * SIN(SINE / (WALKSPEEDVALUE / 2))), RAD(0), RAD(0) - Head.RotVelocity.Y / 30), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
1927
			--RightHip.C1 = Clerp(RightHip.C1, CF(0.5 * Player_Size, 0.875 * Player_Size - 0.125 * SIN(SINE / WALKSPEEDVALUE) * Player_Size, -0.125 * COS(SINE / WALKSPEEDVALUE) * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0) - RightLeg.RotVelocity.Y / 75, RAD(0), RAD(60 * COS(SINE / WALKSPEEDVALUE))), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
1928
			--LeftHip.C1 = Clerp(LeftHip.C1, CF(-0.5 * Player_Size, 0.875 * Player_Size + 0.125 * SIN(SINE / WALKSPEEDVALUE) * Player_Size, 0.125 * COS(SINE / WALKSPEEDVALUE) * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0) + LeftLeg.RotVelocity.Y / 75, RAD(0), RAD(60 * COS(SINE / WALKSPEEDVALUE))), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
1929
		elseif (ANIM ~= "Walk") or (TORSOVELOCITY < 1) then
1930
			RootJoint.C1 = Clerp(RootJoint.C1, ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed)
1931
			Neck.C1 = Clerp(Neck.C1, CF(0 * Player_Size, -0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(-90), RAD(0), RAD(180)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed)
1932
			--RightHip.C1 = Clerp(RightHip.C1, CF(0.5 * Player_Size, 1 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed)
1933
			----LeftHip.C1 = Clerp(LeftHip.C1, CF(-0.5 * Player_Size, 1 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed)
1934
		end
1935
		if TORSOVERTICALVELOCITY > 1 and HITFLOOR == nil then
1936
			ANIM = "Jump"
1937
			if ATTACK == false then
1938
				RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0 * Player_Size, 0 * Player_Size, 0.7 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed)
1939
				Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(-20), RAD(0), RAD(0)), 0.2 / Animation_Speed)
1940
				RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(-40), RAD(0), RAD(20)) * RIGHTSHOULDERC0, 0.2 / Animation_Speed)
1941
				LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(-40), RAD(0), RAD(-20)) * LEFTSHOULDERC0, 0.2 / Animation_Speed)
1942
				RightHip.C0 = Clerp(RightHip.C0, CF(1 * Player_Size, -1 * Player_Size, -0.3 * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-5), RAD(0), RAD(-20)), 0.2 / Animation_Speed)
1943
				LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -1 * Player_Size, -0.3 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-5), RAD(0), RAD(20)), 0.2 / Animation_Speed)
1944
	        end
1945
		elseif TORSOVERTICALVELOCITY < -1 and HITFLOOR == nil then
1946
			ANIM = "Fall"
1947
			if ATTACK == false then
1948
				RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0 * Player_Size, 0 * Player_Size, 0.7 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed)
1949
				Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(20), RAD(0), RAD(0)), 0.2 / Animation_Speed)
1950
				RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(60)) * RIGHTSHOULDERC0, 0.2 / Animation_Speed)
1951
				LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(-60)) * LEFTSHOULDERC0, 0.2 / Animation_Speed)
1952
				RightHip.C0 = Clerp(RightHip.C0, CF(1 * Player_Size, -1 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(20)), 0.2 / Animation_Speed)
1953
				LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -1 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(10)), 0.2 / Animation_Speed)
1954
			end
1955
		elseif TORSOVELOCITY < 1 and HITFLOOR ~= nil then
1956
			ANIM = "Idle"
1957
			if ATTACK == false then
1958
				RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0 * Player_Size, 0 * Player_Size, 0.7 * Player_Size + 0.05 * COS(SINE / 12) * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
1959
				Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(15 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 0.15 / Animation_Speed)
1960
				RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(12)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed)
1961
				LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(-12)) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
1962
				RightHip.C0 = Clerp(RightHip.C0, CF(1 * Player_Size, -0.3 * Player_Size - 0 * Player_Size, -0.2 * Player_Size) * ANGLES(RAD(0), RAD(70), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.15 / Animation_Speed)
1963
				LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -0.8 * Player_Size - 0.2 * COS(SINE / 12) * Player_Size, -0.01 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.15 / Animation_Speed)
1964
			end
1965
		elseif TORSOVELOCITY > 1 and HITFLOOR ~= nil then
1966
			ANIM = "Walk"
1967
			WALK = WALK + 1 / Animation_Speed
1968
			if WALK >= 15 - (5 * (Humanoid.WalkSpeed / 16 / Player_Size)) then
1969
				WALK = 0
1970
				if WALKINGANIM == true then
1971
					WALKINGANIM = false
1972
				elseif WALKINGANIM == false then
1973
					WALKINGANIM = true
1974
				end
1975
			end
1976
			--RightHip.C1 = Clerp(RightHip.C1, CF(0.5 * Player_Size, 0.875 * Player_Size - 0.125 * SIN(SINE / WALKSPEEDVALUE) * Player_Size, -0.125 * COS(SINE / WALKSPEEDVALUE) * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0) - RightLeg.RotVelocity.Y / 75, RAD(0), RAD(60 * COS(SINE / WALKSPEEDVALUE))), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
1977
			--LeftHip.C1 = Clerp(LeftHip.C1, CF(-0.5 * Player_Size, 0.875 * Player_Size + 0.125 * SIN(SINE / WALKSPEEDVALUE) * Player_Size, 0.125 * COS(SINE / WALKSPEEDVALUE) * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0) + LeftLeg.RotVelocity.Y / 75, RAD(0), RAD(60 * COS(SINE / WALKSPEEDVALUE))), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
1978
			if ATTACK == false then
1979
				RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0 * Player_Size, 0 * Player_Size, 0.7 * Player_Size) * ANGLES(RAD(25), RAD(0), RAD(0)), 0.15 / Animation_Speed*3)
1980
				Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(-5 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 0.15 / Animation_Speed)
1981
				RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(-40), RAD(0), RAD(20)) * RIGHTSHOULDERC0, 0.2 / Animation_Speed)
1982
				LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(-40), RAD(0), RAD(-20)) * LEFTSHOULDERC0, 0.2 / Animation_Speed) 
1983
				RightHip.C0 = Clerp(RightHip.C0, CF(1 * Player_Size, -0.3 * Player_Size - 0 * Player_Size, -0.2 * Player_Size) * ANGLES(RAD(0), RAD(70), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.15 / Animation_Speed)
1984
				LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -0.8 * Player_Size - 0.2 * COS(SINE / 12) * Player_Size, -0.01 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.15 / Animation_Speed)
1985
			end
1986
		end
1987
if #Effects2>0 then
1988
for e=1,#Effects2 do
1989
if Effects2[e]~=nil then
1990
local Thing=Effects2[e]
1991
if Thing~=nil then
1992
local Part=Thing[1]
1993
local Mode=Thing[2]
1994
local Delay=Thing[3]
1995
local IncX=Thing[4]
1996
local IncY=Thing[5]
1997
local IncZ=Thing[6]
1998
local Part2=Thing[8]
1999
if Thing[1].Transparency<=1 then
2000
if Thing[2]=="Block1" then
2001
Thing[1].CFrame=Thing[1].CFrame
2002
Mesh=Thing[1].Mesh
2003
Mesh.Scale=Mesh.Scale+VT(Thing[4],Thing[5],Thing[6])
2004
Thing[1].Transparency=Thing[1].Transparency+Thing[3]
2005
elseif Thing[2]=="Cylinder" then
2006
Mesh=Thing[1].Mesh
2007
Mesh.Scale=Mesh.Scale+VT(Thing[4],Thing[5],Thing[6])
2008
Thing[1].Transparency=Thing[1].Transparency+Thing[3]
2009
elseif Thing[2]=="Blood" then
2010
Mesh=Thing[7]
2011
Thing[1].CFrame=Thing[1].CFrame*CF(0,.5,0)
2012
Mesh.Scale=Mesh.Scale+VT(Thing[4],Thing[5],Thing[6])
2013
Thing[1].Transparency=Thing[1].Transparency+Thing[3]
2014
elseif Thing[2]=="Elec" then
2015
Mesh=Thing[1].Mesh
2016
Mesh.Scale=Mesh.Scale+VT(Thing[7],Thing[8],Thing[9])
2017
Thing[1].Transparency=Thing[1].Transparency+Thing[3]
2018
elseif Thing[2]=="Disappear" then
2019
Thing[1].Transparency=Thing[1].Transparency+Thing[3]
2020
end
2021
else
2022
Part.Parent=nil
2023
table.remove(Effects2,e)
2024
end
2025
end
2026
end
2027
end
2028
end
2029
unanchor()
2030
Humanoid.MaxHealth = "inf"
2031
Humanoid.Health = "inf"
2032
if Rooted == false then
2033
	Disable_Jump = false
2034
	Humanoid.WalkSpeed = Speed
2035
elseif Rooted == true then
2036
	Disable_Jump = true
2037
	Humanoid.WalkSpeed = 0
2038
end
2039
--CreateMagicCircle(2 ,false,0,3,LeftLeg.CFrame * CF(0,-1.2,0),true)
2040
end
2041
2042
--//=================================\\
2043
--\\=================================//
2044
2045
2046
2047
2048
2049
--//====================================================\\--
2050
--||			  		 END OF SCRIPT
2051
--\\====================================================//--