View difference between Paste ID: Q6X0xY9v and pmEFEYfP
SHOW: | | - or go back to the newest paste.
1
Effects = { }
2
local Player = game.Players.localPlayer
3
local Character = Player.Character
4
local Humanoid = Character.Humanoid
5
Humanoid.WalkSpeed = 20
6
local Mouse = Player:GetMouse()
7
local LeftArm = Character["Left Arm"]
8
local RightArm = Character["Right Arm"]
9
local LeftLeg = Character["Left Leg"]
10
local RightLeg = Character["Right Leg"]
11
local Head = Character.Head
12
local Torso = Character.Torso
13
local Camera = game.Workspace.CurrentCamera
14
local RootPart = Character.HumanoidRootPart
15
local RootJoint = RootPart.RootJoint
16
local attack = false
17
local Anim = 'Idle'
18
local attacktype = 1
19
local Torsovelocity = (RootPart.Velocity * Vector3.new(1, 0, 1)).magnitude 
20
local velocity = RootPart.Velocity.y
21
local sine = 0
22
local change = 1
23
local Create = LoadLibrary("RbxUtility").Create
24
local TimeStop = false
25
26
local m = Create("Model"){
27
	Parent = Character,
28
	Name = "WeaponModel",
29
}
30
31
Humanoid.Animator.Parent = nil
32
Character.Animate.Parent = nil
33
34
local newMotor = function(part0, part1, c0, c1)
35
	local w = Create('Motor'){
36
		Parent = part0,
37
		Part0 = part0,
38
		Part1 = part1,
39
		C0 = c0,
40
		C1 = c1,
41
	}
42
	return w
43
end
44
45
function clerp(a, b, t)
46
	return a:lerp(b, t)
47
end
48
49
RootCF = CFrame.fromEulerAnglesXYZ(-1.57, 0, 3.14)
50
NeckCF = CFrame.new(0, 1, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)
51
52
local RW = newMotor(Torso, RightArm, CFrame.new(1.5, 0, 0), CFrame.new(0, 0, 0)) 
53
local LW = newMotor(Torso, LeftArm, CFrame.new(-1.5, 0, 0), CFrame.new(0, 0, 0))
54
local RH = newMotor(Torso, RightLeg, CFrame.new(.5, -2, 0), CFrame.new(0, 0, 0))
55
local LH = newMotor(Torso, LeftLeg, CFrame.new(-.5, -2, 0), CFrame.new(0, 0, 0))
56
RootJoint.C1 = CFrame.new(0, 0, 0)
57
RootJoint.C0 = CFrame.new(0, 0, 0)
58
Torso.Neck.C1 = CFrame.new(0, 0, 0)
59
Torso.Neck.C0 = CFrame.new(0, 1.5, 0)
60
61
local rarmc1 = RW.C1
62
local larmc1 = LW.C1
63
local rlegc1 = RH.C1
64
local llegc1 = LH.C1
65
66
local resetc1 = false
67
68
function PlayAnimationFromTable(table, speed, bool)
69
	RootJoint.C0 = clerp(RootJoint.C0, table[1], speed) 
70
	Torso.Neck.C0 = clerp(Torso.Neck.C0, table[2], speed) 
71
	RW.C0 = clerp(RW.C0, table[3], speed) 
72
	LW.C0 = clerp(LW.C0, table[4], speed) 
73
	RH.C0 = clerp(RH.C0, table[5], speed) 
74
	LH.C0 = clerp(LH.C0, table[6], speed) 
75
	if bool == true then
76
		if resetc1 == false then
77
			resetc1 = true
78
			RootJoint.C1 = RootJoint.C1
79
			Torso.Neck.C1 = Torso.Neck.C1
80
			RW.C1 = rarmc1
81
			LW.C1 = larmc1
82
			RH.C1 = rlegc1
83
			LH.C1 = llegc1
84
		end
85
	end
86
end
87
88
ArtificialHB = Create("BindableEvent", script){
89
	Parent = script,
90
	Name = "Heartbeat",
91
}
92
93
script:WaitForChild("Heartbeat")
94
95
frame = 1 / 35
96
tf = 0
97
allowframeloss = false
98
tossremainder = false
99
lastframe = tick()
100
script.Heartbeat:Fire()
101
102
game:GetService("RunService").Heartbeat:connect(function(s, p)
103
	tf = tf + s
104
	if tf >= frame then
105
		if allowframeloss then
106
			script.Heartbeat:Fire()
107
			lastframe = tick()
108
		else
109
			for i = 1, math.floor(tf / frame) do
110
				script.Heartbeat:Fire()
111
			end
112
			lastframe = tick()
113
		end
114
		if tossremainder then
115
			tf = 0
116
		else
117
			tf = tf - frame * math.floor(tf / frame)
118
		end
119
	end
120
end)
121
122
function swait(num)
123
	if num == 0 or num == nil then
124
		ArtificialHB.Event:wait()
125
	else
126
		for i = 0, num do
127
			ArtificialHB.Event:wait()
128
		end
129
	end
130
end
131
132
function RemoveOutlines(part)
133
	part.TopSurface, part.BottomSurface, part.LeftSurface, part.RightSurface, part.FrontSurface, part.BackSurface = 10, 10, 10, 10, 10, 10
134
end
135
	
136
CFuncs = {	
137
	Part = {
138
		Create = function(Parent, Material, Reflectance, Transparency, BColor, Name, Size)
139
			local Part = Create("Part"){
140
				Parent = Parent,
141
				Reflectance = Reflectance,
142
				Transparency = Transparency,
143
				CanCollide = false,
144
				Locked = true,
145
				BrickColor = BrickColor.new(tostring(BColor)),
146
				Name = Name,
147
				Size = Size,
148
				Material = Material,
149
			}
150
			RemoveOutlines(Part)
151
			return Part
152
		end;
153
	};
154
	
155
	Mesh = {
156
		Create = function(Mesh, Part, MeshType, MeshId, OffSet, Scale)
157
			local Msh = Create(Mesh){
158
				Parent = Part,
159
				Offset = OffSet,
160
				Scale = Scale,
161
			}
162
			if Mesh == "SpecialMesh" then
163
				Msh.MeshType = MeshType
164
				Msh.MeshId = MeshId
165
			end
166
			return Msh
167
		end;
168
	};
169
170
	Weld = {
171
		Create = function(Parent, Part0, Part1, C0, C1)
172
			local Weld = Create("Weld"){
173
				Parent = Parent,
174
				Part0 = Part0,
175
				Part1 = Part1,
176
				C0 = C0,
177
				C1 = C1,
178
			}
179
			return Weld
180
		end;
181
	};
182
183
	Sound = {
184
		Create = function(id, par, vol, pit) 
185
			local Sound = Create("Sound"){
186
				Volume = vol,
187
				Pitch = pit or 1,
188
				SoundId = "rbxassetid://" .. id,
189
				Parent = par or workspace,
190
			}
191
			Sound:play() 
192
			return Sound
193
		end;
194
	};
195
	
196
	Decal = {
197
		Create = function(Color, Texture, Transparency, Name, Parent)
198
			local Decal = Create("Decal"){
199
				Color3 = Color,
200
				Texture = "rbxassetid://" .. Texture,
201
				Transparency = Transparency,
202
				Name = Name,
203
				Parent = Parent,
204
			}
205
			return Decal
206
		end;
207
	};
208
	
209
	BillboardGui = {
210
		Create = function(Parent, Image, Position, Size)
211
			local BillPar = CFuncs.Part.Create(Parent, "SmoothPlastic", 0, 1, BrickColor.new("Black"), "BillboardGuiPart", Vector3.new(1, 1, 1))
212
			BillPar.CFrame = CFrame.new(Position)
213
			local Bill = Create("BillboardGui"){
214
				Parent = BillPar,
215
				Adornee = BillPar,
216
				Size = UDim2.new(1, 0, 1, 0),
217
				SizeOffset = Vector2.new(Size, Size),
218
			}
219
			local d = Create("ImageLabel", Bill){
220
				Parent = Bill,
221
				BackgroundTransparency = 1,
222
				Size = UDim2.new(1, 0, 1, 0),
223
				Image = "rbxassetid://" .. Image,
224
			}
225
			return BillPar
226
		end
227
	};
228
	
229
	ParticleEmitter = {
230
		Create = function(Parent, Color1, Color2, LightEmission, Size, Texture, Transparency, ZOffset, Accel, Drag, LockedToPart, VelocityInheritance, EmissionDirection, Enabled, LifeTime, Rate, Rotation, RotSpeed, Speed, VelocitySpread)
231
			local Particle = Create("ParticleEmitter"){
232
				Parent = Parent,
233
				Color = ColorSequence.new(Color1, Color2),
234
				LightEmission = LightEmission,
235
				Size = Size,
236
				Texture = Texture,
237
				Transparency = Transparency,
238
				ZOffset = ZOffset,
239
				Acceleration = Accel,
240
				Drag = Drag,
241
				LockedToPart = LockedToPart,
242
				VelocityInheritance = VelocityInheritance,
243
				EmissionDirection = EmissionDirection,
244
				Enabled = Enabled,
245
				Lifetime = LifeTime,
246
				Rate = Rate,
247
				Rotation = Rotation,
248
				RotSpeed = RotSpeed,
249
				Speed = Speed,
250
				VelocitySpread = VelocitySpread,
251
			}
252
			return Particle
253
		end;
254
	};
255
	
256
	CreateTemplate = {
257
		
258
	};
259
}
260
261
function rayCast(Position, Direction, Range, Ignore)
262
	return game:service("Workspace"):FindPartOnRay(Ray.new(Position, Direction.unit * (Range or 999.999)), Ignore) 
263
end 
264
265
function FindNearestTorso(Position, Distance, SinglePlayer)
266
	if SinglePlayer then
267
		return (SinglePlayer.Torso.CFrame.p - Position).magnitude < Distance
268
	end
269
	local List = {}
270
	for i, v in pairs(workspace:GetChildren()) do
271
		if v:IsA("Model") then
272
			if v:findFirstChild("Torso") then
273
				if v ~= Character then
274
					if (v.Torso.Position - Position).magnitude <= Distance then
275
						table.insert(List, v)
276
					end 
277
				end 
278
			end 
279
		end 
280
	end
281
	return List
282
end
283
284
function Damage(Part, hit, minim, maxim, knockback, Type, Property, Delay, HitSound, HitPitch)
285
	if hit.Parent == nil then
286
		return
287
	end
288
	local h = hit.Parent:FindFirstChild("Humanoid")
289
	for _, v in pairs(hit.Parent:children()) do
290
		if v:IsA("Humanoid") then
291
			h = v
292
		end
293
	end
294
	if h ~= nil and hit.Parent.Name ~= Character.Name and hit.Parent:FindFirstChild("Torso") ~= nil then
295
		if hit.Parent:findFirstChild("DebounceHit") ~= nil then
296
			if hit.Parent.DebounceHit.Value == true then
297
				return
298
			end
299
		end
300
		local c = Create("ObjectValue"){
301
			Name = "creator",
302
			Value = game:service("Players").LocalPlayer,
303
			Parent = h,
304
		}
305
		game:GetService("Debris"):AddItem(c, .5)
306
		CFuncs.Sound.Create(HitSound, hit, 1, HitPitch) 
307
		local Damage = math.random(minim, maxim)
308
		local blocked = false
309
		local block = hit.Parent:findFirstChild("Block")
310
		if block ~= nil then
311
			if block.className == "IntValue" then
312
				if block.Value > 0 then
313
					blocked = true
314
					block.Value = block.Value - 1
315
					print(block.Value)
316
				end
317
			end
318
		end
319
		if TimeStop == false then
320
			h.Health = h.Health - Damage
321
			ShowDamage((Part.CFrame * CFrame.new(0, 0, (Part.Size.Z / 2)).p + Vector3.new(0, 1.5, 0)), -Damage, 1.5, BrickColor.new("Deep blue").Color)
322
		elseif TimeStop == true then
323
			repeat wait() until TimeStop == false
324
			h.Health = h.Health - (Damage / 2)
325
			ShowDamage((Part.CFrame * CFrame.new(0, 0, (Part.Size.Z / 2)).p + Vector3.new(0, 1.5, 0)), -Damage, 1.5, BrickColor.new("Deep blue").Color)
326
		end
327
		if Type == "Knockdown" then
328
			local hum = hit.Parent.Humanoid
329
			hum.PlatformStand = true
330
			coroutine.resume(coroutine.create(function(HHumanoid)
331
				swait(1)
332
				HHumanoid.PlatformStand = false
333
			end), hum)
334
			local angle = (hit.Position - (Property.Position + Vector3.new(0, 0, 0))).unit
335
			local bodvol = Create("BodyVelocity"){
336
				velocity = angle * knockback,
337
				P = 5000,
338
				maxForce = Vector3.new(8e+003, 8e+003, 8e+003),
339
				Parent = hit,
340
			}
341
			local rl = Create("BodyAngularVelocity"){
342
				P = 3000,
343
				maxTorque = Vector3.new(500000, 500000, 500000) * 50000000000000,
344
				angularvelocity = Vector3.new(math.random(-10, 10), math.random(-10, 10), math.random(-10, 10)),
345
				Parent = hit,
346
			}
347
			game:GetService("Debris"):AddItem(bodvol, .5)
348
			game:GetService("Debris"):AddItem(rl, .5)
349
		elseif Type == "Normal" then
350
			local vp = Create("BodyVelocity"){
351
				P = 500,
352
				maxForce = Vector3.new(math.huge, 0, math.huge),
353
				velocity = Property.CFrame.lookVector * knockback + Property.Velocity / 1.05,
354
			}
355
			if knockback > 0 then
356
				vp.Parent = hit.Parent.Torso
357
			end
358
			game:GetService("Debris"):AddItem(vp, .5)
359
		elseif Type == "Up" then
360
			local bodyVelocity = Create("BodyVelocity"){
361
				velocity = Vector3.new(0, 20, 0),
362
				P = 5000,
363
				maxForce = Vector3.new(8e+003, 8e+003, 8e+003),
364
				Parent = hit,
365
			}
366
			game:GetService("Debris"):AddItem(bodyVelocity, .5)
367
		elseif Type == "DarkUp" then
368
			coroutine.resume(coroutine.create(function()
369
				for i = 0, 1, 0.1 do
370
					swait()
371
					Effects.Block.Create(BrickColor.new("Black"), hit.Parent.Torso.CFrame, 5, 5, 5, 1, 1, 1, .08, 1)
372
				end
373
			end))
374
			local bodyVelocity = Create("BodyVelocity"){
375
				velocity = Vector3.new(0, 20, 0),
376
				P = 5000,
377
				maxForce = Vector3.new(8e+003, 8e+003, 8e+003),
378
				Parent = hit,
379
			}
380
			game:GetService("Debris"):AddItem(bodyVelocity, 1)
381
		elseif Type == "Snare" then
382
			local bp = Create("BodyPosition"){
383
				P = 2000,
384
				D = 100,
385
				maxForce = Vector3.new(math.huge, math.huge, math.huge),
386
				position = hit.Parent.Torso.Position,
387
				Parent = hit.Parent.Torso,
388
			}
389
			game:GetService("Debris"):AddItem(bp, 1)
390
		elseif Type == "Freeze" then
391
			local BodPos = Create("BodyPosition"){
392
				P = 50000,
393
				D = 1000,
394
				maxForce = Vector3.new(math.huge, math.huge, math.huge),
395
				position = hit.Parent.Torso.Position,
396
				Parent = hit.Parent.Torso,
397
			}
398
			local BodGy = Create("BodyGyro") {
399
				maxTorque = Vector3.new(4e+005, 4e+005, 4e+005) * math.huge ,
400
				P = 20e+003,
401
				Parent = hit.Parent.Torso,
402
				cframe = hit.Parent.Torso.CFrame,
403
			}
404
			hit.Parent.Torso.Anchored = true
405
			coroutine.resume(coroutine.create(function(Part) 
406
				swait(1.5)
407
				Part.Anchored = false
408
			end), hit.Parent.Torso)
409
			game:GetService("Debris"):AddItem(BodPos, 3)
410
			game:GetService("Debris"):AddItem(BodGy, 3)
411
		end
412
		local debounce = Create("BoolValue"){
413
			Name = "DebounceHit",
414
			Parent = hit.Parent,
415
			Value = true,
416
		}
417
		game:GetService("Debris"):AddItem(debounce, Delay)
418
		c = Create("ObjectValue"){
419
			Name = "creator",
420
			Value = Player,
421
			Parent = h,
422
		}
423
		game:GetService("Debris"):AddItem(c, .5)
424
	end
425
end
426
427
function ShowDamage(Pos, Text, Time, Color)
428
	local Rate = (1 / 30)
429
	local Pos = (Pos or Vector3.new(0, 0, 0))
430
	local Text = (Text or "")
431
	local Time = (Time or 2)
432
	local Color = (Color or Color3.new(1, 0, 1))
433
	local EffectPart = CFuncs.Part.Create(workspace, "SmoothPlastic", 0, 1, BrickColor.new(Color), "Effect", Vector3.new(0, 0, 0))
434
	EffectPart.Anchored = true
435
	local BillboardGui = Create("BillboardGui"){
436
		Size = UDim2.new(3, 0, 3, 0),
437
		Adornee = EffectPart,
438
		Parent = EffectPart,
439
	}
440
	local TextLabel = Create("TextLabel"){
441
		BackgroundTransparency = 1,
442
		Size = UDim2.new(1, 0, 1, 0),
443
		Text = Text,
444
		Font = "SciFi",
445
		TextColor3 = Color,
446
		TextScaled = true,
447
		Parent = BillboardGui,
448
	}
449
	game.Debris:AddItem(EffectPart, (Time))
450
	EffectPart.Parent = game:GetService("Workspace")
451
	delay(0, function()
452
		local Frames = (Time / Rate)
453
		for Frame = 1, Frames do
454
			wait(Rate)
455
			local Percent = (Frame / Frames)
456
			EffectPart.CFrame = CFrame.new(Pos) + Vector3.new(0, Percent, 0)
457
			TextLabel.TextTransparency = Percent
458
		end
459
		if EffectPart and EffectPart.Parent then
460
			EffectPart:Destroy()
461
		end
462
	end)
463
end
464
465
function MagnitudeDamage(Part, Magnitude, MinimumDamage, MaximumDamage, KnockBack, Type, HitSound, HitPitch)
466
	for _, c in pairs(workspace:children()) do
467
		local hum = c:findFirstChild("Humanoid")
468
		if hum ~= nil then
469
			local head = c:findFirstChild("Torso")
470
			if head ~= nil then
471
				local targ = head.Position - Part.Position
472
				local mag = targ.magnitude
473
				if mag <= Magnitude and c.Name ~= Player.Name then 
474
			for i = 1, 10 do
475
				Effects.Elect.Create(head.CFrame, 10, 10, 10)
476
			end
477
			CFuncs.Sound.Create("0", head, 1, 1)
478
			Effects.Sphere.Create(BrickColor.new("Deep blue"), head.CFrame, .5, .5, .5, .5, .5, .5, .05)
479
					Damage(head, head, MinimumDamage, MaximumDamage, KnockBack, Type, RootPart, .1, HitSound, HitPitch)
480
				end
481
			end
482
		end
483
	end
484
end
485
486
HandleR = CFuncs.Part.Create(m, Enum.Material.SmoothPlastic, 0, 1, "Deep blue", "HandleR", Vector3.new(0.403949469, 0.452220112, 0.425030977))
487
HandleRWeld = CFuncs.Weld.Create(m, Character["Right Arm"], HandleR, CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1), CFrame.new(-0.637853563, -0.00997161865, 0.00182324648, 0, -1, 0, 1, 0, 0, 0, -0, 1))
488
HitboxR = CFuncs.Part.Create(m, Enum.Material.SmoothPlastic, 0, 1, "Deep blue", "HitboxR", Vector3.new(1.00394952, 1.05222011, 1.02503109))
489
HitboxRWeld = CFuncs.Weld.Create(m, HandleR, HitboxR, CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1), CFrame.new(0.0999999642, 0, 5.96046448e-008, 1, 0, 0, 0, 1, 0, 0, 0, 1))
490
HandleL = CFuncs.Part.Create(m, Enum.Material.SmoothPlastic, 0, 1, "Deep blue", "HandleL", Vector3.new(0.403949469, 0.452220112, 0.425030977))
491
HandleLWeld = CFuncs.Weld.Create(m, Character["Left Arm"], HandleL, CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1), CFrame.new(-0.637853563, -0.00997924805, 0.00182324648, 0, -1, 0, 1, 0, 0, 0, -0, 1))
492
HitboxL = CFuncs.Part.Create(m, Enum.Material.SmoothPlastic, 0, 1, "Deep blue", "HitboxL", Vector3.new(1.00394952, 1.05222011, 1.02503109))
493
HitboxLWeld = CFuncs.Weld.Create(m, HandleL, HitboxL, CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1), CFrame.new(0.0999999642, 3.81469727e-006, 5.96046448e-008, 1, 0, 0, 0, 1, 0, 0, 0, 1))
494
sref = CFuncs.Part.Create(Character, "Neon", 0, 1, BrickColor.new("Black"), "Reference", Vector3.new())
495
sref.Anchored = true
496
497
EffectModel = Create("Model"){
498
	Parent = Character,
499
	Name = "Effects",
500
}
501
502
Effects = {
503
	Block = {
504
		Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay, Type)
505
			local prt = CFuncs.Part.Create(EffectModel, "Neon", 0, 0, brickcolor, "Effect", Vector3.new())
506
			prt.Anchored = true
507
			prt.CFrame = cframe
508
			local msh = CFuncs.Mesh.Create("BlockMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
509
			game:GetService("Debris"):AddItem(prt, 10)
510
			if Type == 1 or Type == nil then
511
				table.insert(Effects, {
512
					prt,
513
					"Block1",
514
					delay,
515
					x3,
516
					y3,
517
					z3,
518
					msh
519
				})
520
			elseif Type == 2 then
521
				table.insert(Effects, {
522
					prt,
523
					"Block2",
524
					delay,
525
					x3,
526
					y3,
527
					z3,
528
					msh
529
				})
530
			end
531
		end;
532
	};
533
	
534
	Cylinder = {
535
		Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
536
			local prt = CFuncs.Part.Create(EffectModel, "Neon", 0, 0, brickcolor, "Effect", Vector3.new(0.2, 0.2, 0.2))
537
			prt.Anchored = true
538
			prt.CFrame = cframe
539
			local msh = CFuncs.Mesh.Create("CylinderMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
540
			game:GetService("Debris"):AddItem(prt, 2)
541
			table.insert(Effects, {
542
				prt,
543
				"Cylinder",
544
				delay,
545
				x3,
546
				y3,
547
				z3,
548
				msh
549
			})
550
		end;
551
	};
552
	
553
	Head = {
554
		Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
555
			local prt = CFuncs.Part.Create(EffectModel, "Neon", 0, 0, brickcolor, "Effect", Vector3.new())
556
			prt.Anchored = true
557
			prt.CFrame = cframe
558
			local msh = CFuncs.Mesh.Create("SpecialMesh", prt, "Head", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
559
			game:GetService("Debris"):AddItem(prt, 10)
560
			table.insert(Effects, {
561
				prt,
562
				"Cylinder",
563
				delay,
564
				x3,
565
				y3,
566
				z3,
567
				msh
568
			})
569
		end;
570
	};
571
	
572
	Sphere = {
573
		Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
574
			local prt = CFuncs.Part.Create(EffectModel, "Neon", 0, 0, brickcolor, "Effect", Vector3.new())
575
			prt.Anchored = true
576
			prt.CFrame = cframe
577
			local msh = CFuncs.Mesh.Create("SpecialMesh", prt, "Sphere", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
578
			game:GetService("Debris"):AddItem(prt, 10)
579
			table.insert(Effects, {
580
				prt,
581
				"Cylinder",
582
				delay,
583
				x3,
584
				y3,
585
				z3,
586
				msh
587
			})
588
		end;
589
	};
590
	
591
	Elect = {
592
		Create = function(cff, x, y, z)
593
			local prt = CFuncs.Part.Create(EffectModel, "Neon", 0, 0, BrickColor.new("Deep blue"), "Part", Vector3.new(1, 1, 1))
594
			prt.Anchored = true
595
			prt.CFrame = cff * CFrame.new(math.random(-x, x), math.random(-y, y), math.random(-z, z))
596
			prt.CFrame = CFrame.new(prt.Position)
597
			game:GetService("Debris"):AddItem(prt, 2)
598
			local xval = math.random() / 2
599
			local yval = math.random() / 2
600
			local zval = math.random() / 2
601
			local msh = CFuncs.Mesh.Create("BlockMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(xval, yval, zval))
602
			table.insert(Effects, {
603
				prt,
604
				"Elec",
605
				0.1,
606
				x,
607
				y,
608
				z,
609
				xval,
610
				yval,
611
				zval
612
			})
613
		end;
614
615
	};
616
	
617
	Ring = {
618
		Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
619
			local prt = CFuncs.Part.Create(EffectModel, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new())
620
			prt.Anchored = true
621
			prt.CFrame = cframe
622
			local msh = CFuncs.Mesh.Create("CylinderMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
623
			game:GetService("Debris"):AddItem(prt, 10)
624
			table.insert(Effects, {
625
				prt,
626
				"Cylinder",
627
				delay,
628
				x3,
629
				y3,
630
				z3,
631
				msh
632
			})
633
		end;
634
	};
635
636
637
	Wave = {
638
		Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
639
			local prt = CFuncs.Part.Create(EffectModel, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new())
640
			prt.Anchored = true
641
			prt.CFrame = cframe
642
			local msh = CFuncs.Mesh.Create("SpecialMesh", prt, "FileMesh", "rbxassetid://20329976", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
643
			game:GetService("Debris"):AddItem(prt, 10)
644
			table.insert(Effects, {
645
				prt,
646
				"Cylinder",
647
				delay,
648
				x3,
649
				y3,
650
				z3,
651
				msh
652
			})
653
		end;
654
	};
655
656
	Break = {
657
		Create = function(brickcolor, cframe, x1, y1, z1)
658
			local prt = CFuncs.Part.Create(EffectModel, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new(0.5, 0.5, 0.5))
659
			prt.Anchored = true
660
			prt.CFrame = cframe * CFrame.fromEulerAnglesXYZ(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50))
661
			local msh = CFuncs.Mesh.Create("SpecialMesh", prt, "Sphere", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
662
			local num = math.random(10, 50) / 1000
663
			game:GetService("Debris"):AddItem(prt, 10)
664
			table.insert(Effects, {
665
				prt,
666
				"Shatter",
667
				num,
668
				prt.CFrame,
669
				math.random() - math.random(),
670
				0,
671
				math.random(50, 100) / 100
672
			})
673
		end;
674
	};
675
	
676
	Fire = {
677
		Create = function(brickcolor, cframe, x1, y1, z1, delay)
678
			local prt = CFuncs.Part.Create(EffectModel, "Neon", 0, 0, brickcolor, "Effect", Vector3.new())
679
			prt.Anchored = true
680
			prt.CFrame = cframe
681
			msh = CFuncs.Mesh.Create("BlockMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
682
			game:GetService("Debris"):AddItem(prt, 10)
683
			table.insert(Effects, {
684
				prt,
685
				"Fire",
686
				delay,
687
				1,
688
				1,
689
				1,
690
				msh
691
			})
692
		end;
693
	};
694
	
695
	FireWave = {
696
		Create = function(brickcolor, cframe, x1, y1, z1)
697
			local prt = CFuncs.Part.Create(EffectModel, "Neon", 0, 1, brickcolor, "Effect", Vector3.new())
698
			prt.Anchored = true
699
			prt.CFrame = cframe
700
			msh = CFuncs.Mesh.Create("BlockMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
701
			local d = Create("Decal"){
702
				Parent = prt,
703
				Texture = "rbxassetid://26356434",
704
				Face = "Top",
705
			}
706
			local d = Create("Decal"){
707
				Parent = prt,
708
				Texture = "rbxassetid://26356434",
709
				Face = "Bottom",
710
			}
711
			game:GetService("Debris"):AddItem(prt, 10)
712
			table.insert(Effects, {
713
				prt,
714
				"FireWave",
715
				1,
716
				30,
717
				math.random(400, 600) / 100,
718
				msh
719
			})
720
		end;
721
	};
722
	
723
	Lightning = {
724
		Create = function(p0, p1, tym, ofs, col, th, tra, last)
725
			local magz = (p0 - p1).magnitude
726
			local curpos = p0
727
			local trz = {
728
				-ofs,
729
				ofs
730
			}
731
			for i = 1, tym do
732
				local li = CFuncs.Part.Create(EffectModel, "Neon", 0, tra or 0.4, col, "Ref", Vector3.new(th, th, magz / tym))
733
				local ofz = Vector3.new(trz[math.random(1, 2)], trz[math.random(1, 2)], trz[math.random(1, 2)])
734
				local trolpos = CFrame.new(curpos, p1) * CFrame.new(0, 0, magz / tym).p + ofz
735
				li.Material = "Neon"
736
				if tym == i then
737
					local magz2 = (curpos - p1).magnitude
738
					li.Size = Vector3.new(th, th, magz2)
739
					li.CFrame = CFrame.new(curpos, p1) * CFrame.new(0, 0, -magz2 / 2)
740
					table.insert(Effects, {
741
						li,
742
						"Disappear",
743
						last
744
					})
745
				else
746
					do
747
						do
748
							li.CFrame = CFrame.new(curpos, trolpos) * CFrame.new(0, 0, magz / tym / 2)
749
							curpos = li.CFrame * CFrame.new(0, 0, magz / tym / 2).p
750
							game.Debris:AddItem(li, 10)
751
							table.insert(Effects, {
752
								li,
753
								"Disappear",
754
								last
755
							})
756
						end
757
					end
758
				end
759
			end
760
		end
761
	};
762
763
	EffectTemplate = {
764
765
	};
766
}
767
768
local DORARA = false
769
770
function ORA()
771
	attack = true
772
	for i = 0, 1, 0.2 do
773
		swait()
774
		PlayAnimationFromTable({
775
			CFrame.new(4.76837158e-007, -0.107780606, -0.0868092626, 1, 0, 0, 0, 0.984807849, 0.173647985, 0, -0.173647985, 0.984807849) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
776
			CFrame.new(0, 1.4999913, 2.38418608e-007, 1, 0, 0, 0, 1.00000012, 0, 0, 0, 1.00000012) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
777
			CFrame.new(1.50214899, 0.590444803, 0.195881441, 0.965925872, 3.76027884e-007, 0.258818895, 0.257834077, -0.0871552154, -0.962250412, 0.0225570519, 0.99619478, -0.0841855928) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
778
			CFrame.new(-1.60470915, 0.600643516, 0.204860806, 0.937436998, -0.0449436344, -0.345242023, -0.345831364, -0.00582624972, -0.938278675, 0.0401581824, 0.998972595, -0.0210046768) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
779
			CFrame.new(0.636808395, -1.93472588, -0.370165229, 0.936116338, -0.0517791435, -0.347858071, 0.0266665779, 0.996705353, -0.0765988752, 0.350678325, 0.0624292716, 0.934412897) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
780
			CFrame.new(-0.6665681, -1.92173398, -0.343467057, 0.962250233, 0.0613082647, 0.265171379, -0.0410595685, 0.99584806, -0.0812460929, -0.269051433, 0.0672912449, 0.960772276) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
781
		}, .3, false)
782
	end
783-
	local DORA = CFuncs.Sound.Create("791374350", Torso, 20, 1)
783+
	local DORA = CFuncs.Sound.Create("636570085", Torso, 20, 1)
784
	Instance.new("DistortionSoundEffect", DORA).Level = .45
785
	DORA.Looped = true
786
	local Con1 = HitboxL.Touched:connect(function(hit) Damage(HitboxL, hit, 1, 5, 0, "Normal", RootPart, 0, "260430117", 1) end)
787
	local Con2 = HitboxR.Touched:connect(function(hit) Damage(HitboxR, hit, 1, 5, 0, "Normal", RootPart, 0, "260430117", 1) end)
788
	while DORARA == true do
789
		RootPart.Velocity = RootPart.CFrame.lookVector * 5
790
		for i = 0, 1, 0.7 do
791
			swait()
792
			Effects.Elect.Create(HitboxL.CFrame, 4, 4, 4)
793
			Effects.Sphere.Create(BrickColor.new("Deep blue"), HitboxL.CFrame, .5, .5, .5, 1.5, 1.5, 1.5, .15)
794
			PlayAnimationFromTable({
795
				CFrame.new(-0.0223142356, -0.107780628, -0.249816686, 0.906307876, 0.0733869597, -0.416197479, 0, 0.98480773, 0.173648462, 0.422617942, -0.157378972, 0.892539084) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
796
				CFrame.new(-2.22850417e-007, 1.49999118, 1.16660271e-006, 0.906307936, 1.49011612e-008, 0.422617972, -7.27595761e-009, 1, 0, -0.422618032, 0, 0.906308055) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
797
				CFrame.new(1.5318948, 0.588474631, 0.207054406, 0.899958313, 0.340718478, 0.272003621, 0.314965397, -0.0767233223, -0.945997, -0.301449746, 0.9370296, -0.176362336) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
798
				CFrame.new(-1.27977741, 0.723447502, -1.20010054, 0.726744413, 0.46058476, -0.509611845, -0.503104627, -0.148215696, -0.851421177, -0.46768418, 0.875153661, 0.124007396) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
799
				CFrame.new(0.636807501, -1.93472636, -0.370165735, 0.868198872, -0.0517790169, 0.493507534, 0.075819321, 0.996705353, -0.0288097262, -0.490389913, 0.0624299645, 0.869264364) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
800
				CFrame.new(-0.666569352, -1.92173386, -0.343467534, 0.86083132, 0.0613082871, 0.505183935, -0.018632248, 0.995848, -0.0891051888, -0.508549333, 0.0672918186, 0.858399451) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
801
			}, .9, false)
802
		end
803
		CFuncs.Sound.Create("200632136", HitboxL, 1, 1)
804
		Effects.Sphere.Create(BrickColor.new("Deep blue"), HitboxL.CFrame, .5, .5, .5, 2, 2, 2, .15)
805
		RootPart.Velocity = RootPart.CFrame.lookVector * 5
806
		for i = 0, 1, 0.7 do
807
			swait()
808
			Effects.Sphere.Create(BrickColor.new("Deep blue"), HitboxR.CFrame, .5, .5, .5, 1.5, 1.5, 1.5, .2)
809
			PlayAnimationFromTable({
810
				CFrame.new(0.0767437443, -0.107780531, -0.279432267, 0.866025388, -0.0868241936, 0.492404073, 0, 0.98480773, 0.173648342, -0.500000238, -0.150383845, 0.852868438) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
811
				CFrame.new(-2.61076184e-006, 1.4999913, -6.19508683e-007, 0.866025209, 2.98023224e-007, -0.500000656, -2.56928615e-007, 1, 1.1920929e-007, 0.500000596, 2.98023224e-008, 0.866025209) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
812
				CFrame.new(1.40606534, 0.812639356, -1.14933658, 0.82139349, -0.422619373, 0.383021921, 0.349686205, -0.157378837, -0.923553765, 0.450591207, 0.892538428, 0.0185142085) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
813
				CFrame.new(-1.64197171, 0.599264741, 0.212680459, 0.807513177, -0.456930667, -0.373010725, -0.413006425, 0.0134942085, -0.9106282, 0.421127379, 0.889400065, -0.177818552) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
814
				CFrame.new(0.636808515, -1.93472552, -0.37016958, 0.814187765, -0.0517790765, -0.578288436, 0.00593282748, 0.996705353, -0.0808905214, 0.580571651, 0.0624291934, 0.811812401) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
815
				CFrame.new(-0.666569233, -1.92173398, -0.343468547, 0.867917657, 0.0613080971, -0.492910266, -0.0864830092, 0.99584806, -0.0284160972, 0.489121556, 0.0672912076, 0.869616032) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
816
			}, .9, false)
817
		end
818
819
fat = Instance.new("BindableEvent", script)
820
fat.Name = "Heartbeat"
821
script:WaitForChild("Heartbeat")
822
frame = 0.013333333333333
823
tf = 0
824
allowframeloss = false
825
tossremainder = false
826
lastframe = tick()
827
script.Heartbeat:Fire()
828
local ss = Instance.new("Sound",char)
829
ss.Volume = 3
830
ss.Looped = true
831
ss.Pitch = 1
832
ss.SoundId = "rbxassetid://0"
833
ss:Play()
834
function sbchat(msg,displayname)
835
        if not displayname then
836
            displayname = 'bela'
837
        end
838
        for i,v in pairs(game:GetService('Players'):GetChildren()) do
839
            local st = Instance.new('StringValue')
840
            st.Name = 'SB_Chat'
841
            st.Value = displayname..'/'..msg
842
            delay(0.2,function() st.Parent = v end)
843
        end
844
    end
845
846
sbchat("ORA ORA ORA",'[Star Platinum]')
847
		CFuncs.Sound.Create("200632136", HitboxR, 1, 1)
848
		Effects.Sphere.Create(BrickColor.new("Deep blue"), HitboxR.CFrame, .5, .5, .5, 2, 2, 2, .2)
849
	    end
850
	Con1:disconnect()
851
	Con2:disconnect()
852
	DORA:Stop()
853
	attack = false
854
end
855
856
local stoppedParts = {}
857
858
859
function getAllParts()
860
    local rtn = {}
861
    
862
    local function recurse(object)
863
        for q,e in next, object:children() do
864
            if e:isA'BasePart' and e.Name ~= "HumanoidRootPart" then
865
                table.insert(rtn, e)
866
            end
867
            recurse(e)
868
        end
869
    end
870
871
    recurse(workspace)
872
    return rtn
873
end
874
875
function stopParts(distance)
876
    stoppedParts = {}
877
    for nada, part in next, getAllParts() do
878
        local dist = (Torso.Position-part.Position).magnitude 
879
        if dist <= distance and part.Name ~='Base' and part.Name ~= 'Baseplate' and not part:isDescendantOf(Torso.Parent) and part.Anchored ~= true then
880
            table.insert(stoppedParts, part)
881
            if part.Name ~= "Torso" and part.Anchored ~= true then
882
                part.Anchored = true
883
            end
884
        end
885
    end
886
end
887
888
889
function freeParts()
890
    for q,e in next, stoppedParts do
891
        stoppedParts[q] = nil
892
        e.Anchored = false
893
    end
894
end
895
896
local effect = Instance.new('ColorCorrectionEffect')
897
function TheWorld(Mode)
898
     if Mode == "Time Start" then
899
	 Effects.Sphere.Create(BrickColor.new("Deep blue"), HitboxL.CFrame, .5, .5, .5, 1.5, 1.5, 1.5, .15)
900
        for i = 1,50 do
901
            if effect.Saturation <= 0 then
902
                effect.Saturation = effect.Saturation + i/50
903
            end
904
            swait(1/30)
905
        end
906
        freeParts()
907
        effect.Saturation = 0
908
        effect.Contrast = 0
909
        effect.Parent = nil
910
        workspace.Gravity = 196.2
911
    end
912
    if Mode == "Quick Stop" then
913
914
fat = Instance.new("BindableEvent", script)
915
fat.Name = "Heartbeat"
916
script:WaitForChild("Heartbeat")
917
frame = 0.013333333333333
918
tf = 0
919
allowframeloss = false
920
tossremainder = false
921
lastframe = tick()
922
script.Heartbeat:Fire()
923
local ss = Instance.new("Sound",char)
924
ss.Volume = 3
925
ss.Looped = true
926
ss.Pitch = 1
927
ss.SoundId = "rbxassetid://0"
928
ss:Play()
929
function sbchat(msg,displayname)
930
        if not displayname then
931
            displayname = 'bela'
932
        end
933
        for i,v in pairs(game:GetService('Players'):GetChildren()) do
934
            local st = Instance.new('StringValue')
935
            st.Name = 'SB_Chat'
936
            st.Value = displayname..'/'..msg
937
            delay(0.2,function() st.Parent = v end)
938
        end
939
    end
940
941
sbchat("THE WORLD!",'[Star Platinum]')
942-
	 local zawarudo = CFuncs.Sound.Create("735067173", workspace, 1, 1)
942+
	 local zawarudo = CFuncs.Sound.Create("843280494", workspace, 1, 1)
943
Instance.new("DistortionSoundEffect", zawarudo).Level = .67
944
	 swait(60)
945
	Effects.Sphere.Create(BrickColor.new("Institutional white"), RootPart.CFrame, 1, 1, 1, 50, 50, 50, .01)
946
        effect.Parent = game.Lighting
947
        for i = 1,50 do
948
            effect.Saturation = -(i/10)
949
            swait()
950
        end
951
        stopParts(5555)
952
    end
953
end
954
955
Mouse.Button1Down:connect(function()
956
	if attack == false and DORARA == false then
957
		DORARA = true
958
        ORA()
959
	end
960
end)
961
962
Mouse.Button1Up:connect(function()
963
	if attack == true and DORARA == true then
964
		DORARA = false
965
	end
966
end)
967
968
Mouse.KeyDown:connect(function(k)
969
	k = k:lower()
970
	if attack == false and k == 'g' and TimeStop == false then
971
	    TimeStop = true
972
		TheWorld("Quick Stop")
973
	elseif attack == false and k == 'g' and TimeStop == true then
974
	    TimeStop = false
975
		TheWorld("Time Start")
976
	end
977
end)
978
979
while true do
980
	swait()
981
	sref.CFrame = RightArm.CFrame * CFrame.new(0, -1.5, 0) * CFrame.fromEulerAnglesXYZ(-1.57, 0, 0)
982
	for i, v in pairs(Character:GetChildren()) do
983
		if v:IsA("Part") then
984
			v.Material = "SmoothPlastic"
985
		elseif v:IsA("Accessory") then
986
			v:WaitForChild("Handle").Material = "SmoothPlastic"
987
		end
988
	end
989
	Torsovelocity = (RootPart.Velocity * Vector3.new(1, 0, 1)).magnitude 
990
	velocity = RootPart.Velocity.y
991
	sine = sine + change
992
	local hit, pos = rayCast(RootPart.Position, (CFrame.new(RootPart.Position, RootPart.Position - Vector3.new(0, 1, 0))).lookVector, 4, Character)
993
	if RootPart.Velocity.y > 1 and hit == nil then 
994
		Anim = "Jump"
995
		if attack == false then
996
			PlayAnimationFromTable({
997
				CFrame.new(0, 0.0486936681, -0.0429394133, 1, 0, -0, 0, 0.996194661, -0.087155968, 0, 0.087155968, 0.996194661) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
998
				CFrame.new(0, 1.48698187, -0.0992434025, 1, 0, 0, 0, 0.98480767, 0.173648626, -0, -0.173648626, 0.98480767) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
999
				CFrame.new(1.66118193, 0.583681226, 0.430878729, 0.556951106, -0.772693694, -0.30454877, 0.830109596, 0.506009281, 0.234249175, -0.026898358, -0.383274168, 0.923242927) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
1000
				CFrame.new(-1.65963519, 0.695907593, 0.339572817, 0.482961893, 0.810776234, 0.330741376, -0.866026103, 0.498096228, 0.0435779653, -0.129409045, -0.307477146, 0.94271481) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
1001
				CFrame.new(0.499997795, -1.71809137, -0.102601528, 0.984807849, 3.55863392e-007, -0.173647791, 0.0593907312, 0.939692557, 0.336824298, 0.163175657, -0.342020214, 0.925416589) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
1002
				CFrame.new(-0.599241376, -1.29528463, -0.396836221, 0.992403984, 0.086823605, 0.0871558413, -0.118890785, 0.858931601, 0.498097867, -0.0316142589, -0.504676282, 0.862729669) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
1003
			}, .3, false)
1004
		end
1005
	elseif RootPart.Velocity.y < -1 and hit == nil then 
1006
		Anim = "Fall"
1007
		if attack == false then
1008
			PlayAnimationFromTable({
1009
				CFrame.new(-0, -0.0520263538, -0.0354017057, 1, 0, 0, 0, 0.965925872, 0.258818984, 0, -0.258818984, 0.965925872) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
1010
				CFrame.new(0, 1.51533091, -0.10684365, 1, 0, 0, 0, 0.965925872, 0.258819342, 0, -0.258819342, 0.965925872) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
1011
				CFrame.new(1.67554009, 0.885679007, 0.385592818, 0.374123871, -0.696466088, -0.61234498, 0.914592147, 0.386364758, 0.119345918, 0.153468132, -0.604696095, 0.781530797) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
1012
				CFrame.new(-1.67474985, 0.999329269, 0.296636045, 0.250219911, 0.753912985, 0.607457995, -0.927206695, 0.367205799, -0.0738086402, -0.278707415, -0.544770718, 0.79091537) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
1013
				CFrame.new(0.504494727, -1.81757987, -0.0935191363, 0.984807849, -0.0449431092, -0.167730823, 0.059390761, 0.99484998, 0.0821366012, 0.163175508, -0.0908504426, 0.982405365) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
1014
				CFrame.new(-0.623603821, -1.49203336, -0.421764404, 0.992403865, 0.122534379, 0.0109562073, -0.118891656, 0.978150725, -0.17054674, -0.0316146575, 0.167948633, 0.985288799) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
1015
			}, .3, false)
1016
		end
1017
	elseif Torsovelocity < 1 and hit ~= nil then
1018
		Anim = "Idle"
1019
		if attack == false then
1020
			change = 1
1021
			PlayAnimationFromTable({
1022
				CFrame.new(-0.0254490171, -0.100000001, -0.0245252885, 0.965925872, 0, 0.258818984, 0, 1, 0, -0.258818984, 0, 0.965925872) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
1023
				CFrame.new(-5.58793545e-008, 1.49999201, 2.23517418e-007, 0.965925872, 0.02255762, -0.257834077, 0, 0.996194661, 0.087155968, 0.258818984, -0.0841862038, 0.962250173) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
1024
				CFrame.new(1.18608475, 0.561332762, -0.668662548, 0.815707564, 0.397307515, 0.420437992, 0.567439079, -0.408345699, -0.71502924, -0.112402454, 0.821827531, -0.558538496) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
1025
				CFrame.new(-1.18486226, 0.664583206, -0.703545451, 0.801997423, -0.384815574, -0.456855893, -0.595755875, -0.459863067, -0.658483863, 0.0433037281, 0.800276875, -0.598065078) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
1026
				CFrame.new(0.602607846, -1.89999723, -0.281901717, 0.938264608, -0.0318391919, -0.344450235, 0.0551190265, 0.996793628, 0.0580029301, 0.341499031, -0.0734078437, 0.937011182) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
1027
				CFrame.new(-0.68740654, -1.99010217, 0.313043743, 0.998308659, 0.0566585623, -0.0130319893, -0.0526040196, 0.975744903, 0.212496698, 0.0247556716, -0.211451754, 0.977074862) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
1028
			}, .3, false)
1029
		end
1030
	elseif Torsovelocity > 2 and hit ~= nil then
1031
		Anim = "Walk"
1032
		if attack == false then
1033
			change = 2
1034
			PlayAnimationFromTable({
1035
				CFrame.new(-0, -0.331043243, -0.246173918, 1, 0, 0, 0, 0.906307876, 0.422617942, 0, -0.422617942, 0.906307876) * CFrame.new(0, .1, 0) * CFrame.Angles(0, math.rad(-5 * math.cos(sine / 7)), 0), 
1036
				CFrame.new(0, 1.4999913, 6.55651093e-007, 1, 0, 0, 0, 0.965925813, -0.258818924, 0, 0.258818924, 0.965925813) * CFrame.new(0, 0, 0) * CFrame.Angles(0, math.rad(5 * math.cos(sine / 7)), 0), 
1037
				CFrame.new(1.14562762, 0.526349247, -0.591056466, 0.825674891, 0.469375819, 0.312965363, 0.547643542, -0.533675969, -0.644419432, -0.135452792, 0.703474402, -0.697693527) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
1038
				CFrame.new(-1.14244175, 0.534408689, -0.582344949, 0.825674295, -0.469376504, -0.312966168, -0.547644734, -0.533675849, -0.644418597, 0.13545242, 0.703474045, -0.697693944) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), 
1039
				CFrame.new(.5, -1.64 - 0.5 * math.cos(sine / 8) / 2, 0 + 2 *  math.sin(sine / 8) / 2) * CFrame.Angles(math.rad(-70 *  math.sin(sine / 8)), math.rad(-3), math.rad(0)),
1040
				CFrame.new(-.5, -1.64 + 0.5 * math.cos(sine / 8) / 2, 0 - 2 * math.sin(sine / 8) / 2) * CFrame.Angles(math.rad(70 *  math.sin(sine / 8)), math.rad(3), math.rad(0)),
1041
			}, .3, false)
1042
		end
1043
	end
1044
	if 0 < #Effects then
1045
		for e = 1, #Effects do
1046
			if Effects[e] ~= nil then
1047
				local Thing = Effects[e]
1048
				if Thing ~= nil then
1049
					local Part = Thing[1]
1050
					local Mode = Thing[2]
1051
					local Delay = Thing[3]
1052
					local IncX = Thing[4]
1053
					local IncY = Thing[5]
1054
					local IncZ = Thing[6]
1055
					if Thing[2] == "Shoot" then
1056
						local Look = Thing[1]
1057
						local move = 5
1058
						local hit, pos = rayCast(Thing[4], Thing[1], move, Character)
1059
						if Thing[10] ~= nil then
1060
							da = pos
1061
							cf2 = CFrame.new(Thing[4], Thing[10].Position)
1062
							cfa = CFrame.new(Thing[4], pos)
1063
							tehCF = cfa:lerp(cf2, 0.2)
1064
							Thing[1] = tehCF.lookVector
1065
						end
1066
						local mag = (Thing[4] - pos).magnitude
1067
						Effects.Elect.Create(CFrame.new((Thing[4] + pos) / 2, pos), 4, 4, 4)
1068
						Effects.Sphere.Create(BrickColor.new("Deep blue"), CFrame.new((Thing[4] + pos) / 2, pos) * CFrame.Angles(1.57, 0, 0), 3, 3, 3, 5, 5, 5, 0.15)
1069
						Thing[4] = Thing[4] + Look * move
1070
						Thing[3] = Thing[3] - 1
1071
						if 2 < Thing[5] then
1072
							Thing[5] = Thing[5] - 0.3
1073
							Thing[6] = Thing[6] - 0.3
1074
						end
1075
						if hit ~= nil then
1076
							Thing[3] = 0
1077
							MagnitudeDamage(hit, 5, 10, 15, 0, "Normal", "161006093", 0.8)
1078
							ref = CFuncs.Part.Create(workspace, "Neon", 0, 1, BrickColor.new("Really red"), "Reference", Vector3.new())
1079
							ref.Anchored = true
1080
							ref.CFrame = CFrame.new(pos)
1081
							Effects.Block.Create(BrickColor.new("Deep blue"), CFrame.new(pos), 1, 1, 1, 2, 2, 2, .05)
1082
							Effects.Sphere.Create(BrickColor.new("Deep blue"), CFrame.new(pos), 5, 5, 5, 1, 1, 1, 0.03)
1083
							game:GetService("Debris"):AddItem(ref, 1)
1084
						end
1085
						if Thing[3] <= 0 then
1086
							table.remove(Effects, e)
1087
						end
1088
					end
1089
					do
1090
						do
1091
							if Thing[2] == "FireWave" then
1092
								if Thing[3] <= Thing[4] then
1093
									Thing[1].CFrame = Thing[1].CFrame * CFrame.fromEulerAnglesXYZ(0, 1, 0)
1094
									Thing[3] = Thing[3] + 1
1095
									Thing[6].Scale = Thing[6].Scale + Vector3.new(Thing[5], 0, Thing[5])
1096
								else
1097
									Part.Parent = nil
1098
									table.remove(Effects, e)
1099
								end
1100
							end
1101
							if Thing[2] ~= "Shoot" and Thing[2] ~= "Wave" and Thing[2] ~= "FireWave" then
1102
								if Thing[1].Transparency <= 1 then
1103
									if Thing[2] == "Block1" then
1104
										Thing[1].CFrame = Thing[1].CFrame * CFrame.fromEulerAnglesXYZ(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50))
1105
										Mesh = Thing[7]
1106
										Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6])
1107
										Thing[1].Transparency = Thing[1].Transparency + Thing[3]
1108
									else
1109
										if Thing[2] == "Block2" then
1110
											Thing[1].CFrame = Thing[1].CFrame
1111
											Mesh = Thing[7]
1112
											Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6])
1113
											Thing[1].Transparency = Thing[1].Transparency + Thing[3]
1114
										else
1115
											if Thing[2] == "Fire" then
1116
												Thing[1].CFrame = CFrame.new(Thing[1].Position) + Vector3.new(0, 0.2, 0)
1117
												Thing[1].CFrame = Thing[1].CFrame * CFrame.fromEulerAnglesXYZ(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50))
1118
												Thing[1].Transparency = Thing[1].Transparency + Thing[3]
1119
											else
1120
												if Thing[2] == "Cylinder" then
1121
													Mesh = Thing[7]
1122
													Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6])
1123
													Thing[1].Transparency = Thing[1].Transparency + Thing[3]
1124
												else
1125
													if Thing[2] == "Blood" then
1126
														Mesh = Thing[7]
1127
														Thing[1].CFrame = Thing[1].CFrame * CFrame.new(0, 0.5, 0)
1128
														Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6])
1129
														Thing[1].Transparency = Thing[1].Transparency + Thing[3]
1130
													else
1131
														if Thing[2] == "Elec" then
1132
															Thing[1].Size = Thing[1].Size + Vector3.new(Thing[7], Thing[8], Thing[9])
1133
															Thing[1].Transparency = Thing[1].Transparency + Thing[3]
1134
														else
1135
															if Thing[2] == "Disappear" then
1136
																Thing[1].Transparency = Thing[1].Transparency + Thing[3]
1137
															end
1138
														end
1139
													end
1140
												end
1141
											end
1142
										end
1143
									end
1144
								else
1145
									Part.Parent = nil
1146
									table.remove(Effects, e)
1147
								end
1148
							end
1149
						end
1150
					end
1151
				end
1152
			end
1153
		end
1154
	end
1155
end