View difference between Paste ID: Xi002z0Y and J9J7AreK
SHOW: | | - or go back to the newest paste.
1
if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
2-
--||			   CREATED BY SHACKLUSTER
2+
3-
--\\====================================================//--
3+
4
	print("FE Compatibility code by Mokiros")
5-
wait(0.2)if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
5+
6
7
	--RemoteEvent for communicating
8
	local Event = Instance.new("RemoteEvent")
9
	Event.Name = "UserInput_Event"
10
11
	--Fake event to make stuff like Mouse.KeyDown work
12
	local function fakeEvent()
13
		local t = {_fakeEvent=true,Connect=function(self,f)self.Function=f end}
14
		t.connect = t.Connect
15
		return t
16
	end
17
18
	--Creating fake input objects with fake variables
19
    local m = {Target=nil,Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent()}
20
	local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()}
21
	local CAS = {Actions={},BindAction=function(self,name,fun,touch,...)
22
		CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil
23
	end}
24
	--Merged 2 functions into one by checking amount of arguments
25
	CAS.UnbindAction = CAS.BindAction
26
27
	--This function will trigger the events that have been :Connect()'ed
28
	local function te(self,ev,...)
29
		local t = m[ev]
30
		if t and t._fakeEvent and t.Function then
31
			t.Function(...)
32
		end
33
	end
34
	m.TrigEvent = te
35
	UIS.TrigEvent = te
36
37
	Event.OnServerEvent:Connect(function(plr,io)
38
	    if plr~=Player then return end
39
		if io.isMouse then
40
			m.Target = io.Target
41
			m.Hit = io.Hit
42
		else
43
			local b = io.UserInputState == Enum.UserInputState.Begin
44
			if io.UserInputType == Enum.UserInputType.MouseButton1 then
45
				return m:TrigEvent(b and "Button1Down" or "Button1Up")
46
			end
47
			for _,t in pairs(CAS.Actions) do
48
				for _,k in pairs(t.Keys) do
49
					if k==io.KeyCode then
50
						t.Function(t.Name,io.UserInputState,io)
51
					end
52
				end
53
			end
54
			m:TrigEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower())
55
			UIS:TrigEvent(b and "InputBegan" or "InputEnded",io,false)
56
	    end
57
	end)
58
	Event.Parent = NLS([==[
59
	local Player = game:GetService("Players").LocalPlayer
60
	local Event = script:WaitForChild("UserInput_Event")
61
62
	local UIS = game:GetService("UserInputService")
63
	local input = function(io,a)
64
		if a then return end
65
		--Since InputObject is a client-side instance, we create and pass table instead
66
		Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState})
67
	end
68
	UIS.InputBegan:Connect(input)
69
	UIS.InputEnded:Connect(input)
70
71
	local Mouse = Player:GetMouse()
72
	local h,t
73
	--Give the server mouse data 30 times every second, but only if the values changed
74
	--If player is not moving their mouse, client won't fire events
75
	while wait(1/30) do
76
		if h~=Mouse.Hit or t~=Mouse.Target then
77
			h,t=Mouse.Hit,Mouse.Target
78
			Event:FireServer({isMouse=true,Target=t,Hit=h})
79
		end
80
	end]==],Player.Character)
81
	Mouse,mouse,UserInputService,ContextActionService = m,m,UIS,CAS
82
end
83
84
Player = owner
85
PlayerGui = Player.PlayerGui
86
Cam = workspace.CurrentCamera
87
Backpack = Player.Backpack
88
Character = Player.Character
89
Humanoid = Character.Humanoid
90
RootPart = Character["HumanoidRootPart"]
91
Torso = Character["Torso"]
92
Head = Character["Head"]
93
RightArm = Character["Right Arm"]
94
LeftArm = Character["Left Arm"]
95
RightLeg = Character["Right Leg"]
96
LeftLeg = Character["Left Leg"]
97
RootJoint = RootPart["RootJoint"]
98
Neck = Torso["Neck"]
99
RightShoulder = Torso["Right Shoulder"]
100
LeftShoulder = Torso["Left Shoulder"]
101
RightHip = Torso["Right Hip"]
102
LeftHip = Torso["Left Hip"]
103
local sick = Instance.new("Sound",Character)
104
sick.SoundId = "rbxassetid://1130685064"
105
sick.Looped = true
106
sick.Pitch = 1
107
sick.Volume = 1
108-
sick.SoundId = "rbxassetid://1494340971"
108+
109
110
111
IT = Instance.new
112
CF = CFrame.new
113
VT = Vector3.new
114
RAD = math.rad
115
C3 = Color3.new
116
UD2 = UDim2.new
117
BRICKC = BrickColor.new
118
ANGLES = CFrame.Angles
119
EULER = CFrame.fromEulerAnglesXYZ
120
COS = math.cos
121
ACOS = math.acos
122
SIN = math.sin
123
ASIN = math.asin
124
ABS = math.abs
125
MRANDOM = math.random
126
FLOOR = math.floor
127
128
--//=================================\\
129
--|| 	      USEFUL VALUES
130
--\\=================================//
131
132
local SIZE = 1
133
Animation_Speed = 3
134
Frame_Speed = 1 / 60 -- (1 / 30) OR (1 / 60)
135
local Speed = 20
136
local ROOTC0 = CF(0, 0, 0) * ANGLES(RAD(-90), RAD(0), RAD(180))
137-
local Speed = 25
137+
138
local RIGHTSHOULDERC0 = CF(-0.5, 0, 0) * ANGLES(RAD(0), RAD(90), RAD(0))
139
local LEFTSHOULDERC0 = CF(0.5, 0, 0) * ANGLES(RAD(0), RAD(-90), RAD(0))
140
local DAMAGEMULTIPLIER = 1
141
local ANIM = "Idle"
142
local ATTACK = false
143
local EQUIPPED = false
144
local HOLD = false
145
local COMBO = 1
146
local Rooted = false
147
local SINE = 0
148
local KEYHOLD = false
149
local CHANGE = 2 / Animation_Speed
150
local WALKINGANIM = false
151
local VALUE1 = false
152
local VALUE2 = false
153
local ROBLOXIDLEANIMATION = IT("Animation")
154
ROBLOXIDLEANIMATION.Name = "Roblox Idle Animation"
155
ROBLOXIDLEANIMATION.AnimationId = "http://www.roblox.com/asset/?id=180435571"
156
--ROBLOXIDLEANIMATION.Parent = Humanoid
157
local WEAPONGUI = IT("ScreenGui", PlayerGui)
158
WEAPONGUI.Name = "Weapon GUI"
159
local Effects = IT("Folder", Character)
160
Effects.Name = "Effects"
161
local ANIMATOR = Humanoid.Animator
162
local ANIMATE = Character.Animate
163
local UNANCHOR = true
164
local PLAYMAINANIM = true
165
local BOLTSOUNDS = {168586621,168586586,178452241}
166
167
168
--//=================================\\
169
--\\=================================//
170
171
172
--//=================================\\
173
--|| SAZERENOS' ARTIFICIAL HEARTBEAT
174
--\\=================================//
175
176
ArtificialHB = Instance.new("BindableEvent", script)
177
ArtificialHB.Name = "ArtificialHB"
178
179
script:WaitForChild("ArtificialHB")
180
181
frame = Frame_Speed
182
tf = 0
183
allowframeloss = false
184
tossremainder = false
185
lastframe = tick()
186
script.ArtificialHB:Fire()
187
188
game:GetService("RunService").Heartbeat:connect(function(s, p)
189
	tf = tf + s
190
	if tf >= frame then
191
		if allowframeloss then
192
			script.ArtificialHB:Fire()
193
			lastframe = tick()
194
		else
195
			for i = 1, math.floor(tf / frame) do
196
				script.ArtificialHB:Fire()
197
			end
198
		lastframe = tick()
199
		end
200
		if tossremainder then
201
			tf = 0
202
		else
203
			tf = tf - frame * math.floor(tf / frame)
204
		end
205
	end
206
end)
207
208
--//=================================\\
209
--\\=================================//
210
211
--//=================================\\
212
--|| 	      SOME FUNCTIONS
213
--\\=================================//
214
215
function Raycast(POSITION, DIRECTION, RANGE, IGNOREDECENDANTS)
216
	return workspace:FindPartOnRay(Ray.new(POSITION, DIRECTION.unit * RANGE), IGNOREDECENDANTS)
217
end
218
219
function PositiveAngle(NUMBER)
220
	if NUMBER >= 0 then
221
		NUMBER = 0
222
	end
223
	return NUMBER
224
end
225
226
function NegativeAngle(NUMBER)
227
	if NUMBER <= 0 then
228
		NUMBER = 0
229
	end
230
	return NUMBER
231
end
232
233
function Swait(NUMBER)
234
	if NUMBER == 0 or NUMBER == nil then
235
		ArtificialHB.Event:wait()
236
	else
237
		for i = 1, NUMBER do
238
			ArtificialHB.Event:wait()
239
		end
240
	end
241
end
242
243
function CreateMesh(MESH, PARENT, MESHTYPE, MESHID, TEXTUREID, SCALE, OFFSET)
244
	local NEWMESH = IT(MESH)
245
	if MESH == "SpecialMesh" then
246
		NEWMESH.MeshType = MESHTYPE
247
		if MESHID ~= "nil" and MESHID ~= "" then
248
			NEWMESH.MeshId = "http://www.roblox.com/asset/?id="..MESHID
249
		end
250
		if TEXTUREID ~= "nil" and TEXTUREID ~= "" then
251
			NEWMESH.TextureId = "http://www.roblox.com/asset/?id="..TEXTUREID
252
		end
253
	end
254
	NEWMESH.Offset = OFFSET or VT(0, 0, 0)
255
	NEWMESH.Scale = SCALE
256
	NEWMESH.Parent = PARENT
257
	return NEWMESH
258
end
259
260
function CreatePart(FORMFACTOR, PARENT, MATERIAL, REFLECTANCE, TRANSPARENCY, BRICKCOLOR, NAME, SIZE, ANCHOR)
261
	local NEWPART = IT("Part")
262
	NEWPART.formFactor = FORMFACTOR
263
	NEWPART.Reflectance = REFLECTANCE
264
	NEWPART.Transparency = TRANSPARENCY
265
	NEWPART.CanCollide = false
266
	NEWPART.Locked = true
267
	NEWPART.Anchored = true
268
	if ANCHOR == false then
269
		NEWPART.Anchored = false
270
	end
271
	NEWPART.BrickColor = BRICKC(tostring(BRICKCOLOR))
272
	NEWPART.Name = NAME
273
	NEWPART.Size = SIZE
274
	NEWPART.Position = Torso.Position
275
	NEWPART.Material = MATERIAL
276
	NEWPART:BreakJoints()
277
	NEWPART.Parent = PARENT
278
	return NEWPART
279
end
280
281
	local function weldBetween(a, b)
282
	    local weldd = Instance.new("ManualWeld")
283
	    weldd.Part0 = a
284
	    weldd.Part1 = b
285
	    weldd.C0 = CFrame.new()
286
	    weldd.C1 = b.CFrame:inverse() * a.CFrame
287
	    weldd.Parent = a
288
	    return weldd
289
	end
290
291
292
function QuaternionFromCFrame(cf)
293
	local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components()
294
	local trace = m00 + m11 + m22
295
	if trace > 0 then 
296
		local s = math.sqrt(1 + trace)
297
		local recip = 0.5 / s
298
		return (m21 - m12) * recip, (m02 - m20) * recip, (m10 - m01) * recip, s * 0.5
299
	else
300
		local i = 0
301
		if m11 > m00 then
302
			i = 1
303
		end
304
		if m22 > (i == 0 and m00 or m11) then
305
			i = 2
306
		end
307
		if i == 0 then
308
			local s = math.sqrt(m00 - m11 - m22 + 1)
309
			local recip = 0.5 / s
310
			return 0.5 * s, (m10 + m01) * recip, (m20 + m02) * recip, (m21 - m12) * recip
311
		elseif i == 1 then
312
			local s = math.sqrt(m11 - m22 - m00 + 1)
313
			local recip = 0.5 / s
314
			return (m01 + m10) * recip, 0.5 * s, (m21 + m12) * recip, (m02 - m20) * recip
315
		elseif i == 2 then
316
			local s = math.sqrt(m22 - m00 - m11 + 1)
317
			local recip = 0.5 / s return (m02 + m20) * recip, (m12 + m21) * recip, 0.5 * s, (m10 - m01) * recip
318
		end
319
	end
320
end
321
 
322
function QuaternionToCFrame(px, py, pz, x, y, z, w)
323
	local xs, ys, zs = x + x, y + y, z + z
324
	local wx, wy, wz = w * xs, w * ys, w * zs
325
	local xx = x * xs
326
	local xy = x * ys
327
	local xz = x * zs
328
	local yy = y * ys
329
	local yz = y * zs
330
	local zz = z * zs
331
	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))
332
end
333
 
334
function QuaternionSlerp(a, b, t)
335
	local cosTheta = a[1] * b[1] + a[2] * b[2] + a[3] * b[3] + a[4] * b[4]
336
	local startInterp, finishInterp;
337
	if cosTheta >= 0.0001 then
338
		if (1 - cosTheta) > 0.0001 then
339
			local theta = ACOS(cosTheta)
340
			local invSinTheta = 1 / SIN(theta)
341
			startInterp = SIN((1 - t) * theta) * invSinTheta
342
			finishInterp = SIN(t * theta) * invSinTheta
343
		else
344
			startInterp = 1 - t
345
			finishInterp = t
346
		end
347
	else
348
		if (1 + cosTheta) > 0.0001 then
349
			local theta = ACOS(-cosTheta)
350
			local invSinTheta = 1 / SIN(theta)
351
			startInterp = SIN((t - 1) * theta) * invSinTheta
352
			finishInterp = SIN(t * theta) * invSinTheta
353
		else
354
			startInterp = t - 1
355
			finishInterp = t
356
		end
357
	end
358
	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
359
end
360
361
function Clerp(a, b, t)
362
	local qa = {QuaternionFromCFrame(a)}
363
	local qb = {QuaternionFromCFrame(b)}
364
	local ax, ay, az = a.x, a.y, a.z
365
	local bx, by, bz = b.x, b.y, b.z
366
	local _t = 1 - t
367
	return QuaternionToCFrame(_t * ax + t * bx, _t * ay + t * by, _t * az + t * bz, QuaternionSlerp(qa, qb, t))
368
end
369
370
function CreateFrame(PARENT, TRANSPARENCY, BORDERSIZEPIXEL, POSITION, SIZE, COLOR, BORDERCOLOR, NAME)
371
	local frame = IT("Frame")
372
	frame.BackgroundTransparency = TRANSPARENCY
373
	frame.BorderSizePixel = BORDERSIZEPIXEL
374
	frame.Position = POSITION
375
	frame.Size = SIZE
376
	frame.BackgroundColor3 = COLOR
377
	frame.BorderColor3 = BORDERCOLOR
378
	frame.Name = NAME
379
	frame.Parent = PARENT
380
	return frame
381
end
382
383
function CreateLabel(PARENT, TEXT, TEXTCOLOR, TEXTFONTSIZE, TEXTFONT, TRANSPARENCY, BORDERSIZEPIXEL, STROKETRANSPARENCY, NAME)
384
	local label = IT("TextLabel")
385
	label.BackgroundTransparency = 1
386
	label.Size = UD2(1, 0, 1, 0)
387
	label.Position = UD2(0, 0, 0, 0)
388
	label.TextColor3 = TEXTCOLOR
389
	label.TextStrokeTransparency = STROKETRANSPARENCY
390
	label.TextTransparency = TRANSPARENCY
391
	label.FontSize = TEXTFONTSIZE
392
	label.Font = TEXTFONT
393
	label.BorderSizePixel = BORDERSIZEPIXEL
394
	label.TextScaled = false
395
	label.Text = TEXT
396
	label.Name = NAME
397
	label.Parent = PARENT
398
	return label
399
end
400
401
function NoOutlines(PART)
402
	PART.TopSurface, PART.BottomSurface, PART.LeftSurface, PART.RightSurface, PART.FrontSurface, PART.BackSurface = 10, 10, 10, 10, 10, 10
403
end
404
405
function CreateWeldOrSnapOrMotor(TYPE, PARENT, PART0, PART1, C0, C1)
406
	local NEWWELD = IT(TYPE)
407
	NEWWELD.Part0 = PART0
408
	NEWWELD.Part1 = PART1
409
	NEWWELD.C0 = C0
410
	NEWWELD.C1 = C1
411
	NEWWELD.Parent = PARENT
412
	return NEWWELD
413
end
414
415
local S = IT("Sound")
416
function CreateSound(ID, PARENT, VOLUME, PITCH, DOESLOOP)
417
	local NEWSOUND = nil
418
	coroutine.resume(coroutine.create(function()
419
		NEWSOUND = S:Clone()
420
		NEWSOUND.Parent = PARENT
421
		NEWSOUND.Volume = VOLUME
422
		NEWSOUND.Pitch = PITCH
423
		NEWSOUND.SoundId = "http://www.roblox.com/asset/?id="..ID
424
		NEWSOUND:play()
425
		if DOESLOOP == true then
426
			NEWSOUND.Looped = true
427
		else
428
			repeat wait(1) until NEWSOUND.Playing == false
429
			NEWSOUND:remove()
430
		end
431
	end))
432
	return NEWSOUND
433
end
434
435
local EyeSizes={
436
	NumberSequenceKeypoint.new(0,2,0),
437
	NumberSequenceKeypoint.new(1,0,0)
438
}
439
local EyeTrans={
440
	NumberSequenceKeypoint.new(0,0.5,0),
441
	NumberSequenceKeypoint.new(1,1,0)
442
}
443
local PE=Instance.new("ParticleEmitter",nil)
444
PE.LightEmission=.8
445
PE.Color = ColorSequence.new(BRICKC("Dirt brown").Color,BRICKC("Dirt brown").Color)
446-
PE.Color = ColorSequence.new(BRICKC("Crimson").Color,BRICKC("Really red").Color)
446+
447
PE.Transparency=NumberSequence.new(EyeTrans)
448
PE.Lifetime=NumberRange.new(0.35,1)
449
PE.Rotation=NumberRange.new(0,360)
450
PE.Rate=100
451
PE.VelocitySpread = 10000
452
PE.Acceleration = Vector3.new(0,85,0)
453
PE.Drag = 5
454
PE.Speed = NumberRange.new(0.1,5)
455
PE.Texture="http://www.roblox.com/asset/?id=1460745664"
456
PE.ZOffset = 0.5
457
PE.Name = "PE"
458
PE.Enabled = false
459
460
function Fire(art)
461
	local PARTICLES = PE:Clone()
462
	PARTICLES.Parent = art
463
	PARTICLES.Enabled = true
464
	return PARTICLES
465
end
466
467
function CFrameFromTopBack(at, top, back)
468
	local right = top:Cross(back)
469
	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)
470
end
471
472
--WACKYEFFECT({EffectType = "", Size = VT(1,1,1), Size2 = VT(0,0,0), Transparency = 0, Transparency2 = 1, CFrame = CF(), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(1,1,1), SoundID = nil, SoundPitch = nil, SoundVolume = nil})
473
function WACKYEFFECT(Table)
474
	local TYPE = (Table.EffectType or "Sphere")
475
	local SIZE = (Table.Size or VT(1,1,1))
476
	local ENDSIZE = (Table.Size2 or VT(0,0,0))
477
	local TRANSPARENCY = (Table.Transparency or 0)
478
	local ENDTRANSPARENCY = (Table.Transparency2 or 1)
479
	local CFRAME = (Table.CFrame or Torso.CFrame)
480
	local MOVEDIRECTION = (Table.MoveToPos or nil)
481
	local ROTATION1 = (Table.RotationX or 0)
482
	local ROTATION2 = (Table.RotationY or 0)
483
	local ROTATION3 = (Table.RotationZ or 0)
484
	local MATERIAL = (Table.Material or "Neon")
485
	local COLOR = (Table.Color or C3(1,1,1))
486
	local TIME = (Table.Time or 45)
487
	local SOUNDID = (Table.SoundID or nil)
488
	local SOUNDPITCH = (Table.SoundPitch or nil)
489
	local SOUNDVOLUME = (Table.SoundVolume or nil)
490
	coroutine.resume(coroutine.create(function()
491
		local PLAYSSOUND = false
492
		local SOUND = nil
493
		local EFFECT = CreatePart(3, Effects, MATERIAL, 0, TRANSPARENCY, BRICKC("Crimson"), "Effect", VT(1,1,1), true)
494
		if SOUNDID ~= nil and SOUNDPITCH ~= nil and SOUNDVOLUME ~= nil then
495
			PLAYSSOUND = true
496
			SOUND = CreateSound(SOUNDID, EFFECT, SOUNDVOLUME, SOUNDPITCH, false)
497
		end
498
		EFFECT.Color = COLOR
499
		local MSH = nil
500
		if TYPE == "Sphere" then
501
			MSH = CreateMesh("SpecialMesh", EFFECT, "Sphere", "", "", SIZE, VT(0,0,0))
502
		elseif TYPE == "Block" or TYPE == "Box" then
503
			MSH = IT("BlockMesh",EFFECT)
504
			MSH.Scale = SIZE
505
		elseif TYPE == "Wave" then
506
			MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "20329976", "", SIZE, VT(0,0,-SIZE.X/8))
507
		elseif TYPE == "Ring" then
508
			MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "559831844", "", VT(SIZE.X,SIZE.X,0.1), VT(0,0,0))
509
		elseif TYPE == "Slash" then
510
			MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "662586858", "", VT(SIZE.X/10,0,SIZE.X/10), VT(0,0,0))
511
		elseif TYPE == "Round Slash" then
512
			MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "662585058", "", VT(SIZE.X/10,0,SIZE.X/10), VT(0,0,0))
513
		elseif TYPE == "Swirl" then
514
			MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "1051557", "", SIZE, VT(0,0,0))
515
		elseif TYPE == "Skull" then
516
			MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "4770583", "", SIZE, VT(0,0,0))
517
		elseif TYPE == "Crystal" then
518
			MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "9756362", "", SIZE, VT(0,0,0))
519
		end
520
		if MSH ~= nil then
521
			local MOVESPEED = nil
522
			if MOVEDIRECTION ~= nil then
523
				MOVESPEED = (CFRAME.p - MOVEDIRECTION).Magnitude/TIME
524
			end
525
			local GROWTH = SIZE - ENDSIZE
526
			local TRANS = TRANSPARENCY - ENDTRANSPARENCY
527
			if TYPE == "Block" then
528
				EFFECT.CFrame = CFRAME*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)))
529
			else
530
				EFFECT.CFrame = CFRAME
531
			end
532
			for LOOP = 1, TIME+1 do
533
				Swait()
534
				MSH.Scale = MSH.Scale - GROWTH/TIME
535
				if TYPE == "Wave" then
536
					MSH.Offset = VT(0,0,-MSH.Scale.X/8)
537
				end
538
				EFFECT.Transparency = EFFECT.Transparency - TRANS/TIME
539
				if TYPE == "Block" then
540
					EFFECT.CFrame = CFRAME*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)))
541
				else
542
					EFFECT.CFrame = EFFECT.CFrame*ANGLES(RAD(ROTATION1),RAD(ROTATION2),RAD(ROTATION3))
543
				end
544
				if MOVEDIRECTION ~= nil then
545
					local ORI = EFFECT.Orientation
546
					EFFECT.CFrame = CF(EFFECT.Position,MOVEDIRECTION)*CF(0,0,-MOVESPEED)
547
					EFFECT.Orientation = ORI
548
				end
549
			end
550
			if PLAYSSOUND == false then
551
				EFFECT:remove()
552
			else
553
				repeat wait(1) until SOUND.Playing == false
554
				EFFECT:remove()
555
			end
556
		else
557
			if PLAYSSOUND == false then
558
				EFFECT:remove()
559
			else
560
				repeat Swait() until SOUND.Playing == false
561
				EFFECT:remove()
562
			end
563
		end
564
	end))
565
end
566
567
function MakeForm(PART,TYPE)
568
	if TYPE == "Cyl" then
569
		local MSH = IT("CylinderMesh",PART)
570
	elseif TYPE == "Ball" then
571
		local MSH = IT("SpecialMesh",PART)
572
		MSH.MeshType = "Sphere"
573
	elseif TYPE == "Wedge" then
574
		local MSH = IT("SpecialMesh",PART)
575
		MSH.MeshType = "Wedge"
576
	end
577
end
578
579
Debris = game:GetService("Debris")
580
581
function CastProperRay(StartPos, EndPos, Distance, Ignore)
582
	local DIRECTION = CF(StartPos,EndPos).lookVector
583
	return Raycast(StartPos, DIRECTION, Distance, Ignore)
584
end
585
586
local HATWELD = nil
587
function Pose(WhichPose,Speed,Time,Magic,Gyro,Tors)
588
	PLAYMAINANIM = false
589
	if WhichPose == "Cast1" then
590
		for i=0, Time, 0.1 / Animation_Speed do
591
			Swait()
592
			if Magic == true then
593
				---WACKYEFFECT({Time = 15, EffectType = "Crystal", Size = VT(1,1,1)*1.5, Size2 = VT(0,4,0), Transparency = 0, Transparency2 = 1, CFrame = RightArm.CFrame*CF(0,-1,0)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Glass", Color = BRICKC"Dirt brown".Color, SoundID = nil, SoundPitch = nil, SoundVolume = nil})
594-
				WACKYEFFECT({Time = 15, EffectType = "Crystal", Size = VT(1,1,1)*1.5, Size2 = VT(0,4,0), Transparency = 0, Transparency2 = 1, CFrame = RightArm.CFrame*CF(0,-1,0)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Glass", Color = BRICKC"Really red".Color, SoundID = nil, SoundPitch = nil, SoundVolume = nil})
594+
595
			if Gyro ~= nil and Gyro ~= false then
596
				Gyro.cframe = CF(RootPart.Position,Mouse.Hit.p)
597
			end
598
			RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(35)), Speed / Animation_Speed)
599
			Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(5 - 6.5 * SIN(SINE / 12)), RAD(0), RAD(-35)), Speed / Animation_Speed)
600
			RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.65 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), -0.5) * ANGLES(RAD(125), RAD(0), RAD(45)) * RIGHTSHOULDERC0, Speed / Animation_Speed)
601
			LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.25, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), 0.5) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, Speed / Animation_Speed)
602
			RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.5, -0.5) * ANGLES(RAD(0), RAD(65), RAD(0)) * ANGLES(RAD(-3), RAD(0), RAD(-15)), Speed / Animation_Speed)
603
			LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), Speed / Animation_Speed)
604
		end
605
	elseif WhichPose == "Cast2" then
606
		for i=0, Time, 0.1 / Animation_Speed do
607
			Swait()
608
			if Magic == true then
609
				---WACKYEFFECT({Time = 15, EffectType = "Crystal", Size = VT(1,1,1)*1.5, Size2 = VT(0,4,0), Transparency = 0, Transparency2 = 1, CFrame = RightArm.CFrame*CF(0,-1,0)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Glass", Color = BRICKC"Really red".Color, SoundID = nil, SoundPitch = nil, SoundVolume = nil})
610-
				WACKYEFFECT({Time = 15, EffectType = "Crystal", Size = VT(1,1,1)*1.5, Size2 = VT(0,4,0), Transparency = 0, Transparency2 = 1, CFrame = RightArm.CFrame*CF(0,-1,0)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Glass", Color = BRICKC"Really red".Color, SoundID = nil, SoundPitch = nil, SoundVolume = nil})
610+
				---WACKYEFFECT({Time = 15, EffectType = "Crystal", Size = VT(1,1,1)*1.5, Size2 = VT(0,4,0), Transparency = 0, Transparency2 = 1, CFrame = LeftArm.CFrame*CF(0,-1,0)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Glass", Color = BRICKC"Really red".Color, SoundID = nil, SoundPitch = nil, SoundVolume = nil})
611-
				WACKYEFFECT({Time = 15, EffectType = "Crystal", Size = VT(1,1,1)*1.5, Size2 = VT(0,4,0), Transparency = 0, Transparency2 = 1, CFrame = LeftArm.CFrame*CF(0,-1,0)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Glass", Color = BRICKC"Really red".Color, SoundID = nil, SoundPitch = nil, SoundVolume = nil})
611+
612
			if Gyro ~= nil and Gyro ~= false then
613
				Gyro.cframe = CF(RootPart.Position,Mouse.Hit.p)
614
			end
615
			RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), Speed / Animation_Speed)
616
			Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(-15 - 6.5 * SIN(SINE / 12)), RAD(0), RAD(0)), Speed / Animation_Speed)
617
			RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.65 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), -0.5) * ANGLES(RAD(120), RAD(0), RAD(15)) * RIGHTSHOULDERC0, Speed / Animation_Speed)
618
			LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.65 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), -0.5) * ANGLES(RAD(120), RAD(0), RAD(-15)) * LEFTSHOULDERC0, Speed / Animation_Speed)
619
			RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.5, -0.5) * ANGLES(RAD(0), RAD(65), RAD(0)) * ANGLES(RAD(-3), RAD(0), RAD(-15)), Speed / Animation_Speed)
620
			LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), Speed / Animation_Speed)
621
		end
622
	elseif WhichPose == "RightArmUp" then
623
		for i=0, Time, 0.1 / Animation_Speed do
624
			Swait()
625
			if Magic == true then
626
				---WACKYEFFECT({Time = 15, EffectType = "Crystal", Size = VT(1,1,1)*1.5, Size2 = VT(0,4,0), Transparency = 0, Transparency2 = 1, CFrame = RightArm.CFrame*CF(0,-1,0)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Glass", Color = BRICKC"Really red".Color, SoundID = nil, SoundPitch = nil, SoundVolume = nil})
627-
				WACKYEFFECT({Time = 15, EffectType = "Crystal", Size = VT(1,1,1)*1.5, Size2 = VT(0,4,0), Transparency = 0, Transparency2 = 1, CFrame = RightArm.CFrame*CF(0,-1,0)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Glass", Color = BRICKC"Really red".Color, SoundID = nil, SoundPitch = nil, SoundVolume = nil})
627+
628
			if Gyro ~= nil and Gyro ~= false then
629
				Gyro.cframe = CF(RootPart.Position,Mouse.Hit.p)
630
			end
631
			RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(15)), Speed / Animation_Speed)
632
			Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(-5 - 6.5 * SIN(SINE / 12)), RAD(0), RAD(-15)), Speed / Animation_Speed)
633
			RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.65 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), -0.2) * ANGLES(RAD(125), RAD(0), RAD(25)) * RIGHTSHOULDERC0, Speed / Animation_Speed)
634
			LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.25, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), 0.5) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, Speed / Animation_Speed)
635
			RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.5, -0.5) * ANGLES(RAD(0), RAD(65), RAD(0)) * ANGLES(RAD(-3), RAD(0), RAD(-15)), Speed / Animation_Speed)
636
			LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), Speed / Animation_Speed)
637
		end
638
	elseif WhichPose == "Taunt" then
639
	 for i=0, Time, 0.1 / Animation_Speed do
640
            Swait()
641
            RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), Speed / Animation_Speed)
642
            Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1*SIZE) - 1)) * ANGLES(RAD(-5 - 6.5 * SIN(SINE / 12)), RAD(0), RAD(0)), Speed / Animation_Speed)
643-
			Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(-5 - 6.5 * SIN(SINE / 12)), RAD(0), RAD(0)), Speed / Animation_Speed)
643+
            RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.25*SIZE, 0.5*SIZE + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), -0.5*SIZE) * ANGLES(RAD(175), RAD(0), RAD(-35)) * RIGHTSHOULDERC0, Speed / Animation_Speed)
644-
			RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.25, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), -0.5) * ANGLES(RAD(175), RAD(0), RAD(-35)) * RIGHTSHOULDERC0, Speed / Animation_Speed)
644+
            LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.25*SIZE, 0.5*SIZE + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), 0.5*SIZE) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, Speed / Animation_Speed)
645
            RightHip.C0 = Clerp(RightHip.C0, CF(1*SIZE, -1*SIZE, -0.01*SIZE) * ANGLES(RAD(0), RAD(75), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), Speed / Animation_Speed)
646
            LeftHip.C0 = Clerp(LeftHip.C0, CF(-1*SIZE, -1*SIZE, -0.01*SIZE) * ANGLES(RAD(0), RAD(-75), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), Speed / Animation_Speed)
647
        end
648
        HATWELD.Part0 = RightArm
649-
		HATWELD.Part0 = RightArm
649+
        HATWELD.C0 = CF(0,-1.1,-0.4) * ANGLES(RAD(0), RAD(0), RAD(180)) * ANGLES(RAD(-20), RAD(0), RAD(0))
650-
		HATWELD.C0 = CF(0,-1.1,-0.4) * ANGLES(RAD(0), RAD(0), RAD(180)) * ANGLES(RAD(-20), RAD(0), RAD(0))
650+
        CreateSound(221057812,Torso,10,1,false)
651-
		CreateSound(221057812,Torso,10,1,false)
651+
        for i=0, Time*2, 0.1 / Animation_Speed do
652-
		for i=0, Time*2, 0.1 / Animation_Speed do
652+
            Swait()
653
            RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), Speed / Animation_Speed)
654
            Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1*SIZE) - 1)) * ANGLES(RAD(35 - 6.5 * SIN(SINE / 12)), RAD(0), RAD(0)), Speed / Animation_Speed)
655-
			Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(35 - 6.5 * SIN(SINE / 12)), RAD(0), RAD(0)), Speed / Animation_Speed)
655+
            RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.25*SIZE, 0.5*SIZE + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), 0.5*SIZE) * ANGLES(RAD(145), RAD(0), RAD(45)) * RIGHTSHOULDERC0, Speed / Animation_Speed)
656-
			RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.25, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), 0.5) * ANGLES(RAD(145), RAD(0), RAD(45)) * RIGHTSHOULDERC0, Speed / Animation_Speed)
656+
            LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.25*SIZE, 0.5*SIZE + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), 0.5*SIZE) * ANGLES(RAD(5), RAD(25), RAD(-15)) * LEFTSHOULDERC0, Speed / Animation_Speed)
657-
			LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.25, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), 0.5) * ANGLES(RAD(5), RAD(25), RAD(-15)) * LEFTSHOULDERC0, Speed / Animation_Speed)
657+
            RightHip.C0 = Clerp(RightHip.C0, CF(1*SIZE, -1*SIZE, -0.01*SIZE) * ANGLES(RAD(0), RAD(75), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), Speed / Animation_Speed)
658
            LeftHip.C0 = Clerp(LeftHip.C0, CF(-1*SIZE, -1*SIZE, -0.01*SIZE) * ANGLES(RAD(0), RAD(-75), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), Speed / Animation_Speed)
659
        end
660
        for i=0, Time, 0.1 / Animation_Speed do
661
            Swait()
662
            RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), Speed / Animation_Speed)
663
            Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1*SIZE) - 1)) * ANGLES(RAD(5), RAD(0), RAD(0)), Speed / Animation_Speed)
664-
			Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(5), RAD(0), RAD(0)), Speed / Animation_Speed)
664+
            RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.35*SIZE, 0.65*SIZE, -0.5*SIZE) * ANGLES(RAD(175), RAD(0), RAD(-35)) * RIGHTSHOULDERC0, Speed / Animation_Speed)
665-
			RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.35, 0.65, -0.5) * ANGLES(RAD(175), RAD(0), RAD(-35)) * RIGHTSHOULDERC0, Speed / Animation_Speed)
665+
            LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.25*SIZE, 0.5*SIZE + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), 0.5*SIZE) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, Speed / Animation_Speed)
666
            RightHip.C0 = Clerp(RightHip.C0, CF(1*SIZE, -1*SIZE, -0.01*SIZE) * ANGLES(RAD(0), RAD(75), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), Speed / Animation_Speed)
667
            LeftHip.C0 = Clerp(LeftHip.C0, CF(-1*SIZE, -1*SIZE, -0.01*SIZE) * ANGLES(RAD(0), RAD(-75), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), Speed / Animation_Speed)
668
            HATWELD.C0 = Clerp(HATWELD.C0, CF(-0.5,-1.2,-0.3) * ANGLES(RAD(0), RAD(0), RAD(180)) * ANGLES(RAD(35), RAD(0), RAD(35)), Speed / Animation_Speed)
669-
			HATWELD.C0 = Clerp(HATWELD.C0, CF(-0.5,-1.2,-0.3) * ANGLES(RAD(0), RAD(0), RAD(180)) * ANGLES(RAD(35), RAD(0), RAD(35)), Speed / Animation_Speed)
669+
        end
670
        HATWELD.Part0 = Head
671-
		HATWELD.Part0 = Head
671+
        HATWELD.C0 = CF(0,0.35,0)
672-
		HATWELD.C0 = CF(0,0.35,0)
672+
673
		for i=0, Time, 0.1 / Animation_Speed do
674
			Swait()
675
			if Gyro ~= nil and Gyro ~= false then
676
				Gyro.cframe = CF(RootPart.Position,Tors.Position)
677
			end
678
			RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(65)), Speed / Animation_Speed)
679
			Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(5 - 6.5 * SIN(SINE / 12)), RAD(0), RAD(-65)), Speed / Animation_Speed)
680
			RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), -0.25) * ANGLES(RAD(90), RAD(0), RAD(65)) * RIGHTSHOULDERC0, Speed / Animation_Speed)
681
			LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.25, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), 0.5) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, Speed / Animation_Speed)
682
			RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.5, -0.5) * ANGLES(RAD(0), RAD(65), RAD(0)) * ANGLES(RAD(-3), RAD(0), RAD(-15)), Speed / Animation_Speed)
683
			LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), Speed / Animation_Speed)
684
		end
685
	elseif WhichPose == "Turn key" then
686
		for i=0, Time, 0.1 / Animation_Speed do
687
			Swait()
688
			if Gyro ~= nil and Gyro ~= false then
689
				Gyro.cframe = CF(RootPart.Position,Tors.Position)
690
			end
691
			RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(75)), Speed / Animation_Speed)
692
			Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(5 - 6.5 * SIN(SINE / 12)), RAD(0), RAD(-75)), Speed / Animation_Speed)
693
			RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), -0.25) * ANGLES(RAD(90), RAD(0), RAD(75)) * ANGLES(RAD(0), RAD(-90), RAD(0)) * RIGHTSHOULDERC0, Speed / Animation_Speed)
694
			LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.25, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), 0.5) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, Speed / Animation_Speed)
695
			RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.5, -0.5) * ANGLES(RAD(0), RAD(65), RAD(0)) * ANGLES(RAD(-3), RAD(0), RAD(-15)), Speed / Animation_Speed)
696
			LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), Speed / Animation_Speed)
697
		end
698
	end
699
	PLAYMAINANIM = true
700
end
701
702
--Lightning({Color = C3(1,1,1), Start = Torso.Position, End = Mouse.Hit.p, SegmentL = 2, Thickness = 0.1, DoesFade = false, Ignore = Character, MaxDist = 400, Branches = false})
703
function Lightning(Table)
704
	local Color = Table.Color or C3(1,1,1)
705
	local StartPos = Table.Start or Torso.Position
706
	local EndPos = Table.End or Mouse.Hit.p
707
	local SegmentLength = Table.SegmentL or 2
708
	local Thickness = Table.Thickness or 0.1
709
	local Dissapear = Table.DoesFade or false
710
	local Parent = Table.Ignore or Character
711
	local MaxDist = Table.MaxDist or 400
712
	local Branches = Table.Branches or false
713
	local HIT,HITPOS = CastProperRay(StartPos, EndPos, MaxDist, Parent)
714
	local DISTANCE = math.ceil((StartPos - HITPOS).Magnitude/SegmentLength)
715
	local LIGHTNINGMODEL = IT("Model",Effects)
716
	LIGHTNINGMODEL.Name = "Lightning"
717
	local LastBolt = nil
718
	for E = 1, DISTANCE do
719
		local ExtraSize = (DISTANCE-E)/15
720
		local PART = CreatePart(3, LIGHTNINGMODEL, "Neon", 0, 0, BRICKC("Crimson"), "LightningPart"..E, VT(Thickness+ExtraSize,SegmentLength,Thickness+ExtraSize))
721
		PART.Color = Color
722
		MakeForm(PART,"Cyl")
723
		if LastBolt == nil then
724
			PART.CFrame = CF(StartPos,HITPOS)*ANGLES(RAD(90),RAD(0),RAD(0))*CF(0,-PART.Size.Y/2,0)
725
		else
726
			PART.CFrame = CF(LastBolt.CFrame*CF(0,-LastBolt.Size.Y/2,0).p,CF(HITPOS)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)))*CF(0,0,SegmentLength/3+(DISTANCE-E)).p)*ANGLES(RAD(90),RAD(0),RAD(0))*CF(0,-PART.Size.Y/2,0)
727
		end
728
		LastBolt = PART
729
		if Branches == true then
730
			local CHOICE = MRANDOM(1,7+((DISTANCE-E)*2))
731
			if CHOICE == 1 then
732
				local LASTBRANCH = nil
733
				for i = 1, MRANDOM(2,5) do
734
					local ExtraSize2 = ((DISTANCE-E)/25)/i
735
					local PART = CreatePart(3, LIGHTNINGMODEL, "Neon", 0, 0, BRICKC("Crimson"), "Branch"..E.."-"..i, VT(Thickness+ExtraSize2,SegmentLength,Thickness+ExtraSize2))
736
					PART.Color = Color
737
					MakeForm(PART,"Cyl")
738
					if LASTBRANCH == nil then
739
						PART.CFrame = CF(LastBolt.CFrame*CF(0,-LastBolt.Size.Y/2,0).p,LastBolt.CFrame*CF(0,-LastBolt.Size.Y/2,0)*ANGLES(RAD(0),RAD(0),RAD(MRANDOM(0,360)))*CF(0,Thickness*7,0)*CF(0,0,-1).p)*ANGLES(RAD(90),RAD(0),RAD(0))*CF(0,-PART.Size.Y/2,0)
740
					else
741
						PART.CFrame = CF(LASTBRANCH.CFrame*CF(0,-LASTBRANCH.Size.Y/2,0).p,LASTBRANCH.CFrame*CF(0,-LASTBRANCH.Size.Y/2,0)*ANGLES(RAD(0),RAD(0),RAD(MRANDOM(0,360)))*CF(0,Thickness*3,0)*CF(0,0,-1).p)*ANGLES(RAD(90),RAD(0),RAD(0))*CF(0,-PART.Size.Y/2,0)
742
					end
743
					LASTBRANCH = PART
744
				end
745
			end
746
		end
747
	end
748
	if Dissapear == true then
749
		coroutine.resume(coroutine.create(function()
750
			for i = 1, 10 do
751
				Swait()
752
				for _, c in pairs(LIGHTNINGMODEL:GetChildren()) do
753
					if c.ClassName == "Part" then
754
						c.Transparency = i/10
755
					end
756
				end
757
			end
758
			LIGHTNINGMODEL:remove()
759
		end))
760
	elseif Dissapear == false then
761
		Debris:AddItem(LIGHTNINGMODEL,0.1)
762
	end
763
	return {End = LastBolt.CFrame*CF(0,0,-LastBolt.Size.Z/2).p,LastBolt = LastBolt,Model = LIGHTNINGMODEL}
764
end
765
766
local Create = LoadLibrary("RbxUtility").Create
767
 
768
local chara = Character
769
local m = Create("Model"){
770
    Parent = Character,
771
    Name = "WeaponModel",
772
}
773
function chat(...)
774
    local txxt = {...}
775
    local ch = coroutine.wrap(function()
776
        if chara:FindFirstChild("Chatt")~= nil then
777
            Character:FindFirstChild("Chatt"):destroy()
778
        end
779
 
780
        local txt = Instance.new("BillboardGui", chara)
781
        txt.Adornee = chara.Head
782
        txt.Name = "Chatt"
783
        txt.Size = UDim2.new(2, 0, 1.2, 0)
784
        txt.StudsOffset = Vector3.new(-9, 7, 0)
785
        local text = Instance.new("TextLabel", txt)
786
        text.Size = UDim2.new(10, 0, 7, 0)
787
        text.TextSize = 33
788
        text.Font = Enum.Font.Antique
789
        text.TextScaled = false
790
        text.BackgroundTransparency = 1
791-
local GEM = CreatePart(3, Character, "Neon", 0, 0, "Really red", "Gem", VT(0.25,0.25,0.1),false)
791+
        text.TextColor3 = Color3.new(1,1,1)
792
        text.TextStrokeTransparency = 0
793
        text.TextStrokeColor3 = Color3.fromRGB(81, 69, 69)
794-
local GEM = CreatePart(3, Character, "Neon", 0, 0, "Really red", "Gem", VT(0.25,0.25,0.1),false)
794+
        text.Text = ""
795
        txxt = table.concat(txxt,"\t")
796
        for i = 1, #txxt do
797-
local GEM = CreatePart(3, Character, "Neon", 0, 0, "Really red", "Gem", VT(0.1,0.25,0.25),false)
797+
            text.Text = txxt:sub(1,i)
798
           
799
        end
800-
local GEM = CreatePart(3, Character, "Neon", 0, 0, "Really red", "Gem", VT(0.1,0.25,0.25),false)
800+
        wait(2)
801
        for trans = 0,1,00.1 do
802
            text.TextTransparency = trans
803
            text.TextStrokeTransparency = trans
804
            wait()
805
        end
806
        wait()
807
        txt:destroy()
808
    end)
809
   
810
    ch(...)
811
end
812
Player.Chatted:connect(chat)
813
814
--//=================================\\
815
--||	     WEAPON CREATION
816
--\\=================================//
817
818
819
for i = 1, 15 do
820
	local FACE = CreatePart(3, Character, "Fabric", 0, 0+(i-1)/15.2, "Dark stone grey", "FaceGradient", VT(1.01,0.58,1.01),false)
821
	FACE.Color = C3(0,0,0)
822
	Head:FindFirstChildOfClass("SpecialMesh"):Clone().Parent = FACE
823
	CreateWeldOrSnapOrMotor("Weld", Head, Head, FACE, CF(0,0.35-(i-1)/35,0), CF(0, 0, 0))
824
end
825
local HAT1 = CreatePart(3, Character, "SmoothPlastic", 0, 0, "Really black", "Hat", VT(2,0.2,2),false)
826-
naeeym2.StudsOffset = Vector3.new(0,3,0)
826+
827
HATWELD = CreateWeldOrSnapOrMotor("Weld", Head, Head, HAT1, CF(0,0.35,0), CF(0, 0, 0))
828
local BELT = CreatePart(3, Character, "SmoothPlastic", 0, 0, "Really black", "Hat", VT(2.01,0.15,2.01),false)
829
BELT.Color = C3(15/255,15/255,15/255)
830-
naeeym2.PlayerToHideFrom = Player
830+
831
CreateWeldOrSnapOrMotor("Weld", HAT1, HAT1, BELT, CF(0,0,0), CF(0, 0, 0))
832
local HAT2 = CreatePart(3, Character, "SmoothPlastic", 0, 0, "Really black", "Hat", VT(1.3,2.2,1.3),false)
833
MakeForm(HAT2,"Cyl")
834
CreateWeldOrSnapOrMotor("Weld", HAT1, HAT1, HAT2, CF(0,1.1,0), CF(0, 0, 0))
835-
tecks2.Text = "The Warden"
835+
836-
tecks2.Font = "Bodoni"
836+
837
MakeForm(BELT,"Cyl")
838-
tecks2.TextStrokeTransparency = 0.5
838+
839-
tecks2.TextColor3 = C3(0,0,0)
839+
local GEM = CreatePart(3, Character, "Neon", 0, 0, "Really black", "Gem", VT(0.25,0.25,0.1),false)
840-
tecks2.TextStrokeColor3 = BRICKC"Really red".Color
840+
841
CreateWeldOrSnapOrMotor("Weld", HAT2, HAT2, GEM, CF(0,0,-BELT.Size.X/2), CF(0, 0, 0))
842
local GEM = CreatePart(3, Character, "Neon", 0, 0, "Really black", "Gem", VT(0.25,0.25,0.1),false)
843-
local EYE = CreatePart(3, Character, "Neon", 0, 0, "Really red", "FaceGradient", VT(0.6,0.1,1)/2,false)
843+
844
CreateWeldOrSnapOrMotor("Weld", HAT2, HAT2, GEM, CF(0,0,BELT.Size.X/2), CF(0, 0, 0))
845
local GEM = CreatePart(3, Character, "Neon", 0, 0, "Really black", "Gem", VT(0.1,0.25,0.25),false)
846-
local EYE = CreatePart(3, Character, "Neon", 0, 0, "Really red", "FaceGradient", VT(0.6,0.1,1)/2,false)
846+
847
CreateWeldOrSnapOrMotor("Weld", HAT2, HAT2, GEM, CF(-BELT.Size.X/2,0,0), CF(0, 0, 0))
848
local GEM = CreatePart(3, Character, "Neon", 0, 0, "Really black", "Gem", VT(0.1,0.25,0.25),false)
849-
local EYE = CreatePart(3, Character, "Neon", 0, 0, "Really red", "FaceGradient", VT(0.1,1,1)/2,false)
849+
850
CreateWeldOrSnapOrMotor("Weld", HAT2, HAT2, GEM, CF(BELT.Size.X/2,0,0), CF(0, 0, 0))
851
local BELT = CreatePart(3, Character, "SmoothPlastic", 0, 0, "Really black", "Hat", VT(1.31,0.1,1.31),false)
852-
local EYE = CreatePart(3, Character, "Neon", 0, 0, "Really red", "FaceGradient", VT(0.1,1,1)/2,false)
852+
853
MakeForm(BELT,"Cyl")
854
CreateWeldOrSnapOrMotor("Weld", HAT2, HAT2, BELT, CF(0,0.7,0), CF(0, 0, 0))
855
local BELT = CreatePart(3, Character, "SmoothPlastic", 0, 0, "Really black", "Hat", VT(1.31,0.1,1.31),false)
856
BELT.Color = C3(15/255,15/255,15/255)
857-
top.ShirtTemplate = "rbxassetid://676428254"
857+
858
CreateWeldOrSnapOrMotor("Weld", HAT2, HAT2, BELT, CF(0,-0.7,0), CF(0, 0, 0))
859
local BELT = CreatePart(3, Character, "SmoothPlastic", 0, 0, "Really black", "Hat", VT(1.31,0.1,1.31),false)
860
BELT.Color = C3(15/255,15/255,15/255)
861-
bottom.PantsTemplate = "rbxassetid://676428351"
861+
862
CreateWeldOrSnapOrMotor("Weld", HAT2, HAT2, BELT, CF(0,0.35,0), CF(0, 0, 0))
863
local BELT = CreatePart(3, Character, "SmoothPlastic", 0, 0, "Really black", "Hat", VT(1.31,0.1,1.31),false)
864
BELT.Color = C3(15/255,15/255,15/255)
865
MakeForm(BELT,"Cyl")
866
CreateWeldOrSnapOrMotor("Weld", HAT2, HAT2, BELT, CF(0,-0.35,0), CF(0, 0, 0))
867
local BELT = CreatePart(3, Character, "SmoothPlastic", 0, 0, "Really black", "Hat", VT(1.3,0.5,1.3),false)
868
MakeForm(BELT,"Ball")
869
CreateWeldOrSnapOrMotor("Weld", HAT2, HAT2, BELT, CF(0,HAT2.Size.Y/2,0), CF(0, 0, 0))
870
871
 
872
Humanoid.DisplayDistanceType = "None"
873
local naeeym2 = IT("BillboardGui",Character)
874
naeeym2.AlwaysOnTop = true
875
naeeym2.Size = UDim2.new(5,35,2,15)
876
naeeym2.StudsOffset = Vector3.new(0,2,0)
877
naeeym2.MaxDistance = 75
878
naeeym2.Adornee = Character.Head
879
naeeym2.Name = "Name"
880
local tecks2 = IT("TextLabel",naeeym2)
881
tecks2.BackgroundTransparency = 1
882
tecks2.TextScaled = true
883
tecks2.BorderSizePixel = 0
884
tecks2.Text = "Maniac Warden"
885
tecks2.Font = "Fantasy"
886
tecks2.TextSize = 30
887
tecks2.TextStrokeTransparency = 0
888
tecks2.TextColor3 = C3(1,1,1)
889
tecks2.TextStrokeColor3 = Color3.fromRGB(81, 62, 62)
890
tecks2.Size = UDim2.new(1,0,0.5,0)
891
tecks2.Parent = naeeym2
892
local EYE = CreatePart(3, Character, "Neon", 0, 0, "Dirt brown", "FaceGradient", VT(0.6,0.1,1)/2,false)
893
MakeForm(EYE,"Ball")
894
CreateWeldOrSnapOrMotor("Weld", Head, Head, EYE, CF(0,0.2,0) * ANGLES(RAD(0), RAD(-18), RAD(15)), CF(0, 0, 0.4))
895
local EYE = CreatePart(3, Character, "Neon", 0, 0, "Dirt brown", "FaceGradient", VT(0.6,0.1,1)/2,false)
896
MakeForm(EYE,"Ball")
897
CreateWeldOrSnapOrMotor("Weld", Head, Head, EYE, CF(0,0.2,0) * ANGLES(RAD(0), RAD(18), RAD(-15)), CF(0, 0, 0.4))
898
local EYE = CreatePart(3, Character, "Neon", 0, 0, "Dirt brown", "FaceGradient", VT(0.1,1,1)/2,false)
899
MakeForm(EYE,"Ball")
900
CreateWeldOrSnapOrMotor("Weld", Head, Head, EYE, CF(0,0.15,0) * ANGLES(RAD(0), RAD(-18), RAD(0)), CF(0, 0, 0.4))
901
local EYE = CreatePart(3, Character, "Neon", 0, 0, "Dirt brown", "FaceGradient", VT(0.1,1,1)/2,false)
902
MakeForm(EYE,"Ball")
903
CreateWeldOrSnapOrMotor("Weld", Head, Head, EYE, CF(0,0.15,0) * ANGLES(RAD(0), RAD(18), RAD(0)), CF(0, 0, 0.4))
904
905
local top = Instance.new("Shirt")
906
top.ShirtTemplate = "rbxassetid://1182218263"
907
top.Parent = Character
908
top.Name = "Cloth"
909
local bottom = Instance.new("Pants")
910
bottom.PantsTemplate = "rbxassetid://1829011479"
911
bottom.Parent = Character
912
bottom.Name = "Cloth"
913
for _, c in pairs(Character:GetChildren()) do
914-
		if BODY[e] ~= nil then
914+
915
		c.Material = "Neon"
916
		if c:FindFirstChildOfClass("ParticleEmitter") then
917
			c:FindFirstChildOfClass("ParticleEmitter"):remove()
918
		end
919
		c.Color = C3(1,1,1)
920
		if c == Head then
921
			if c:FindFirstChild("face") then
922
				c.face:remove()
923
			end
924
		end
925
	elseif c.ClassName == "CharacterMesh" or c.ClassName == "Accessory" or c.ClassName == "Hat" or c.Name == "Body Colors" then
926
		c:remove()
927
	elseif (c.ClassName == "Shirt" or c.ClassName == "Pants") and c.Name ~= "Cloth" then
928
		c:remove()
929
	end
930
end
931
local BODY = {}
932
for _, c in pairs(Character:GetDescendants()) do
933
	if c:IsA("BasePart") and c.Name ~= "Handle" then
934-
local SKILLTEXTCOLOR = BRICKC"Really red".Color
934+
935
			c.CustomPhysicalProperties = PhysicalProperties.new(0, 0, 0, 0, 0)
936
		end
937
		table.insert(BODY,{c,c.Parent,c.Material,c.Color,c.Transparency})
938
	elseif c:IsA("JointInstance") then
939
		table.insert(BODY,{c,c.Parent,nil,nil,nil})
940
	end
941
end
942
for e = 1, #BODY do
943
	if BODY[e] ~= nil then
944
		local STUFF = BODY[e]
945
		local PART = STUFF[1]
946
		local PARENT = STUFF[2]
947
		local MATERIAL = STUFF[3]
948
		local COLOR = STUFF[4]
949
		local TRANSPARENCY = STUFF[5]
950
		if PART.ClassName == "Part" and PART ~= RootPart then
951
			PART.Material = MATERIAL
952
			PART.Color = COLOR
953
			PART.Transparency = TRANSPARENCY
954
		end
955
		PART.AncestryChanged:Connect(function()
956
			PART.Parent = PARENT
957
		end)
958
	end
959
end
960
function refit()
961
	Character.Parent = workspace
962
	for e = 1, #BODY do
963
       if BODY[e] ~= nil then
964
			local STUFF = BODY[e]
965
			local PART = STUFF[1]
966
			local PARENT = STUFF[2]
967
			local MATERIAL = STUFF[3]
968
			local COLOR = STUFF[4]
969
			local TRANSPARENCY = STUFF[5]
970
			if PART.ClassName == "Part" and PART ~= RootPart then
971
				PART.Material = MATERIAL
972
				PART.Color = COLOR
973
				PART.Transparency = TRANSPARENCY
974
			end
975
			if PART.Parent ~= PARENT then
976
				Humanoid:remove()
977
				PART.Parent = PARENT
978
				Humanoid = IT("Humanoid",Character)
979
			end
980
		end
981
	end
982
end
983
local SKILLTEXTCOLOR = BRICKC"Dirt brown".Color
984
local SKILLFONT = "Bodoni"
985
local SKILLTEXTSIZE = 7
986
987
Humanoid.Died:connect(function()
988
	refit()
989
end)
990
991
local SKILL1FRAME = CreateFrame(WEAPONGUI, 0.75, 2, UD2(0.23, 0, 0.80, 0), UD2(0.26, 0, 0.07, 0), C3(0,0,0), C3(0, 0, 0), "Skill 1 Frame")
992
local SKILL2FRAME = CreateFrame(WEAPONGUI, 0.75, 2, UD2(0.50, 0, 0.80, 0), UD2(0.26, 0, 0.07, 0), C3(0,0,0), C3(0, 0, 0), "Skill 2 Frame")
993
local SKILL3FRAME = CreateFrame(WEAPONGUI, 0.75, 2, UD2(0.23, 0, 0.90, 0), UD2(0.26, 0, 0.07, 0), C3(0,0,0), C3(0, 0, 0), "Skill 3 Frame")
994
local SKILL4FRAME = CreateFrame(WEAPONGUI, 0.75, 2, UD2(0.50, 0, 0.90, 0), UD2(0.26, 0, 0.07, 0), C3(0,0,0), C3(0, 0, 0), "Skill 4 Frame")
995
local SKILL5FRAME = CreateFrame(WEAPONGUI, 0.75, 2, UD2(0.365, 0, 0.70, 0), UD2(0.26, 0, 0.07, 0), C3(0,0,0), C3(0, 0, 0), "Skill 5 Frame")
996
997
local SKILL1TEXT = CreateLabel(SKILL1FRAME, "[Z] Warden Zap", SKILLTEXTCOLOR, SKILLTEXTSIZE, SKILLFONT, 0, 2, 0, "Text 1")
998
local SKILL2TEXT = CreateLabel(SKILL2FRAME, "[B] Warden Thunder", SKILLTEXTCOLOR, SKILLTEXTSIZE, SKILLFONT, 0, 2, 0, "Text 2")
999
local SKILL3TEXT = CreateLabel(SKILL3FRAME, "[C] Inferno Ring", SKILLTEXTCOLOR, SKILLTEXTSIZE, SKILLFONT, 0, 2, 0, "Text 3")
1000
local SKILL4TEXT = CreateLabel(SKILL4FRAME, "[V] Warden Wall", SKILLTEXTCOLOR, SKILLTEXTSIZE, SKILLFONT, 0, 2, 0, "Text 4")
1001
local SKILL5TEXT = CreateLabel(SKILL5FRAME, "[X] Prison Key", SKILLTEXTCOLOR, SKILLTEXTSIZE, SKILLFONT, 0, 2, 0, "Text 5")
1002
1003
--//=================================\\
1004
--||			DAMAGING
1005-
	WACKYEFFECT({Time = 15, EffectType = "Sphere", Size = VT(1,1,1), Size2 = VT(1,1,1)*15, Transparency = 0, Transparency2 = 1, CFrame = CF(Hitpos)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = BRICKC"Really red".Color, SoundID = BOLTSOUNDS[MRANDOM(1,#BOLTSOUNDS)], SoundPitch = MRANDOM(8,12)/10, SoundVolume = 5})
1005+
1006
1007-
		WACKYEFFECT({Time = 15, EffectType = "Sphere", Size = VT(1,1,1), Size2 = VT(0,45,0), Transparency = 0, Transparency2 = 1, CFrame = CF(Hitpos)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = BRICKC"Really red".Color, SoundID = nil, SoundPitch = nil, SoundVolume = nil})
1007+
1008
	local CHILDREN = workspace:GetDescendants()
1009
	for index, CHILD in pairs(CHILDREN) do
1010
		if CHILD.ClassName == "Model" and CHILD ~= Character then
1011
			local HUM = CHILD:FindFirstChildOfClass("Humanoid")
1012
			if HUM then
1013
				local TORSO = CHILD:FindFirstChild("Torso") or CHILD:FindFirstChild("UpperTorso")
1014
				if TORSO then
1015
					if HUM.Health > 0 and (TORSO.Position - POSITION).Magnitude <= RANGE then
1016
						CHILD:BreakJoints()
1017
						if FLING ~= 0 then
1018
							for _, c in pairs(CHILD:GetChildren()) do
1019
								if c:IsA("BasePart") and c.Transparency == 0 then
1020
									if BURN == true then
1021
										Fire(c)
1022
									end
1023
									local bv = Instance.new("BodyVelocity") 
1024
									bv.maxForce = Vector3.new(1e9, 1e9, 1e9)
1025
									bv.velocity = CF(POSITION,TORSO.Position).lookVector*FLING
1026
									bv.Parent = c
1027
									Debris:AddItem(bv,0.05)
1028
								end
1029
							end
1030
						end
1031-
			WACKYEFFECT({Time = 15, EffectType = "Sphere", Size = VT(1,1,1), Size2 = VT(1,1,1)*15, Transparency = 0, Transparency2 = 1, CFrame = CF(Hitpos)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = BRICKC"Really red".Color, SoundID = BOLTSOUNDS[MRANDOM(1,#BOLTSOUNDS)], SoundPitch = MRANDOM(8,12)/10, SoundVolume = 5})
1031+
1032
				end
1033-
				WACKYEFFECT({Time = 15, EffectType = "Sphere", Size = VT(1,1,1), Size2 = VT(0,75,0), Transparency = 0, Transparency2 = 1, CFrame = CF(Hitpos)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = BRICKC"Really red".Color, SoundID = nil, SoundPitch = nil, SoundVolume = nil})
1033+
1034
		end
1035
	end
1036
end
1037
1038
--//=================================\\
1039
--||	ATTACK FUNCTIONS AND STUFF
1040
--\\=================================//
1041
1042
function Warden_Zap()
1043
	ATTACK = true
1044
	Rooted = false
1045
	local GYRO = IT("BodyGyro",RootPart)
1046
	GYRO.D = 750
1047
	GYRO.P = 20000
1048
	GYRO.MaxTorque = VT(0,40000000,0)
1049
	CreateSound(348663022,RightArm,1.5,2,false)
1050
	Pose("Cast1",0.8,1,true,GYRO)
1051
	local LightningTable = Lightning({Color = SKILLTEXTCOLOR, Start = RightArm.CFrame*CF(0,-1,0).p, End = Mouse.Hit.p, SegmentL = 2, Thickness = 0.2, DoesFade = true, Ignore = Character, MaxDist = 100, Branches = false})
1052
	local Hitpos = LightningTable.End
1053-
	local MAIN = CreatePart(3, FIRE, "Neon", 0, 1, "Really red", "Center", VT(0,0,0))
1053+
1054
	WACKYEFFECT({Time = 15, EffectType = "Sphere", Size = VT(1,1,1), Size2 = VT(1,1,1)*15, Transparency = 0, Transparency2 = 1, CFrame = CF(Hitpos)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = BRICKC"Dirt brown".Color, SoundID = BOLTSOUNDS[MRANDOM(1,#BOLTSOUNDS)], SoundPitch = MRANDOM(8,12)/10, SoundVolume = 5})
1055
	for i = 1, 4 do
1056
		WACKYEFFECT({Time = 15, EffectType = "Sphere", Size = VT(1,1,1), Size2 = VT(0,45,0), Transparency = 0, Transparency2 = 1, CFrame = CF(Hitpos)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = BRICKC"Dirt brown".Color, SoundID = nil, SoundPitch = nil, SoundVolume = nil})
1057-
		local PRT = CreatePart(3, FIRE, "Neon", 0, 1, "Really red", "RingPart", VT(3,3,3))
1057+
1058
	Pose("Cast1",0.8,1,true)
1059
	GYRO:remove()
1060
	ATTACK = false
1061
	Rooted = false
1062
end
1063
1064
function Warden_Thunder()
1065
	ATTACK = true
1066
	Rooted = false
1067
	local GYRO = IT("BodyGyro",RootPart)
1068
	GYRO.D = 750
1069
	GYRO.P = 20000
1070
	GYRO.MaxTorque = VT(0,40000000,0)
1071
	CreateSound(469345336,Torso,3,2,false)
1072
	Pose("Cast2",1.5,2,true,GYRO)
1073
	coroutine.resume(coroutine.create(function()
1074
		local FRAME = RootPart.CFrame
1075
		for i = 1, 25 do
1076
			local POS = FRAME*CF(MRANDOM(-17,17),0,-i*15)
1077
			local LightningTable = Lightning({Color = SKILLTEXTCOLOR, Start = POS*CF(0,85,0).p, End = POS*CF(0,-15,0).p, SegmentL = 3, Thickness = 0.4, DoesFade = true, Ignore = Character, MaxDist = 400, Branches = true})
1078
			local Hitpos = LightningTable.End
1079
			ApplyAoE(Hitpos,20,15)
1080
			WACKYEFFECT({Time = 15, EffectType = "Sphere", Size = VT(1,1,1), Size2 = VT(1,1,1)*15, Transparency = 0, Transparency2 = 1, CFrame = CF(Hitpos)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = BRICKC"Dirt brown".Color, SoundID = BOLTSOUNDS[MRANDOM(1,#BOLTSOUNDS)], SoundPitch = MRANDOM(8,12)/10, SoundVolume = 5})
1081
			for i = 1, 4 do
1082
				WACKYEFFECT({Time = 15, EffectType = "Sphere", Size = VT(1,1,1), Size2 = VT(0,75,0), Transparency = 0, Transparency2 = 1, CFrame = CF(Hitpos)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = BRICKC"Dirt brown".Color, SoundID = nil, SoundPitch = nil, SoundVolume = nil})
1083
			end
1084
			wait(0.05)
1085
		end
1086
	end))
1087
	Pose("Cast2",1.5,0.7,true)
1088
	GYRO:remove()
1089
	ATTACK = false
1090
	Rooted = false
1091
end
1092
1093
function Inferno_Ring()
1094
	ATTACK = true
1095
	Rooted = false
1096
	local GYRO = IT("BodyGyro",RootPart)
1097
	GYRO.D = 750
1098
	GYRO.P = 20000
1099
	GYRO.MaxTorque = VT(0,40000000,0)
1100
	local FIRE = IT("Model",Effects)
1101
	FIRE.Name = "Fire"
1102
	local MAIN = CreatePart(3, FIRE, "Neon", 0, 1, "Dirt brown", "Center", VT(0,0,0))
1103
	FIRE.PrimaryPart = MAIN
1104
	local FIRES = {}
1105
	for i = 1, 45 do
1106
		local PRT = CreatePart(3, FIRE, "Neon", 0, 1, "Dirt brown", "RingPart", VT(3,3,3))
1107
		PRT.CFrame = MAIN.CFrame*ANGLES(RAD(0),RAD((360/45)*i),RAD(0))*CF(0,0,20)
1108
		local F = Fire(PRT)
1109
		table.insert(FIRES,F)
1110-
				WACKYEFFECT({Time = 35, EffectType = "Box", Size = WALL.Size, Size2 = WALL.Size*2, Transparency = 0, Transparency2 = 1, CFrame = WALL.CFrame, MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = BRICKC"Really red".Color, SoundID = nil, SoundPitch = nil, SoundVolume = nil})
1110+
1111
	repeat
1112
		FIRE:SetPrimaryPartCFrame(CF(Mouse.Hit.p))
1113
		Pose("Cast1",1.5,0.01,false,GYRO)
1114
	until HOLD == true
1115
	coroutine.resume(coroutine.create(function()
1116
		for i = 1, 4 do
1117
			ApplyAoE(MAIN.Position,21,-15,true)
1118
			CreateSound(463598785,MAIN,3,1,false)
1119
			for E = 1, #FIRES do
1120
				if FIRES[E] ~= nil then
1121
					FIRES[E].Acceleration = VT(0,300,0)
1122
					FIRES[E].Lifetime=NumberRange.new(0.35,1.5)
1123
				end
1124
			end
1125
			wait(0.3)
1126
		end
1127
		for E = 1, #FIRES do
1128
			if FIRES[E] ~= nil then
1129
				FIRES[E].Enabled = false
1130
			end
1131
		end
1132
		Debris:AddItem(FIRE,5)
1133
	end))
1134
	CreateSound(215395388,RightArm,3,2,false)
1135
	Pose("RightArmUp",1.5,0.5,true)
1136
	GYRO:remove()
1137
	ATTACK = false
1138
	Rooted = false
1139
end
1140
1141
function Warden_Wall()
1142
	local HITFLOOR = Raycast(RootPart.Position, (CF(RootPart.Position, RootPart.Position + VT(0, -1, 0))).lookVector, 8, Character)
1143
	if HITFLOOR ~= nil then
1144
		if HITFLOOR.Anchored == true then
1145
			local WALL = HITFLOOR:Clone()
1146
			WALL.Size = VT(45,45,5)
1147
			WALL.Parent = Effects
1148
			WALL.Name = "Wall"
1149
			WALL.CFrame = RootPart.CFrame*CF(0,-65/2.1,-5)*ANGLES(RAD(-15),RAD(0),RAD(0))
1150
			CreateSound(130972023,WALL,5,0.8,false)
1151
			ATTACK = true
1152
			Rooted = true
1153
			local HIT = WALL.Touched:Connect(function(hit)
1154
				if hit.Parent ~= Character then
1155
					hit:BreakJoints()
1156
				end
1157
			end)
1158
			coroutine.resume(coroutine.create(function()
1159
				WACKYEFFECT({Time = 35, EffectType = "Box", Size = WALL.Size, Size2 = WALL.Size*2, Transparency = 0, Transparency2 = 1, CFrame = WALL.CFrame, MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = BRICKC"Dirt brown".Color, SoundID = nil, SoundPitch = nil, SoundVolume = nil})
1160
				for i = 1, 90 do
1161
					Swait()
1162
					WALL.CFrame = WALL.CFrame*CF(0,0.5,0)
1163
				end
1164
				HIT:disconnect()
1165
				wait(5)
1166
				for i = 1, 46 do
1167
					Swait()
1168
					WALL.CFrame = WALL.CFrame*CF(0,-1,0)
1169
				end
1170
				WALL:remove()
1171
			end))
1172
			Pose("RightArmUp",1.5,1.2,true)
1173
			ATTACK = false
1174
			Rooted = false
1175
		end
1176
	end
1177
end
1178
1179
function Prison_Key()
1180
	if Mouse.Target ~= nil then
1181
		if Mouse.Target.Parent ~= Character and Mouse.Target.Parent.Parent ~= Character and Mouse.Target.Parent:FindFirstChildOfClass("Humanoid") ~= nil then
1182
			local HUM = Mouse.Target.Parent:FindFirstChildOfClass("Humanoid")
1183
			local TORSO = HUM.Parent:FindFirstChild("Torso") or HUM.Parent:FindFirstChild("UpperTorso")
1184
			local GYRO = IT("BodyGyro",RootPart)
1185
			GYRO.D = 750
1186
			GYRO.P = 20000
1187
			GYRO.MaxTorque = VT(0,40000000,0)
1188
			local grav = Instance.new("BodyPosition",TORSO)
1189
			grav.D = 15
1190
			grav.P = 20000
1191
			grav.maxForce = Vector3.new(math.huge,math.huge,math.huge)
1192
			grav.position = TORSO.Position
1193
			local GYRO2 = IT("BodyGyro",TORSO)
1194
			GYRO2.D = 750
1195
			GYRO2.P = 20000
1196
			GYRO2.MaxTorque = VT(0,40000000,0)
1197
			GYRO2.cframe = CF(TORSO.Position,RootPart.Position)
1198
			grav.Name = "Jail"
1199
			local LOCKPARTS = {}
1200
			ATTACK = true
1201-
				local KBASE = CreatePart(3, KEY, "Neon", 0, 0, "Really red", "KeyBase", VT(0.1, 1, 0.1),false)
1201+
1202
			local LOCK = IT("Model",Effects)
1203
			LOCK.Name = "Lock"
1204
			local LOCK2 = IT("Model",LOCK)
1205
			LOCK2.Name = "Metal"
1206-
					local PRT = CreatePart(3, KEY, "Neon", 0, 0, "Really red", "Key", VT(0.1, 0.1, 0.1),false)
1206+
1207
				local BASE = CreatePart(3, LOCK, "Glass", 0, 0, "Gold", "Keylock", VT(3, 2.5, 1))
1208
				LOCK.PrimaryPart = BASE
1209
				BASE.CFrame = CF(TORSO.Position,RootPart.Position)*CF(0,0,-4)
1210-
				local PRT = CreatePart(3, KEY, "Neon", 0, 0, "Really red", "Key", VT(0.3, 0.1, 0.1),false)
1210+
1211
				PRT.CFrame = BASE.CFrame*CF(0,-1.25,0)*ANGLES(RAD(90),RAD(0),RAD(0))
1212
				MakeForm(PRT,"Cyl")
1213-
				local PRT = CreatePart(3, KEY, "Neon", 0, 0, "Really red", "Key", VT(0.3, 0.1, 0.1),false)
1213+
1214
				PRT.Color = C3(0,0,0)
1215
				PRT.CFrame = BASE.CFrame*CF(0,0.3,-0.01)*ANGLES(RAD(90),RAD(0),RAD(0))
1216
				MakeForm(PRT,"Cyl")
1217
				local PRT = CreatePart(3, LOCK, "Glass", 0, 0, "White", "Hole", VT(0.5, 1, 1))
1218
				PRT.Color = C3(0,0,0)
1219
				PRT.CFrame = BASE.CFrame*CF(0,-0.2,-0.01)
1220
				for i = 1, 45 do
1221
					local PRT = CreatePart(3, LOCK2, "Glass", 0, 0, "Grey", "Keylock", VT(0.5, 0.5, 0.5))
1222
					PRT.CFrame = BASE.CFrame*CF(0,2,0)*ANGLES(RAD(0),RAD(0),RAD(-90+(360/90*i)))*CF(0,1,0)
1223
				end
1224
				local PRT = CreatePart(3, LOCK2, "Glass", 0, 0, "Grey", "Keylock", VT(0.5, 0.5, 0.5))
1225
				PRT.CFrame = BASE.CFrame*CF(0,1.5,0)*ANGLES(RAD(0),RAD(0),RAD(90))*CF(0,1,0)
1226
				LOCK2.PrimaryPart = PRT
1227
			---------------
1228
			local CHILDREN = LOCK:GetDescendants()
1229-
					WACKYEFFECT({Time = 35, EffectType = "Crystal", Size = VT(1,1,1), Size2 = VT(0,15,0), Transparency = 0, Transparency2 = 1, CFrame = BASE.CFrame*CF(1,1.45,0)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = BRICKC"Really red".Color, SoundID = nil, SoundPitch = nil, SoundVolume = nil})
1229+
1230
				if CHILD:IsA("BasePart") then
1231-
				WACKYEFFECT({Time = 35, EffectType = "Sphere", Size = VT(0,0,0), Size2 = VT(1,1,1)*25, Transparency = 0, Transparency2 = 1, CFrame = TORSO.CFrame, MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = BRICKC"Really red".Color, SoundID = nil, SoundPitch = MRANDOM(8,12)/10, SoundVolume = 5})
1231+
1232
				end
1233
			end
1234
			for i = 1, 75 do
1235
				LOCK:SetPrimaryPartCFrame(CF(TORSO.Position,RootPart.Position)*CF(0,0,-4))
1236
				Swait()
1237
				GYRO2.cframe = CF(TORSO.Position,RootPart.Position)
1238
				GYRO.cframe = CF(RootPart.Position,TORSO.Position)
1239
				local CHILDREN = LOCK:GetDescendants()
1240
				for index, CHILD in pairs(CHILDREN) do
1241
					if CHILD:IsA("BasePart") then
1242
						CHILD.Transparency = CHILD.Transparency - 1/75
1243
					end
1244
				end
1245
			end
1246
			HUM.DisplayDistanceType = "None"
1247
			local KEY = IT("Model",Effects)
1248
			KEY.Name = "Key"
1249
			--CREATE KEY--
1250
				local KBASE = CreatePart(3, KEY, "Neon", 0, 0, "Dirt brown", "KeyBase", VT(0.1, 1, 0.1),false)
1251
				KEY.PrimaryPart = KBASE
1252
				KBASE.CFrame = RightArm.CFrame*CF(0,-2.1,0)*ANGLES(RAD(0),RAD(90),RAD(0))
1253
				local WLD = weldBetween(RightArm,KBASE)
1254
				for i = 1, 45 do
1255
					local PRT = CreatePart(3, KEY, "Neon", 0, 0, "Dirt brown", "Key", VT(0.1, 0.1, 0.1),false)
1256
					PRT.CFrame = KBASE.CFrame*CF(0,0.8,0)*ANGLES(RAD(0),RAD(0),RAD((360/45*i)))*CF(0,0.25,0)
1257
					weldBetween(KBASE,PRT)
1258
				end
1259
				local PRT = CreatePart(3, KEY, "Neon", 0, 0, "Dirt brown", "Key", VT(0.3, 0.1, 0.1),false)
1260
				PRT.CFrame = KBASE.CFrame*CF(-0.15,-0.45,0)
1261
				weldBetween(KBASE,PRT)
1262
				local PRT = CreatePart(3, KEY, "Neon", 0, 0, "Dirt brown", "Key", VT(0.3, 0.1, 0.1),false)
1263
				PRT.CFrame = KBASE.CFrame*CF(-0.15,-0.25,0)
1264
				weldBetween(KBASE,PRT)
1265
			--------------
1266
			Rooted = true
1267
			Pose("Prepare key",1.5,1.2,false,GYRO,TORSO)
1268
			coroutine.resume(coroutine.create(function()
1269
				for i = 1, 10 do
1270
					Swait()
1271
					GYRO2.cframe = CF(TORSO.Position,RootPart.Position)
1272
					GYRO.cframe = CF(RootPart.Position,TORSO.Position)
1273
				end
1274
				CreateSound(1149318312,BASE,5,1,false)
1275
				CreateSound(160772554,BASE,3,1,false)
1276
				LOCK2:SetPrimaryPartCFrame(BASE.CFrame*CF(0,0.8,0)*ANGLES(RAD(0),RAD(0),RAD(90))*CF(0,1,0))
1277
				for i = 1, 4 do
1278
					WACKYEFFECT({Time = 35, EffectType = "Crystal", Size = VT(1,1,1), Size2 = VT(0,15,0), Transparency = 0, Transparency2 = 1, CFrame = BASE.CFrame*CF(1,1.45,0)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = BRICKC"Dirt brown".Color, SoundID = nil, SoundPitch = nil, SoundVolume = nil})
1279
				end
1280
				WACKYEFFECT({Time = 35, EffectType = "Sphere", Size = VT(0,0,0), Size2 = VT(1,1,1)*25, Transparency = 0, Transparency2 = 1, CFrame = TORSO.CFrame, MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = BRICKC"Dirt brown".Color, SoundID = nil, SoundPitch = MRANDOM(8,12)/10, SoundVolume = 5})
1281
				wait(1)
1282
				TORSO.Parent.Parent = LOCK
1283
				for i = 1, 75 do
1284
					Swait()
1285
					local CHILDREN = KEY:GetDescendants()
1286
					for index, CHILD in pairs(CHILDREN) do
1287
						if CHILD:IsA("BasePart") then
1288
							CHILD.Transparency = i/25
1289
						end
1290
					end
1291
					local CHILDREN = LOCK:GetDescendants()
1292
					for index, CHILD in pairs(CHILDREN) do
1293
						if CHILD:IsA("BasePart") and CHILD.Name ~= "HumanoidRootPart" then
1294
							CHILD.Transparency = CHILD.Transparency + 1/75
1295
						elseif CHILD.ClassName == "Decal" then
1296
							CHILD.Transparency = CHILD.Transparency + 1/75
1297
						end
1298
					end
1299-
	if Key == "v" and ATTACK == false then
1299+
1300
				TORSO.Parent:ClearAllChildren()
1301
				KEY:remove()
1302
				LOCK:remove()
1303
			end))
1304
			Pose("Turn key",0.8,1.2,false,GYRO,TORSO)
1305
			GYRO:remove()
1306
			ATTACK = false
1307
			Rooted = false
1308
		end
1309
	end
1310
end
1311
1312
function Taunt3()
1313
    ATTACK = true
1314
    Rooted = true
1315
    local TAUNT = CreateSound(159882635, Torso,17, 1, false)
1316
    repeat
1317
        Swait()
1318
        TAUNT.Parent = Torso
1319
        TAUNT.Playing = true
1320
        RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed)
1321
        Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(-0.02, 0, 0 + ((1) - 1)) * ANGLES(RAD(0 - 2.5 * SIN(SINE / 12)), RAD(25), RAD(0)), 1 / Animation_Speed)
1322
        RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.1, 0.5, -0.45) * ANGLES(RAD(110), RAD(0), RAD(-80)) * RIGHTSHOULDERC0, 1 / Animation_Speed)
1323
        LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.1, 0.15, -0.45) * ANGLES(RAD(80), RAD(0), RAD(80)) * ANGLES(RAD(0), RAD(45), RAD(0)) * LEFTSHOULDERC0, 1 / Animation_Speed)
1324
        RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), 0) * ANGLES(RAD(0), RAD(80), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed)
1325
        LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), 0) * ANGLES(RAD(0), RAD(-80), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed)
1326
    until TAUNT.TimePosition >= 1.25
1327
    for i=0, 1.6, 0.1 / Animation_Speed do
1328
        Swait()
1329
        TAUNT.Parent = Torso
1330
        RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(5)), 1 / Animation_Speed)
1331
        Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(25)), 1 / Animation_Speed)
1332
        RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.1, 0.5, -0.45) * ANGLES(RAD(110), RAD(0), RAD(-80)) * RIGHTSHOULDERC0, 1 / Animation_Speed)
1333
        LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.1, 0.15, -0.45) * ANGLES(RAD(80), RAD(0), RAD(80)) * ANGLES(RAD(0), RAD(45), RAD(0)) * LEFTSHOULDERC0, 1 / Animation_Speed)
1334
        RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), 0) * ANGLES(RAD(0), RAD(75), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed)
1335
        LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), 0) * ANGLES(RAD(0), RAD(-85), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed)
1336
    end
1337
    ATTACK = false
1338
    Rooted = false
1339
end
1340
1341
function Hat()
1342
	ATTACK = true
1343
	Rooted = false
1344
	Pose("Taunt",0.4,1.2,false)
1345
	ATTACK = false
1346
	Rooted = false
1347
end
1348
1349
--//=================================\\
1350
--||	  ASSIGN THINGS TO KEYS
1351
--\\=================================//
1352
1353
function MouseDown(Mouse)
1354
	HOLD = true
1355
	if ATTACK == false then
1356-
	Swait()
1356+
1357-
	script.Parent = WEAPONGUI
1357+
1358-
	Humanoid.Parent = Character
1358+
1359-
	if Humanoid then
1359+
1360-
		local IDLEANIMATION = Humanoid:LoadAnimation(ROBLOXIDLEANIMATION)
1360+
1361-
		IDLEANIMATION:Play()
1361+
1362
1363-
	if ANIMATE.Parent == Character then
1363+
1364-
		ANIMATE:Destroy()
1364+
1365
	if Key == "z" and ATTACK == false then
1366-
	SINE = SINE + CHANGE
1366+
1367-
	local TORSOVELOCITY = (RootPart.Velocity * VT(1, 0, 1)).magnitude
1367+
1368-
	local TORSOVERTICALVELOCITY = RootPart.Velocity.y
1368+
1369-
	Humanoid.HipHeight = 1
1369+
1370-
	Humanoid.Name = "Warden"
1370+
1371-
	Humanoid.PlatformStand = false
1371+
1372-
	if PLAYMAINANIM == true then
1372+
1373-
		if TORSOVELOCITY < 1 then
1373+
1374-
			RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
1374+
1375-
			Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15 - 6.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 0.15 / Animation_Speed)
1375+
1376-
			RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.25, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), 0.5) * ANGLES(RAD(-45), RAD(0), RAD(-45)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed)
1376+
1377-
			LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.25, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), 0.5) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
1377+
	if Key == "y" and ATTACK == false then
1378-
			RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.5, -0.5) * ANGLES(RAD(0), RAD(65), RAD(0)) * ANGLES(RAD(-3), RAD(0), RAD(-15)), 0.15 / Animation_Speed)
1378+
		Taunt3()
1379-
			LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.15 / Animation_Speed)
1379+
1380-
		elseif TORSOVELOCITY > 1 then
1380+
1381-
			RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(5), RAD(0), RAD(0)), 0.15 / Animation_Speed)
1381+
   if Key == "v" and ATTACK == false then
1382-
			Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(10 - 6.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 0.15 / Animation_Speed)
1382+
1383-
			RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.25, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), 0.5) * ANGLES(RAD(-35), RAD(0), RAD(-45)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed)
1383+
1384-
			LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.25, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), 0.5) * ANGLES(RAD(-35), RAD(0), RAD(45)) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
1384+
1385-
			RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.5, -0.5) * ANGLES(RAD(0), RAD(65), RAD(0)) * ANGLES(RAD(-3), RAD(0), RAD(-20)), 0.15 / Animation_Speed)
1385+
1386-
			LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(10)), 0.15 / Animation_Speed)
1386+
1387
	end
1388
1389
	if Key == "t" and ATTACK == false then
1390
		Hat()
1391
	end
1392
end
1393
1394
function KeyUp(Key)
1395
	KEYHOLD = false
1396
end
1397
1398
	Mouse.Button1Down:connect(function(NEWKEY)
1399
		MouseDown(NEWKEY)
1400
	end)
1401
	Mouse.Button1Up:connect(function(NEWKEY)
1402
		MouseUp(NEWKEY)
1403
	end)
1404
	Mouse.KeyDown:connect(function(NEWKEY)
1405
		KeyDown(NEWKEY)
1406
	end)
1407
	Mouse.KeyUp:connect(function(NEWKEY)
1408
		KeyUp(NEWKEY)
1409
	end)
1410
1411
--//=================================\\
1412
--\\=================================//
1413
1414
1415
function unanchor()
1416
	if UNANCHOR == true then
1417-
	sick.SoundId = "rbxassetid://1494340971"
1417+
1418
		for i = 1, #g do
1419
			if g[i].ClassName == "Part" then
1420-
	sick.Volume = 3
1420+
1421
			end
1422
		end
1423
	end
1424
end
1425
1426
1427
--//=================================\\
1428
--||	WRAP THE WHOLE SCRIPT UP
1429
--\\=================================//
1430
1431
Humanoid.Changed:connect(function(Jump)
1432
	if Jump == "Jump" and (Disable_Jump == true) then
1433
		Humanoid.Jump = false
1434
	end
1435
end)
1436
1437
while true do
1438
    Swait()
1439
           refit()
1440
    script.Parent = WEAPONGUI
1441
    for _,v in next, Humanoid:GetPlayingAnimationTracks() do
1442
        v:Stop();
1443
    end
1444
    ANIMATE.Parent = nil
1445
    SINE = SINE + CHANGE*1.5
1446
    local TORSOVELOCITY = (RootPart.Velocity * VT(1, 0, 1)).magnitude
1447
    local TORSOVERTICALVELOCITY = RootPart.Velocity.y
1448
    local HITFLOOR = Raycast(RootPart.Position, (CF(RootPart.Position, RootPart.Position + VT(0, -1, 0))).lookVector, 4*SIZE, Character)
1449
    local WALKSPEEDVALUE = 10 / (Humanoid.WalkSpeed / 16)
1450
    if ANIM == "Walk" and TORSOVELOCITY > 1 then
1451
        RootJoint.C1 = Clerp(RootJoint.C1, ROOTC0 * CF(0, 0, -0.15 * COS(SINE / (WALKSPEEDVALUE / 2))) * ANGLES(RAD(0), RAD(0) - RootPart.RotVelocity.Y / 75, RAD(0)), 2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
1452
        Neck.C1 = Clerp(Neck.C1, CF(0, -0.5, 0) * 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)
1453
        RightHip.C1 = Clerp(RightHip.C1, CF(0.5*SIZE, 0.875*SIZE - 0.125 * SIN(SINE / WALKSPEEDVALUE)*SIZE - 0.15 * COS(SINE / WALKSPEEDVALUE*2), 0 +0.5+ 0.2 * COS(SINE / WALKSPEEDVALUE)) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0) - RightLeg.RotVelocity.Y / 75, RAD(0), RAD(25+80 * COS(SINE / WALKSPEEDVALUE))), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
1454
        LeftHip.C1 = Clerp(LeftHip.C1, CF(-0.5*SIZE, 0.875*SIZE + 0.125 * SIN(SINE / WALKSPEEDVALUE)*SIZE - 0.15 * COS(SINE / WALKSPEEDVALUE*2), 0 +0.5+ -0.2 * COS(SINE / WALKSPEEDVALUE)) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0) + LeftLeg.RotVelocity.Y / 75, RAD(0), RAD(-25+80 * COS(SINE / WALKSPEEDVALUE))), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
1455
    elseif (ANIM ~= "Walk") or (TORSOVELOCITY < 1) then
1456
        RootJoint.C1 = Clerp(RootJoint.C1, ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed)
1457
        Neck.C1 = Clerp(Neck.C1, CF(0, -0.5, 0) * ANGLES(RAD(-90), RAD(0), RAD(180)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed)
1458
        RightHip.C1 = Clerp(RightHip.C1, CF(0.5*SIZE, 1*SIZE, 0) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed)
1459
        LeftHip.C1 = Clerp(LeftHip.C1, CF(-0.5*SIZE, 1*SIZE, 0) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed)
1460
    end
1461
    if TORSOVERTICALVELOCITY > 1 and HITFLOOR == nil then
1462
        ANIM = "Jump"
1463
        if ATTACK == false then
1464
            RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0*SIZE, 0*SIZE, 0*SIZE) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed)
1465
            Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0*SIZE, 0*SIZE, 0 + ((1.1*SIZE) - 1)) * ANGLES(RAD(-20), RAD(0), RAD(0)), 1 / Animation_Speed)
1466
            RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5*SIZE, 0.5*SIZE, 0*SIZE) * ANGLES(RAD(-40), RAD(0), RAD(20)) * RIGHTSHOULDERC0, 1 / Animation_Speed)
1467
            LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5*SIZE, 0.5*SIZE, 0*SIZE) * ANGLES(RAD(-40), RAD(0), RAD(-20)) * LEFTSHOULDERC0, 1 / Animation_Speed)
1468
            RightHip.C0 = Clerp(RightHip.C0, CF(1*SIZE, -1*SIZE, -0.3*SIZE) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-5), RAD(0), RAD(-20)), 1 / Animation_Speed)
1469
            LeftHip.C0 = Clerp(LeftHip.C0, CF(-1*SIZE, -1*SIZE, -0.3*SIZE) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-5), RAD(0), RAD(20)), 1 / Animation_Speed)
1470
        end
1471
    elseif TORSOVERTICALVELOCITY < -1 and HITFLOOR == nil then
1472
        ANIM = "Fall"
1473
        if ATTACK == false then
1474
            RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0*SIZE, 0*SIZE, 0*SIZE) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed)
1475
            Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0*SIZE, 0*SIZE, 0 + ((1.1*SIZE) - 1)) * ANGLES(RAD(20), RAD(0), RAD(0)), 1 / Animation_Speed)
1476
            RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5*SIZE, 0.5*SIZE, 0*SIZE) * ANGLES(RAD(0), RAD(0), RAD(60)) * RIGHTSHOULDERC0, 1 / Animation_Speed)
1477
            LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5*SIZE, 0.5*SIZE, 0*SIZE) * ANGLES(RAD(0), RAD(0), RAD(-60)) * LEFTSHOULDERC0, 1 / Animation_Speed)
1478
            RightHip.C0 = Clerp(RightHip.C0, CF(1*SIZE, -1*SIZE, 0*SIZE) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(20)), 1 / Animation_Speed)
1479
            LeftHip.C0 = Clerp(LeftHip.C0, CF(-1*SIZE, -1*SIZE, 0*SIZE) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(10)), 1 / Animation_Speed)
1480
        end
1481
    elseif TORSOVELOCITY < 1 and HITFLOOR ~= nil then
1482
        ANIM = "Idle"
1483
        if ATTACK == false then
1484
            RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0 - 0.04 * SIN(SINE / 24)*SIZE, 0 + 0.04 * SIN(SINE / 12)*SIZE, 0 + 0.05*SIZE * COS(SINE / 12)) * ANGLES(RAD(0 - 2.5 * SIN(SINE / 12)), RAD(0 - 2.5 * SIN(SINE / 24)), RAD(0)), 1 / Animation_Speed)
1485
            Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1.1*SIZE) - 1)) * ANGLES(RAD(25 - 4 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed)
1486
            RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.25*SIZE, 0.2*SIZE, -0.5*SIZE) * ANGLES(RAD(35), RAD(-15 + 2.5 * SIN(SINE / 12)), RAD(-85 + 2.5 * SIN(SINE / 12))) * RIGHTSHOULDERC0, 1 / Animation_Speed)
1487
            LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.25*SIZE, 0.2*SIZE, -0.5*SIZE) * ANGLES(RAD(35), RAD(15 - 2.5 * SIN(SINE / 12)), RAD(85 - 2.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed)
1488
            RightHip.C0 = Clerp(RightHip.C0, CF(1*SIZE, -1*SIZE + 0.06 * SIN(SINE / 24) - 0.05*SIZE * COS(SINE / 12), -0.01*SIZE) * ANGLES(RAD(0 - 2.5 * SIN(SINE / 12)), RAD(75), RAD(0)) * ANGLES(RAD(-2 - 2.5 * SIN(SINE / 24)), RAD(0), RAD(0)), 1 / Animation_Speed)
1489
            LeftHip.C0 = Clerp(LeftHip.C0, CF(-1*SIZE, -1*SIZE - 0.06 * SIN(SINE / 24) - 0.05*SIZE * COS(SINE / 12), -0.01*SIZE) * ANGLES(RAD(0 - 2.5 * SIN(SINE / 12)), RAD(-75), RAD(0)) * ANGLES(RAD(-2 + 2.5 * SIN(SINE / 24)), RAD(0), RAD(0)), 1 / Animation_Speed)
1490
        end
1491
    elseif TORSOVELOCITY > 1 and HITFLOOR ~= nil then
1492
        ANIM = "Walk"
1493
        if ATTACK == false then
1494
            RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0*SIZE, 0*SIZE, -0.1*SIZE) * ANGLES(RAD(5), RAD(0), RAD(0)), 1 / Animation_Speed)
1495
            Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1.1*SIZE) - 1)) * ANGLES(RAD(15 - 1 * SIN(SINE / (WALKSPEEDVALUE / 2))), RAD(0), RAD(0)), 1/ Animation_Speed)
1496
            RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.25*SIZE, 0.5*SIZE, 0.5*SIZE) * ANGLES(RAD(-35), RAD(-25 + 2.5 * SIN(SINE / WALKSPEEDVALUE)), RAD(-55 + 2.5 * SIN(SINE / WALKSPEEDVALUE))) * RIGHTSHOULDERC0, 1 / Animation_Speed)
1497
            LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.25*SIZE, 0.5*SIZE, 0.5*SIZE) * ANGLES(RAD(-35), RAD(25 - 2.5 * SIN(SINE / WALKSPEEDVALUE)), RAD(55 - 2.5 * SIN(SINE / WALKSPEEDVALUE))) * LEFTSHOULDERC0, 1 / Animation_Speed)
1498
            RightHip.C0 = Clerp(RightHip.C0, CF(1*SIZE , -1*SIZE, 0*SIZE) * ANGLES(RAD(0), RAD(85), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 2 / Animation_Speed)
1499
            LeftHip.C0 = Clerp(LeftHip.C0, CF(-1*SIZE, -1*SIZE, 0*SIZE) * ANGLES(RAD(0), RAD(-85), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 2 / Animation_Speed)
1500
        end
1501
    end
1502
	unanchor()
1503
	Humanoid.MaxHealth = "inf"
1504
	Humanoid.Health = "inf"
1505
	if Rooted == false then
1506
		Disable_Jump = false
1507
		Humanoid.WalkSpeed = Speed
1508
	elseif Rooted == true then
1509
		Disable_Jump = true
1510
		Humanoid.WalkSpeed = 0
1511
	end
1512
	for _, c in pairs(Character:GetChildren()) do
1513
		if c.ClassName == "Part" and c.Name ~= "Eye" then
1514
			c.Material = "Neon"
1515
			if c:FindFirstChildOfClass("ParticleEmitter") then
1516
				c:FindFirstChildOfClass("ParticleEmitter"):remove()
1517
			end
1518
			c.Color = C3(1,1,1)
1519
			if c == Head then
1520
				if c:FindFirstChild("face") then
1521
					c.face:remove()
1522
				end
1523
			end
1524
		elseif c.ClassName == "CharacterMesh" or c.ClassName == "Accessory" or c.ClassName == "Hat" or c.Name == "Body Colors" then
1525
			c:remove()
1526
		elseif (c.ClassName == "Shirt" or c.ClassName == "Pants") and c.Name ~= "Cloth" then
1527
			c:remove()
1528
		end
1529
	end
1530
	sick.SoundId = "rbxassetid://1130685064"
1531
	sick.Looped = true
1532
	sick.Pitch = 1
1533
	sick.Volume = 10000
1534
	sick:Resume()
1535
	sick.Parent = Torso
1536
	refit()
1537
	if Head:FindFirstChildOfClass("Sound") then
1538
		Head:FindFirstChildOfClass("Sound"):remove()
1539
	end
1540
end
1541
1542
--//=================================\\
1543
--\\=================================//
1544
1545
1546
1547
1548
1549
--//====================================================\\--
1550
--||			  		 END OF SCRIPT
1551
--\\====================================================//--