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