View difference between Paste ID: W8tuvkVx and nxhgiEwz
SHOW: | | - or go back to the newest paste.
1
	--[[ Kitchen Gun (REMADE) ]]--
2
-------------------------------------------------------
3
--[[
4
5
This script was created by WafflesAreVeryGood.
6
ATTACKS
7
_______
8
9
10
--]]
11
-------------------------------------------------------
12
print("This script was created by WafflesAreVeryGood!")
13
	--[[Changeable Variables]]--
14
local multiplier = 1 --Attack multiplier (default is 1)
15
local soundlist = {
16
	HardHit1 = "",
17
	HardHit2 = "",
18
	HardHit3 = "",
19
	WeakHit1 = "",
20
	WeakHit2 = "",
21
	Slice1 = "",
22
	Slice2 = "",
23
	Explosion1 = "",
24
	Explosion2 = "",
25
	Woosh1 = "",
26
	Woosh2 = "",
27
	
28
}
29
local bgmusic = Instance.new("Sound")
30
bgmusic.Volume = 3.5
31
bgmusic.SoundId = ""
32
bgmusic.Looped = true
33
bgmusic.Parent = game:GetService('Players').LocalPlayer.Character.Torso
34
bgmusic:Play()
35
36
	--[[Important Variables]]--
37
local plr = game:GetService('Players').LocalPlayer
38
local char = plr.Character
39
local mouse = plr:GetMouse()
40
local input = game:GetService('UserInputService')
41
----
42
local joints = {"Right Shoulder", "Left Shoulder", "Right Hip", "Left Hip", "Neck", "RootJoint"}
43
local torso,head,rootpart = char.Torso,char.Head,char.HumanoidRootPart
44
local rs = torso["Right Shoulder"]
45
local ls = torso["Left Shoulder"]
46
local rh = torso["Right Hip"]
47
local lh = torso["Left Hip"]
48
local neck = torso.Neck
49
local rj = rootpart["RootJoint"]
50
local humanoid = char:FindFirstChildOfClass("Humanoid")
51
----
52
local huge = Vector3.new(math.huge, math.huge, math.huge)
53
local attacking = false
54
local cananim = true
55-
local currentanim = "Idle"
55+
local currentanim = ""
56
local mode = "Normal"
57
58
	--[[ Functions ]]--
59
function addattack(keycode, func)
60
	if keycode ~= "MouseClick" then
61
		input.InputBegan:connect(function(inp)
62
			if inp.KeyCode == keycode and not input:GetFocusedTextBox() then
63
				func()
64
			end
65
		end)
66
	else
67
		mouse.Button1Down:connect(function()
68
			func()
69
		end)
70
	end
71
end
72
function attackend(keycode, func)
73
	input.InputEnded:connect(function(inp)
74
		if inp.KeyCode == keycode and not input:GetFocusedTextBox() then
75
			func()
76
		end
77
	end)
78
end
79
function swait(t)
80
	if t then
81
		for i = 0, t do
82
			game:GetService('RunService').Stepped:wait(0)
83
		end
84
	else
85
		game:GetService('RunService').Stepped:wait(0)
86
	end
87
	return true
88
end
89
function fade(obj, dest, grow)
90
	spawn(function()
91
		local oldcf = obj.CFrame
92
		for i = 0, 10 do
93
			if grow then
94
				obj.Size = obj.Size +Vector3.new(1,1,1)
95
				obj.CFrame = oldcf
96
			end
97
			obj.Transparency = obj.Transparency +0.1
98
			swait()
99
		end
100
		if dest then
101
		obj:Destroy()
102
		end
103
	end)
104
end
105
function replacejoint(name)
106
	local j = torso:FindFirstChild(name)
107
	if not j then j = char.HumanoidRootPart:FindFirstChild(name) end
108
	if j then
109
		if true then
110
			local already = j.Parent:FindFirstChild(j.Name.." Replacement")
111
			local new = Instance.new("Weld")
112
			local c0 = j.C0
113
			local c1 = j.C1
114
			new.Part0 = j.Part0
115
			j.Part0 = nil
116
			new.Name = j.Name.." Replacement"
117
			if already then c0 = already.C0 c1 = already.C1 already:Destroy() end
118
			new.Parent = j.Parent
119
			new.Part1 = j.Part1
120
			new.C0 = c0
121
			new.C1 = c1
122
			return new
123
		end
124
	end
125
end
126
function removejoint(name, fast)
127
	local j = torso:FindFirstChild(name.." Replacement")
128
	if not j then j = char.HumanoidRootPart:FindFirstChild(name.." Replacement") end
129
	if j then
130
		local p0 = j.Part0
131
		if p0 ~= nil then
132
		local c0 = j.C0
133
		local c1 = j.C1
134
		j:Destroy()
135
		local new = p0:FindFirstChild(name)
136
		local ac0 = new.C0
137
		local ac1 = new.C1
138
		new.Part0 = p0
139
		new.C0 = c0
140
		new.C1 = c1
141
		spawn(function()
142
			if name ~= "RootJoint" then
143
			if not fast then
144
			for i = 0, 0.6, 0.1 do
145
				print(i)
146
				new.C0 = new.C0:Lerp(ac0, 0.5)
147
				new.C1 = new.C1:lerp(ac1, 0.5)
148
				swait()
149
			end
150
			else
151
				new.C0 = new.C0:Lerp(ac0, 1)
152
				new.C1 = new.C1:lerp(ac1, 1)
153
			end
154
			end
155
		end)
156
		end
157
	end
158
end
159
function fixalljoints(fast)
160
	for i,v in pairs({"Right Shoulder", "Left Shoulder", "Right Hip", "Left Hip",  "Neck", "RootJoint"}) do
161
		removejoint(v, fast)
162
	end
163
end
164
function getnewjoints()
165
	local rs = replacejoint("Right Shoulder")
166
	local ls = replacejoint("Left Shoulder")
167
	local rh = replacejoint("Right Hip")
168
	local lh = replacejoint("Left Hip")
169
	local neck = replacejoint("Neck")
170
	local rj = replacejoint("RootJoint")
171
	return rs,ls,rh,lh,neck,rj
172
end
173
function knockback(hit, force)
174
	local bv = Instance.new("BodyVelocity")
175
	bv.MaxForce = huge
176
	bv.Velocity = force
177
	bv.Parent = hit
178
	game:GetService('Debris'):AddItem(bv, 0.15)
179
end
180
function soundeffect(id, volume, speed, parent, forcewait)
181
	local func = function()
182
		local s = LoadLibrary("RbxUtility").Create("Sound")()
183
		s.Name = "SoundEffect"
184
		s.Volume = volume
185
		s.PlaybackSpeed = speed
186
		s.SoundId = id
187
		s.Looped = false
188
		s.Parent = parent
189
		s:Play()
190
		repeat wait() until not s.Playing
191
		s:Destroy()
192
	end
193
	if forcewait then
194
		func()
195
	else
196
		spawn(func)
197
	end
198
end
199
function specialsound(id, volume, speed, parent, starts, ends)
200
	local func = function()
201
		local s = LoadLibrary("RbxUtility").Create("Sound")()
202
		s.Name = "SoundEffect"
203
		s.Volume = volume
204
		s.PlaybackSpeed = speed
205
		s.SoundId = id
206
		s.TimePosition = starts
207
		s.Looped = false
208
		s.Parent = parent
209
		s:Play()
210
		repeat swait() until s.TimePosition >= ends
211
		s:Destroy()
212
	end
213
	spawn(func)
214
end
215
function hurt(hit, dmg)
216
	--pcall(function()
217
		local hum = hit.Parent:FindFirstChildOfClass("Humanoid")
218
		if hum then
219
			if hum.Parent ~= char and not hum.Parent:FindFirstChild("kk_urcool") then
220
				hum.Health = hum.Health - dmg
221
				return true
222
			end
223
		end
224
	--end)
225
end
226
function disable(hit)
227
	pcall(function()
228
		for i,v in pairs(hit.Parent:GetChildren()) do
229
			if v:IsA("Script") and v.Name ~= "Animate" then
230
				v:Destroy()
231
				soundeffect("rbxassetid://1132948877", 1, 1, char.Head)
232
			end
233
			if v:IsA("Model") then
234
				v:BreakJoints()
235
			end
236
			if v.Name ~= "Torso" and v.Name ~= "HumanoidRootPart" then
237
				for _,child in pairs(v:GetChildren()) do
238
					if child:IsA("Weld") then
239
						child:Destroy()
240
					end
241
				end
242
			end
243
		end
244
	end)
245
end
246
humanoid.Running:connect(function(speed)
247
	if speed > 2 then
248
		currentanim = "Walking"
249
	else
250
		currentanim = ""
251
	end
252
end)
253
humanoid.Jumping:connect(function(active)
254
	if active then
255
		currentanim = "Jumping"
256
	end
257
end)
258
humanoid.FallingDown:connect(function(active)
259
	if active then
260
		currentanim = "Falling"
261
	end
262
end)
263
humanoid.FreeFalling:connect(function(active)
264
	if active and char.HumanoidRootPart.Velocity.Y < 0 then
265
		currentanim = "Falling"
266
	end
267
end)
268
pcall(function()
269
	char.Animate:Destroy()
270
end)
271
for i,v in pairs(humanoid:GetPlayingAnimationTracks()) do
272
	v:Stop()
273
end
274
	--[[ Actual script :OOOOOOOOOO ]]--
275
local gun = Instance.new("Part")
276-
gun.Size = Vector3.new(1, 1, 2)
276+
gun.Size = Vector3.new(0, 0, 0)
277
gun.CanCollide = false
278
gun.Anchored = false
279
gun.Color = Color3.new(0,0,0)
280
local gunw = Instance.new("Weld")
281
gunw.Name = "GunWeld"
282
gunw.Part0 = gun
283-
gunw.Part1 = char["Right Arm"]
283+
gunw.Part1 = char["torso"]
284
gunw.C1 = CFrame.new(0,-1,-0.25) *CFrame.Angles(math.rad(270),math.rad(0),math.rad(0))
285
gunw.Parent = gun
286
local m = Instance.new("SpecialMesh")
287
m.MeshId = ""
288-
m.Scale = Vector3.new(1.2,1.2,1.2)
288+
m.Scale = Vector3.new(0,0,0)
289
m.Parent = gun
290
gun.Parent = char
291
292
addattack(Enum.KeyCode.R, function()
293
	if not attacking then
294
		if mode == "Normal" then
295
			mode = "Heal"
296
			gun.Color = Color3.new(0,1,0)
297
			specialsound("", 5, 1, char, 18.49549100592, 20.526269195994)
298
		else
299
			gun.Color = Color3.new(0,0,0)
300
			mode = "Normal"
301
			soundeffect("", 5, 1, char)
302
		end
303
	end
304
end)
305
addattack(Enum.KeyCode.Q, function()
306
	if not attacking then
307
		mode = "Disable"
308
		gun.Color = Color3.new(1,0,0)
309
		specialsound("", 5, 1, char, 33.878067323327, 35.438444041738)
310
	end
311
end)
312
addattack(Enum.KeyCode.P, function()
313
	if bgmusic.Playing then
314
		bgmusic:Stop()
315
	else
316
		bgmusic:Play()
317
	end
318
end)
319
addattack("MouseClick", function()
320
	if not attacking then
321
		cananim = false
322
		attacking = true
323
		for i = 0, 0.6, 0.1 do
324
		rs.C0 = rs.C0:Lerp(CFrame.new(1, 0.5, 0, -4.37113883e-08, 0, 1, -0, 0.99999994, 0, -1, 0, -4.37113883e-08), 0.6)
325
		rs.C1 = rs.C1:Lerp(CFrame.new(-0.235909924, 0.846874475, 0, 0.399310559, 0.00480417395, 0.916803062, -0.916736782, -0.0110294167, 0.399339437, 0.0120302998, -0.99992764, 5.25861077e-10), 0.6)
326
		ls.C0 = ls.C0:Lerp(CFrame.new(-1, 0.5, 0, -4.37113883e-08, 0, -1, 0, 0.99999994, 0, 1, 0, -4.37113883e-08), 0.6)
327
		ls.C1 = ls.C1:Lerp(CFrame.new(0.232030958, 1.28329468, 0, 0.758646905, 0.0105680302, -0.651416421, 0.65135318, 0.00907341763, 0.758720517, 0.0139287533, -0.999902964, -6.08845141e-10), 0.6)
328
		rh.C0 = rh.C0:Lerp(CFrame.new(1, -1, 0, -4.37113883e-08, 0, 1, -0, 0.99999994, 0, -1, 0, -4.37113883e-08), 0.6)
329
		rh.C1 = rh.C1:Lerp(CFrame.new(0.5, 1, 0, -4.37113883e-08, 0, 1, 0, 1, 0, -1, 0, -4.37113883e-08), 0.6)
330
		lh.C0 = lh.C0:Lerp(CFrame.new(-1, -1, 0, -4.37113883e-08, 0, -1, 0, 0.99999994, 0, 1, 0, -4.37113883e-08), 0.6)
331
		lh.C1 = lh.C1:Lerp(CFrame.new(-0.5, 1, 0, -4.37113883e-08, 0, -1, 0, 1, 0, 1, 0, -4.37113883e-08), 0.6)
332
		neck.C0 = neck.C0:Lerp(CFrame.new(0, 1, 0, -1, 0, 0, 0, 0, 1, 0, 1, -0), 0.6)
333
		neck.C1 = neck.C1:Lerp(CFrame.new(0, -0.5, 0, -1, 0, 0, 0, 0, 1, 0, 1, -0), 0.6)
334
		rj.C0 = rj.C0:Lerp(CFrame.new(0, 0, 0, -1, 0, 0, 0, 0, 1, 0, 1, -0), 0.6)
335
		rj.C1 = rj.C1:Lerp(CFrame.new(0, 0, 0, -1, 0, 0, 0, 0, 1, 0, 1, -0), 0.6)
336
		swait()
337
		end
338
		local sounds = {
339
			{};
340
			{};
341
			{};
342
		}
343
		local ids = sounds[math.random(#sounds)]
344
		specialsound("", 5, 1, char, ids[1], ids[2])
345
		local p = Instance.new("Part")
346
		p.Anchored = false
347
		p.Material = "Neon"
348
		p.CanCollide = false
349
		local start = gun.Position +Vector3.new(0.5,0,-0.5)
350
		local endp = mouse.Hit.p
351
		local ray = Ray.new(start, (endp-start).unit * 999)
352
		local hit,position = workspace:FindPartOnRayWithIgnoreList(ray, {char, gun})
353
		local mag = (start-position).magnitude + 2
354
		p.Size = Vector3.new(0.1,0.1,mag)
355
		p.CFrame = CFrame.new(start, position) *CFrame.new(0,0,-mag/2)
356
		local bp = Instance.new("BodyPosition")
357
		bp.MaxForce = huge
358
		bp.Position = p.Position
359
		bp.Parent = p
360
		p.Color = gun.Color
361
		if mode == "Normal" then
362
			p.Color = Color3.new(1,1,1)
363
		end
364
		p.Parent = workspace
365
		spawn(function()
366
			for i = 1, 10 do
367
				p.Transparency = i/10
368
				swait()
369
			end
370
			p:Destroy()
371
		end)
372
		local con
373
		local dmg = 750000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
374
		if mode == "Heal" then dmg = -750000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000 end
375
		if mode == "Disable" then dmg = 0 end
376
		con = p.Touched:connect(function(hit)
377
			if hurt(hit, dmg) then
378
				pcall(function()
379
					con:disconnect()
380
					if mode == "Disable" then
381
						disable(hit)
382
					end
383
					for i,v in pairs(hit.Parent:GetDescendants()) do
384
						spawn(function()
385
							if v:IsA("BasePart") and mode == "Normal" then
386
								local bv = Instance.new("BodyVelocity")
387
								bv.MaxForce = huge
388
								bv.Velocity = CFrame.new(start, position).lookVector*100
389
								bv.Parent = v
390
								game:GetService('Debris'):AddItem(bv, 0.1)
391
								if v.Transparency <= 0.9 then
392
									for i = 1, 20 do
393
										v.Transparency = i/20
394
										swait()
395
									end
396
								end
397
								v:Destroy()
398
							end
399
						end)
400
					end
401
				end)
402
			end
403
		end)
404
		for i = 0, 0.3, 0.1 do
405
		rs.C0 = rs.C0:Lerp(CFrame.new(1, 0.5, 0, -4.37113883e-08, 0, 1, -0, 0.99999994, 0, -1, 0, -4.37113883e-08), 0.8)
406
		rs.C1 = rs.C1:Lerp(CFrame.new(-0.108213484, 0.142491132, -0.0458124876, 0.399310559, 0.00480417395, 0.916803062, -0.907117367, -0.142995536, 0.395841271, 0.133000448, -0.989711702, -0.0527416691), 0.8)
407
		ls.C0 = ls.C0:Lerp(CFrame.new(-1, 0.5, 0, -4.37113883e-08, 0, -1, 0, 0.99999994, 0, 1, 0, -4.37113883e-08), 0.8)
408
		ls.C1 = ls.C1:Lerp(CFrame.new(-0.214841455, 0.866598129, -0.112976491, 0.758646905, 0.0105680302, -0.651416421, 0.64655149, -0.135239884, 0.750787199, -0.0801631361, -0.990756512, -0.109432101), 0.8)
409
		rh.C0 = rh.C0:Lerp(CFrame.new(1, -1, 0, -4.37113883e-08, 0, 1, -0, 0.99999994, 0, -1, 0, -4.37113883e-08), 0.8)
410
		rh.C1 = rh.C1:Lerp(CFrame.new(0.5, 1, 0, -4.37113883e-08, 0, 1, -0.104150683, 0.994561553, -4.55257076e-09, -0.994561553, -0.104150683, -4.34736656e-08), 0.8)
411
		lh.C0 = lh.C0:Lerp(CFrame.new(-1, -1, 0, -4.37113883e-08, 0, -1, 0, 0.99999994, 0, 1, 0, -4.37113883e-08), 0.8)
412
		lh.C1 = lh.C1:Lerp(CFrame.new(-0.5, 1, 0, -4.37113883e-08, 0, -1, -0.0883838907, 0.996086478, 3.8633825e-09, 0.996086478, 0.0883838907, -4.35403216e-08), 0.8)
413
		neck.C0 = neck.C0:Lerp(CFrame.new(0, 1, 0, -1, 0, 0, 0, 0, 1, 0, 1, -0), 0.8)
414
		neck.C1 = neck.C1:Lerp(CFrame.new(0, -0.49999997, 0, -1, 0, 0, 0, 0.0492738597, 0.998785317, 0, 0.998785317, -0.0492738597), 0.8)
415
		rj.C0 = rj.C0:Lerp(CFrame.new(0, 0, 0, -1, 0, 0, 0, 0, 1, 0, 1, -0), 0.8)
416
		rj.C1 = rj.C1:Lerp(CFrame.new(0, 0, 0, -1, 0, 0, 0, 0.0276213959, 0.999618471, 0, 0.999618471, -0.0276213959), 0.8)
417
		swait()
418
		end
419
		cananim = true
420
		attacking = false
421
	end
422
end)
423
while true do
424
	swait()
425
	if currentanim == "Jumping" and cananim then
426
for i = 0, 1.2, 0.1 do
427
if currentanim ~= "Jumping" or not cananim then break end
428
rs.C0 = rs.C0:Lerp(CFrame.new(1, 0.5, 0, -4.37113883e-08, 0, 1, -0, 0.99999994, 0, -1, 0, -4.37113883e-08), 0.4)
429
rs.C1 = rs.C1:Lerp(CFrame.new(0.0997244716, 0.195344329, -0.746855855, -0.155881107, 0.00388455181, 0.987768173, 0.260807574, -0.964343727, 0.0449508503, 0.952722609, 0.264624417, 0.149309859), 0.4)
430
ls.C0 = ls.C0:Lerp(CFrame.new(-1, 0.5, 0, -4.37113883e-08, 0, -1, 0, 0.99999994, 0, 1, 0, -4.37113883e-08), 0.4)
431
ls.C1 = ls.C1:Lerp(CFrame.new(0.793125331, 0.89348793, -0.0677016973, 0.986068428, -0.132806748, -0.100156575, 0.1031176, 0.0155911446, 0.994546831, -0.130520999, -0.991019309, 0.0290686507), 0.4)
432
rh.C0 = rh.C0:Lerp(CFrame.new(1, -1, 0, -4.37113883e-08, 0, 1, -0, 0.99999994, 0, -1, 0, -4.37113883e-08), 0.4)
433
rh.C1 = rh.C1:Lerp(CFrame.new(0.49999997, 0.99999994, -4.47034836e-08, -0.0421661586, 0.0827250704, 0.995679915, 0.25110203, 0.965456486, -0.0695800334, -0.967041731, 0.247083336, -0.0614820197), 0.4)
434
lh.C0 = lh.C0:Lerp(CFrame.new(-1, -1, 0, -4.37113883e-08, 0, -1, 0, 0.99999994, 0, 1, 0, -4.37113883e-08), 0.4)
435
lh.C1 = lh.C1:Lerp(CFrame.new(-0.49999997, 1, 2.98023224e-08, 0.0194152314, 0, -0.99981153, 0.178683311, 0.983900607, 0.00346983178, 0.983715117, -0.178716987, 0.0191026554), 0.4)
436
neck.C0 = neck.C0:Lerp(CFrame.new(0, 1, 0, -1, 0, 0, 0, 0, 1, 0, 1, 0), 0.4)
437
neck.C1 = neck.C1:Lerp(CFrame.new(0, -0.5, 0, -1, 0, 0, 0, 0.0515226237, 0.99867183, 0, 0.99867183, -0.0515226237), 0.4)
438
rj.C0 = rj.C0:Lerp(CFrame.new(0, 0, 0, -1, 0, 0, 0, 0, 1, 0, 1, 0), 0.4)
439
rj.C1 = rj.C1:Lerp(CFrame.new(0, 0.128909558, -0.0269506648, -0.996639967, -0.0819067881, 0, -0.00100739487, 0.0122579783, 0.999924421, -0.0819005966, 0.996564567, -0.0122992992), 0.4)
440
swait()
441
end
442
	end
443
	if currentanim == "Falling" and cananim then
444
for i = 0, 1.2, 0.1 do
445
if currentanim ~= "Falling" or not cananim then break end
446
rs.C0 = rs.C0:Lerp(CFrame.new(1, 0.5, 0, -4.37113883e-08, 0, 1, -0, 0.99999994, 0, -1, 0, -4.37113883e-08), 0.4)
447
rs.C1 = rs.C1:Lerp(CFrame.new(0.0997244716, 0.389569163, -0.799008012, -0.155881107, 0.00388455181, 0.987768173, 0.0170185864, -0.999833226, 0.00661772862, 0.987629175, 0.0178419873, 0.155789018), 0.4)
448
ls.C0 = ls.C0:Lerp(CFrame.new(-1, 0.5, 0, -4.37113883e-08, 0, -1, 0, 0.99999994, 0, 1, 0, -4.37113883e-08), 0.4)
449
ls.C1 = ls.C1:Lerp(CFrame.new(0.800841689, 0.89348793, 0.000534057617, 0.989977896, 0.0953866094, -0.104139231, 0.1031176, 0.0155911446, 0.994546831, 0.0964901, -0.995318174, 0.00559884822), 0.4)
450
rh.C0 = rh.C0:Lerp(CFrame.new(1, -1, 0, -4.37113883e-08, 0, 1, -0, 0.99999994, 0, -1, 0, -4.37113883e-08), 0.4)
451
rh.C1 = rh.C1:Lerp(CFrame.new(0.49999997, 1, -1.49011612e-08, -0.0421661586, 0.0827250704, 0.995679915, -0.0600035824, 0.994557679, -0.085172914, -0.997307122, -0.0633357614, -0.0369728766), 0.4)
452
lh.C0 = lh.C0:Lerp(CFrame.new(-1, -1, 0, -4.37113883e-08, 0, -1, 0, 0.99999994, 0, 1, 0, -4.37113883e-08), 0.4)
453
lh.C1 = lh.C1:Lerp(CFrame.new(-0.499999881, 1, 3.7252903e-08, 0.0207479522, -0.155918092, -0.987552047, -0.00691960612, 0.987718761, -0.156089753, 0.999760866, 0.0100720376, 0.0194142479), 0.4)
454
neck.C0 = neck.C0:Lerp(CFrame.new(0, 1, 0, -1, 0, 0, 0, 0, 1, 0, 1, 0), 0.4)
455
neck.C1 = neck.C1:Lerp(CFrame.new(0, -0.5, 0, -1, 0, 0, 0, 0.0515226237, 0.99867183, 0, 0.99867183, -0.0515226237), 0.4)
456
rj.C0 = rj.C0:Lerp(CFrame.new(0, 0, 0, -1, 0, 0, 0, 0, 1, 0, 1, 0), 0.4)
457
rj.C1 = rj.C1:Lerp(CFrame.new(0, 0.313415587, -0.0163925812, -0.996639967, -0.0819067881, 0, 0.00564728118, -0.0687159598, 0.997620344, -0.0817118809, 0.994268239, 0.068947643), 0.4)
458
swait()
459
end
460
	end
461
	if currentanim == "" and cananim then
462
for i = 0, 0.6, 0.1 do
463
if currentanim ~= "" or not cananim then break end
464
rs.C0 = rs.C0:Lerp(CFrame.new(1, 0.5, 0, -4.37113883e-08, 0, 1, -0, 0.99999994, 0, -1, 0, -4.37113883e-08), 0.6)
465
rs.C1 = rs.C1:Lerp(CFrame.new(0.0997244716, -0.134959042, -0.791477084, -0.155881107, 0.00388455181, 0.987768173, 0.0728884861, -0.997220755, 0.0154243633, 0.985082865, 0.0744013041, 0.155164748), 0.6)
466
ls.C0 = ls.C0:Lerp(CFrame.new(-1, 0.5, 0, -4.37113883e-08, 0, -1, 0, 0.99999994, 0, 1, 0, -4.37113883e-08), 0.6)
467
ls.C1 = ls.C1:Lerp(CFrame.new(0.728777826, 0.934069037, -0.221951187, 0.958276987, -0.133620545, -0.252687156, 0.254302055, -0.00512516592, 0.96711117, -0.130520999, -0.991019309, 0.0290686507), 0.6)
468
rh.C0 = rh.C0:Lerp(CFrame.new(1, -1, 0, -4.37113883e-08, 0, 1, -0, 0.99999994, 0, -1, 0, -4.37113883e-08), 0.6)
469
rh.C1 = rh.C1:Lerp(CFrame.new(0.49999997, 1, 0, -0.0421661586, 0.0827250704, 0.995679915, -0.568820775, 0.817300439, -0.0919936299, -0.82137984, -0.570242465, 0.0125933159), 0.6)
470
lh.C0 = lh.C0:Lerp(CFrame.new(-1, -1, 0, -4.37113883e-08, 0, -1, 0, 0.99999994, 0, 1, 0, -4.37113883e-08), 0.6)
471
lh.C1 = lh.C1:Lerp(CFrame.new(-0.49999997, 1, 0, 0.0194152314, 0, -0.99981153, -0.845399499, 0.53388226, -0.0164167192, 0.533781588, 0.845558882, 0.0103654461), 0.6)
472
neck.C0 = neck.C0:Lerp(CFrame.new(0, 1, 0, -1, 0, 0, 0, 0, 1, 0, 1, 0), 0.6)
473
neck.C1 = neck.C1:Lerp(CFrame.new(0, -0.5, 0, -1, 0, 0, 0, 0.0515226237, 0.99867183, 0, 0.99867183, -0.0515226237), 0.6)
474
rj.C0 = rj.C0:Lerp(CFrame.new(0, 0, 0, -1, 0, 0, 0, 0, 1, 0, 1, 0), 0.6)
475
rj.C1 = rj.C1:Lerp(CFrame.new(0, 0.239933819, 0, -0.996639967, -0.0819067881, 0, 0.00819849782, -0.0997591168, 0.994977891, -0.0814954415, 0.991634667, 0.100095451), 0.6)
476
swait()
477
end
478
local rslastc0 = rs.C0
479
local rslastc1 = rs.C1
480
local lslastc0 = ls.C0
481
local lslastc1 = ls.C1
482
local rhlastc0 = rh.C0
483
local rhlastc1 = rh.C1
484
local lhlastc0 = lh.C0
485
local lhlastc1 = lh.C1
486
local necklastc0 = neck.C0
487
local necklastc1 = neck.C1
488
local rjlastc0 = rj.C0
489
local rjlastc1 = rj.C1
490
local max = 0.6
491
for i = 0, max, 0.1 do
492
if currentanim ~= "" or not cananim then break end
493
rs.C0 = rslastc0:Lerp(CFrame.new(1, 0.5, 0, -4.37113883e-08, 0, 1, -0, 0.99999994, 0, -1, 0, -4.37113883e-08), i/max)
494
rs.C1 = rslastc1:Lerp(CFrame.new(0.0997244716, -0.134959042, -0.791477084, -0.155881107, 0.00388455181, 0.987768173, 0.0728884861, -0.997220755, 0.0154243633, 0.985082865, 0.0744013041, 0.155164748), i/max)
495
ls.C0 = lslastc0:Lerp(CFrame.new(-1, 0.5, 0, -4.37113883e-08, 0, -1, 0, 0.99999994, 0, 1, 0, -4.37113883e-08), i/max)
496
ls.C1 = lslastc1:Lerp(CFrame.new(0.728777826, 0.934069037, -0.221951187, 0.958276987, -0.133620545, -0.252687156, 0.254302055, -0.00512516592, 0.96711117, -0.130520999, -0.991019309, 0.0290686507), i/max)
497
rh.C0 = rhlastc0:Lerp(CFrame.new(1, -1, 0, -4.37113883e-08, 0, 1, -0, 0.99999994, 0, -1, 0, -4.37113883e-08), i/max)
498
rh.C1 = rhlastc1:Lerp(CFrame.new(0.5, 0.675323606, 0, -0.0421661623, 0.0827250704, 0.995679975, 0.221647412, 0.972508371, -0.0714133158, -0.974214792, 0.217678651, -0.059342742), i/max)
499
lh.C0 = lhlastc0:Lerp(CFrame.new(-1, -1, 0, -4.37113883e-08, 0, -1, 0, 0.99999994, 0, 1, 0, -4.37113883e-08), i/max)
500
lh.C1 = lhlastc1:Lerp(CFrame.new(-0.49999997, 0.680277288, -1.49011612e-08, 0.0194152296, -2.24613939e-11, -0.99981153, -0.183868393, 0.982944369, -0.00357052009, 0.982759118, 0.183903053, 0.0190840904), i/max)
501
neck.C0 = necklastc0:Lerp(CFrame.new(0, 1, 0, -1, 0, 0, 0, 0, 1, 0, 1, 0), i/max)
502
neck.C1 = necklastc1:Lerp(CFrame.new(0, -0.5, 0, -1, 0, 0, 0, 0.0515226237, 0.99867183, 0, 0.99867183, -0.0515226237), i/max)
503
rj.C0 = rjlastc0:Lerp(CFrame.new(0, 0, 0, -1, 0, 0, 0, 0, 1, 0, 1, 0), i/max)
504
rj.C1 = rjlastc1:Lerp(CFrame.new(0, 0.169720784, 0, -0.996639967, -0.0819067881, 0, 0.00819849782, -0.0997591168, 0.994977891, -0.0814954415, 0.991634667, 0.100095451), i/max)
505
swait()
506
end
507
for i = 0, 0.6, 0.1 do
508
if currentanim ~= "Walking" or not cananim then break end
509
rs.C0 = rs.C0:Lerp(CFrame.new(1, 0.5, 0, -4.37113883e-08, 0, 1, -0, 0.99999994, 0, -1, 0, -4.37113883e-08), 0.6)
510
rs.C1 = rs.C1:Lerp(CFrame.new(0.0997244716, -0.134959042, -0.791477084, -0.155881107, 0.00388455181, 0.987768173, 0.0728884861, -0.997220755, 0.0154243633, 0.985082865, 0.0744013041, 0.155164748), 0.6)
511
ls.C0 = ls.C0:Lerp(CFrame.new(-1, 0.5, 0, -4.37113883e-08, 0, -1, 0, 0.99999994, 0, 1, 0, -4.37113883e-08), 0.6)
512
ls.C1 = ls.C1:Lerp(CFrame.new(0.728777826, 0.934069037, -0.221951187, 0.958276987, -0.133620545, -0.252687156, 0.254302055, -0.00512516592, 0.96711117, -0.130520999, -0.991019309, 0.0290686507), 0.6)
513
rh.C0 = rh.C0:Lerp(CFrame.new(1, -1, 0, -4.37113883e-08, 0, 1, -0, 0.99999994, 0, -1, 0, -4.37113883e-08), 0.6)
514
rh.C1 = rh.C1:Lerp(CFrame.new(0.49999997, 1, 0, -0.0421661586, 0.0827250704, 0.995679915, 0.868188143, 0.496215105, -0.00446053827, -0.494440407, 0.864249468, -0.0927444026), 0.6)
515
lh.C0 = lh.C0:Lerp(CFrame.new(-1, -1, 0, -4.37113883e-08, 0, -1, 0, 0.99999994, 0, 1, 0, -4.37113883e-08), 0.6)
516
lh.C1 = lh.C1:Lerp(CFrame.new(-0.49999997, 1, 0, 0.0194152314, 0, -0.99981153, 0.595236421, 0.803467572, 0.0115588298, 0.803316057, -0.595348656, 0.015599506), 0.6)
517
neck.C0 = neck.C0:Lerp(CFrame.new(0, 1, 0, -1, 0, 0, 0, 0, 1, 0, 1, 0), 0.6)
518
neck.C1 = neck.C1:Lerp(CFrame.new(0, -0.5, 0, -1, 0, 0, 0, 0.0515226237, 0.99867183, 0, 0.99867183, -0.0515226237), 0.6)
519
rj.C0 = rj.C0:Lerp(CFrame.new(0, 0, 0, -1, 0, 0, 0, 0, 1, 0, 1, 0), 0.6)
520
rj.C1 = rj.C1:Lerp(CFrame.new(0, 0.342528641, -9.31322575e-10, -0.996639967, -0.0819067955, -6.22866592e-10, 0.00819849595, -0.0997591242, 0.994977832, -0.0814954415, 0.991634727, 0.100095443), 0.6)
521
swait()
522
end
523
local rslastc0 = rs.C0
524
local rslastc1 = rs.C1
525
local lslastc0 = ls.C0
526
local lslastc1 = ls.C1
527
local rhlastc0 = rh.C0
528
local rhlastc1 = rh.C1
529
local lhlastc0 = lh.C0
530
local lhlastc1 = lh.C1
531
local necklastc0 = neck.C0
532
local necklastc1 = neck.C1
533
local rjlastc0 = rj.C0
534
local rjlastc1 = rj.C1
535
local max = 0.6
536
for i = 0, max, 0.1 do
537
if currentanim ~= "Walking" or not cananim then break end
538
rs.C0 = rslastc0:Lerp(CFrame.new(1, 0.5, 0, -4.37113883e-08, 0, 1, -0, 0.99999994, 0, -1, 0, -4.37113883e-08), i/max)
539
rs.C1 = rslastc1:Lerp(CFrame.new(0.0997244716, -0.134959042, -0.791477084, -0.155881107, 0.00388455181, 0.987768173, 0.0728884861, -0.997220755, 0.0154243633, 0.985082865, 0.0744013041, 0.155164748), i/max)
540
ls.C0 = lslastc0:Lerp(CFrame.new(-1, 0.5, 0, -4.37113883e-08, 0, -1, 0, 0.99999994, 0, 1, 0, -4.37113883e-08), i/max)
541
ls.C1 = lslastc1:Lerp(CFrame.new(0.728777826, 0.934069037, -0.221951187, 0.958276987, -0.133620545, -0.252687156, 0.254302055, -0.00512516592, 0.96711117, -0.130520999, -0.991019309, 0.0290686507), i/max)
542
rh.C0 = rhlastc0:Lerp(CFrame.new(1, -1, 0, -4.37113883e-08, 0, 1, -0, 0.99999994, 0, -1, 0, -4.37113883e-08), i/max)
543
rh.C1 = rhlastc1:Lerp(CFrame.new(0.5, 0.675323606, 0, -0.0421661623, 0.0827250704, 0.995679975, 0.221647412, 0.972508371, -0.0714133158, -0.974214792, 0.217678651, -0.059342742), i/max)
544
lh.C0 = lhlastc0:Lerp(CFrame.new(-1, -1, 0, -4.37113883e-08, 0, -1, 0, 0.99999994, 0, 1, 0, -4.37113883e-08), i/max)
545
lh.C1 = lhlastc1:Lerp(CFrame.new(-0.49999997, 0.680277288, -1.49011612e-08, 0.0194152296, -2.24613939e-11, -0.99981153, -0.183868393, 0.982944369, -0.00357052009, 0.982759118, 0.183903053, 0.0190840904), i/max)
546
neck.C0 = necklastc0:Lerp(CFrame.new(0, 1, 0, -1, 0, 0, 0, 0, 1, 0, 1, 0), i/max)
547
neck.C1 = necklastc1:Lerp(CFrame.new(0, -0.5, 0, -1, 0, 0, 0, 0.0515226237, 0.99867183, 0, 0.99867183, -0.0515226237), i/max)
548
rj.C0 = rjlastc0:Lerp(CFrame.new(0, 0, 0, -1, 0, 0, 0, 0, 1, 0, 1, 0), i/max)
549
rj.C1 = rjlastc1:Lerp(CFrame.new(5.82076609e-11, 0.2270886, 2.32830644e-10, -0.996639967, -0.0819067881, 4.13409307e-10, 0.00819849502, -0.0997591093, 0.994977832, -0.081495434, 0.991634727, 0.100095429), i/max)
550
wait()
551
end
552
	end
553
	if currentanim == "" and cananim then
554
		for i = 0, 5, 0.1 do
555
		if currentanim ~= "" or not cananim then break end
556
		rs.C0 = rs.C0:Lerp(CFrame.new(1, 0.5, 0, -4.37113883e-08, 0, 1, -0, 0.99999994, 0, -1, 0, -4.37113883e-08), 0.05)
557
		rs.C1 = rs.C1:Lerp(CFrame.new(0.0997244716, -0.105339587, -1.12973166, -0.155881107, 0.00388455181, 0.987768173, -0.0249122381, -0.999689579, -1.08894849e-09, 0.987461567, -0.0246075168, 0.155929506), 0.05)
558
		ls.C0 = ls.C0:Lerp(CFrame.new(-1, 0.5, 0, -4.37113883e-08, 0, -1, 0, 0.99999994, 0, 1, 0, -4.37113883e-08), 0.05)
559
		ls.C1 = ls.C1:Lerp(CFrame.new(0.998242438, 0.966719627, -0.251513988, 0.948773444, -0.0191214401, -0.315378129, 0.315314144, -0.00635479437, 0.948966026, -0.0201497618, -0.999796987, 8.80774065e-10), 0.05)
560
		rh.C0 = rh.C0:Lerp(CFrame.new(1, -1, 0, -4.37113883e-08, 0, 1, -0, 0.99999994, 0, -1, 0, -4.37113883e-08), 0.05)
561
		rh.C1 = rh.C1:Lerp(CFrame.new(0.5, 1, 0, -0.246849835, 0, 0.969053745, 0, 1, 0, -0.969053745, 0, -0.246849835), 0.05)
562
		lh.C0 = lh.C0:Lerp(CFrame.new(-1, -1, 0, -4.37113883e-08, 0, -1, 0, 0.99999994, 0, 1, 0, -4.37113883e-08), 0.05)
563
		lh.C1 = lh.C1:Lerp(CFrame.new(-0.5, 1, 0, 0.0194152314, 0, -0.99981153, 0, 1, 0, 0.99981153, 0, 0.0194152314), 0.05)
564
		neck.C0 = neck.C0:Lerp(CFrame.new(0, 1, 0, -1, 0, 0, 0, 0, 1, 0, 1, 0), 0.05)
565
		neck.C1 = neck.C1:Lerp(CFrame.new(0, -0.5, 0, -1, 0, 0, 0, 0, 1, 0, 1, 0), 0.05)
566
		rj.C0 = rj.C0:Lerp(CFrame.new(0, 0, 0, -1, 0, 0, 0, 0, 1, 0, 1, 0), 0.05)
567
		rj.C1 = rj.C1:Lerp(CFrame.new(0, 0, 0, -0.996639967, -0.0819067881, 0, 0, 0, 1, -0.0819067881, 0.996639967, 0), 0.05)
568
		swait()
569
		end
570
		for i = 0, 5, 0.1 do
571
		if currentanim ~= "" or not cananim then break end
572
		rs.C0 = rs.C0:Lerp(CFrame.new(1, 0.5, 0, -4.37113883e-08, 0, 1, -0, 0.99999994, 0, -1, 0, -4.37113883e-08), 0.05)
573
		rs.C1 = rs.C1:Lerp(CFrame.new(0.0997244716, -0.134959042, -1.07218063, -0.155881107, 0.00388455181, 0.987768173, 0.0728884861, -0.997220755, 0.0154243633, 0.985082865, 0.0744013041, 0.155164748), 0.05)
574
		ls.C0 = ls.C0:Lerp(CFrame.new(-1, 0.5, 0, -4.37113883e-08, 0, -1, 0, 0.99999994, 0, 1, 0, -4.37113883e-08), 0.05)
575
		ls.C1 = ls.C1:Lerp(CFrame.new(0.994734883, 0.934069037, -0.221951187, 0.958276987, -0.133620545, -0.252687156, 0.254302055, -0.00512516592, 0.96711117, -0.130520999, -0.991019309, 0.0290686507), 0.05)
576
		rh.C0 = rh.C0:Lerp(CFrame.new(1, -1, 0, -4.37113883e-08, 0, 1, -0, 0.99999994, 0, -1, 0, -4.37113883e-08), 0.05)
577
		rh.C1 = rh.C1:Lerp(CFrame.new(0.5, 1, 0, -0.246849835, 0, 0.969053745, 0, 1, 0, -0.969053745, 0, -0.246849835), 0.05)
578
		lh.C0 = lh.C0:Lerp(CFrame.new(-1, -1, 0, -4.37113883e-08, 0, -1, 0, 0.99999994, 0, 1, 0, -4.37113883e-08), 0.05)
579
		lh.C1 = lh.C1:Lerp(CFrame.new(-0.49999997, 1, 0, 0.0194152314, 0, -0.99981153, 0, 1, 0, 0.99981153, 0, 0.0194152314), 0.05)
580
		neck.C0 = neck.C0:Lerp(CFrame.new(0, 1, 0, -1, 0, 0, 0, 0, 1, 0, 1, 0), 0.05)
581
		neck.C1 = neck.C1:Lerp(CFrame.new(0, -0.5, 0, -1, 0, 0, 0, 0, 1, 0, 1, 0), 0.05)
582
		rj.C0 = rj.C0:Lerp(CFrame.new(0, 0, 0, -1, 0, 0, 0, 0, 1, 0, 1, 0), 0.05)
583
		rj.C1 = rj.C1:Lerp(CFrame.new(0, 0, 0, -0.996639967, -0.0819067881, 0, -0.00139390712, 0.0169610307, 0.999855161, -0.0818949267, 0.996495605, -0.017018212), 0.05)
584
		swait()
585
		end
586
	end
587
end