View difference between Paste ID: jpmgTPPy and nujVwAah
SHOW: | | - or go back to the newest paste.
1
print([[
2
___________________________________
3
  
4
Kyutatsuki13's アマツミカ·スタライト script
5
Build 0003
6
Amatsumika Starlight the Kami of Stars
7
Crystal5241 custom edit
8
9
___________________________________
10
]])
11
12
13
warn("You're whitelisted, "..game:GetService("Players").LocalPlayer.Name.." :)")
14
15
local p = game:GetService("Players").LocalPlayer
16
local plr = game:GetService("Players").LocalPlayer
17
local player = game:GetService("Players").LocalPlayer
18
local char = p.Character
19
local mouse = p:GetMouse()
20
local larm = char:WaitForChild("Left Arm")
21
local rarm = char:WaitForChild("Right Arm")
22
local lleg = char:WaitForChild("Left Leg")
23
local rleg = char:WaitForChild("Right Leg")
24
local hed = char:WaitForChild("Head")
25
local torso = char:WaitForChild("Torso")
26
local root = char:WaitForChild("HumanoidRootPart")
27
local hum = char:FindFirstChildOfClass("Humanoid")
28
local debris = game:GetService("Debris")
29
local run = game:GetService("RunService")
30
local rs = run.RenderStepped
31
local cam = workspace.CurrentCamera
32
local movement = 4
33
local change = 0.4
34
local DebrisModel = Instance.new("Model",char)
35
local stealth = false
36
local debounce = false
37
hum.MaxHealth = 50000
38
hum.Health = hum.MaxHealth
39
themeid = 556122490
40
themepitch = 1
41
main = {r = 51;g = 255;b = 153;v = 1}
42
if p:FindFirstChild("rcolor") then main.r = p.rcolor.Value else local string = Instance.new("StringValue",p) string.Name = "rcolor" end
43
if p:FindFirstChild("gcolor") then main.g = p.gcolor.Value else local string = Instance.new("StringValue",p) string.Name = "gcolor" end
44
if p:FindFirstChild("bcolor") then main.b = p.bcolor.Value else local string = Instance.new("StringValue",p) string.Name = "bcolor" end
45
if p:FindFirstChild("vcolor") then main.v = p.vcolor.Value else local string = Instance.new("StringValue",p) string.Name = "vcolor" end
46
if p:FindFirstChild("idtheme") then themeid = p.idtheme.Value else local string = Instance.new("StringValue",p) string.Name = "idtheme" end
47
if p:FindFirstChild("pitchtheme") then themepitch = p.pitchtheme.Value else local string = Instance.new("StringValue",p) string.Name = "pitchtheme" end
48
pr = p:FindFirstChild("rcolor")
49
pg = p:FindFirstChild("gcolor")
50
pb = p:FindFirstChild("bcolor")
51
pv = p:FindFirstChild("vcolor")
52
idth = p:FindFirstChild("idtheme")
53
pith = p:FindFirstChild("pitchtheme")
54
main_color = Color3.fromRGB(main.r,main.g,main.b)
55
explosionid = {262562442,144699494,539294959,1388740053}
56
--919941001
57
Prefix = "/"
58
p.Chatted:connect(function(msg)
59
 
60
    if msg:lower():sub(1,#Prefix+#'color r ')==Prefix..'color r ' then
61
    local v = tonumber(msg:sub(#Prefix+#'color r '+1))
62
    main.r = v
63
    elseif msg:lower():sub(1,#Prefix+#'color g ')==Prefix..'color g ' then
64
    local v = tonumber(msg:sub(#Prefix+#'color g '+1))
65
    main.g = v
66
    elseif msg:lower():sub(1,#Prefix+#'color b ')==Prefix..'color b ' then
67
    local v = tonumber(msg:sub(#Prefix+#'color b '+1))
68
    main.b = v
69
    elseif msg:lower():sub(1,#Prefix+#'color v ')==Prefix..'color v ' then
70
    local v = tonumber(msg:sub(#Prefix+#'color v '+1))
71
    if v > 1 then main.v = 1 elseif v < -1 then main.v = -1 else main.v = v end
72
73
    elseif msg:lower():sub(1,#Prefix+#'theme ')==Prefix..'theme ' then
74
    local v = tonumber(msg:sub(#Prefix+#'theme '+1))
75
    themeid = v
76
    music(themeid,themepitch)
77
78
    elseif msg:lower():sub(1,#Prefix+#'pitch ')==Prefix..'pitch ' then
79
    local v = tonumber(msg:sub(#Prefix+#'pitch '+1))
80
    themepitch = v
81
    music(themeid,themepitch)
82
83
    elseif msg:lower():sub(1,#Prefix+#'prefix ')==Prefix..'prefix ' then
84
    local v = msg:sub(#Prefix+#'prefix '+1)
85
    Prefix = v
86
 
87
    elseif msg:lower():sub(1,#Prefix+#'reset')==Prefix..'reset' then
88
    main.r = 51
89
    main.g = 255
90
    main.b = 153
91
    main.v = 1
92
    themeid = 556122490
93
    themepitch = 1
94
    music(themeid,themepitch)
95
96
    end
97
98
end)
99
100
101
local Humanoid = game.Players.LocalPlayer.Character:FindFirstChildOfClass("Humanoid")
102
103
local CurrentHealth = Humanoid.Health
104
local Defeated = false
105
Humanoid.Changed:connect(function()
106
	if Defeated then return end
107
	local Health = math.min(Humanoid.Health-CurrentHealth)
108
	if CurrentHealth - 0.1 < -Health then
109
		Humanoid.Health = Humanoid.MaxHealth
110
	end
111
	CurrentHealth = Humanoid.Health
112
end)
113
114
local ff = Instance.new("ForceField",char)
115
ff.Visible = false
116
117
118
----------------------------------------------------------------------------
119
no_anim = false
120
attack = false
121
attacking = false
122
canjump = true
123
aiming_anim = false
124
animid = math.random(0,1)
125
timer = 0
126
bg = Instance.new("BodyGyro",root)
127
bg.P = 100000
128
bg.D = 100
129
----------------------------------------------------------------------------
130
131
function rswait(value)
132
  if value ~= nil and value ~= 0 then
133
    for i=1,value do
134
     rs:wait()
135
    end
136
  else
137
	rs:wait()
138
  end
139
end
140
141
----------------------------------------------------------------------------
142
local maincolor = BrickColor.new("Institutional white")
143
function Eviscerate(dude)
144
	if dude.Name ~= char.Name then
145
		local bgf = Instance.new("BodyGyro", dude.Head)
146
		bgf.CFrame = bgf.CFrame * CFrame.fromEulerAnglesXYZ(math.rad(-90), 0, 0)
147
		local val = Instance.new("BoolValue", dude)
148
		val.Name = "IsHit"
149
		local ds = coroutine.wrap(function()
150
			dude:WaitForChild("Head"):BreakJoints()
151
			wait(0.5)
152
			coroutine.resume(coroutine.create(function()
153
				for i, v in pairs(dude:GetChildren()) do
154
					if v:IsA("Accessory") then
155
						v:Destroy()
156
					end
157
					if v:IsA("Humanoid") then
158
						v:Destroy()
159
					end
160
					if v:IsA("CharacterMesh") then
161
						v:Destroy()
162
					end
163
					if v:IsA("Model") then
164
						v:Destroy()
165
					end
166
					if v:IsA("Part") or v:IsA("MeshPart") then
167
						for x, o in pairs(v:GetChildren()) do
168
							if o:IsA("Decal") then
169
								o:Destroy()
170
							end
171
						end
172
						coroutine.resume(coroutine.create(function()
173
							v.Material = "Neon"
174
							v.CanCollide = false
175
							local PartEmmit1 = Instance.new("ParticleEmitter", v)
176
							PartEmmit1.LightEmission = 1
177
							PartEmmit1.Texture = "rbxassetid://284205403"
178
							PartEmmit1.Color = ColorSequence.new(maincolor.Color)
179
							PartEmmit1.Rate = 150
180
							PartEmmit1.Lifetime = NumberRange.new(1)
181
							PartEmmit1.Size = NumberSequence.new({
182
								NumberSequenceKeypoint.new(0, 0.75, 0),
183
								NumberSequenceKeypoint.new(1, 0, 0)
184
							})
185
							PartEmmit1.Transparency = NumberSequence.new({
186
								NumberSequenceKeypoint.new(0, 0, 0),
187
								NumberSequenceKeypoint.new(1, 1, 0)
188
							})
189
							PartEmmit1.Speed = NumberRange.new(0, 0)
190
							PartEmmit1.VelocitySpread = 30000
191
							PartEmmit1.Rotation = NumberRange.new(-500, 500)
192
							PartEmmit1.RotSpeed = NumberRange.new(-500, 500)
193
							local BodPoss = Instance.new("BodyPosition", v)
194
							BodPoss.P = 3000
195
							BodPoss.D = 1000
196
							BodPoss.maxForce = Vector3.new(50000000000, 50000000000, 50000000000)
197
							BodPoss.position = v.Position + Vector3.new(math.random(-15, 15), math.random(-15, 15), math.random(-15, 15))
198
							v.Color = maincolor.Color
199
							v.CanCollide = false
200
							coroutine.resume(coroutine.create(function()
201
								for i = 0, 49 do
202
									rswait()
203
									v.Transparency = v.Transparency + 0.08
204
								end
205
								wait(0.5)
206
								PartEmmit1.Enabled = false
207
								wait(3)
208
								v:Destroy()
209
								dude:Destroy()
210
							end))
211
						end))
212
					end
213
				end
214
			end))
215
		end)
216
		ds()
217
	end
218
end
219
-------------------------
220
local RootPart = char.HumanoidRootPart
221
local Torso = char.Torso
222
local Head = char.Head
223
local RightArm = char['Right Arm']
224
local LeftArm = char['Left Arm']
225
local RightLeg = char['Right Leg']
226
local LeftLeg = char['Left Leg']
227
228
local BODY = {}
229
for _, c in pairs(char:GetDescendants()) do
230
	if c:IsA("BasePart") and c.Name ~= "Handle" then
231
		if c ~= RootPart and c ~= Torso and c ~= Head and c ~= RightArm and c ~= LeftArm and c ~= RightLeg and c ~= LeftLeg then
232
			c.CustomPhysicalProperties = PhysicalProperties.new(0, 0, 0, 0, 0)
233
		end
234
		table.insert(BODY,{c,c.Parent,c.Material,c.Color,c.Transparency})
235
	elseif c:IsA("JointInstance") then
236
		table.insert(BODY,{c,c.Parent,nil,nil,nil})
237
	end
238
end
239
for e = 1, #BODY do
240
	if BODY[e] ~= nil then
241
		local STUFF = BODY[e]
242
		local PART = STUFF[1]
243
		local PARENT = STUFF[2]
244
		local MATERIAL = STUFF[3]
245
		local COLOR = STUFF[4]
246
		local TRANSPARENCY = STUFF[5]
247
		if PART.ClassName == "Part" and PART ~= RootPart then
248
			PART.Material = MATERIAL
249
			PART.Color = COLOR
250
			PART.Transparency = TRANSPARENCY
251
		end
252
		PART.AncestryChanged:Connect(function()
253
			PART.Parent = PARENT
254
		end)
255
	end
256
end
257
258
local EXTRATRANS = 0
259
function refit()
260
	char.Parent = workspace
261
	for e = 1, #BODY do
262
		if BODY[e] ~= nil then
263
			local STUFF = BODY[e]
264
			local PART = STUFF[1]
265
			local PARENT = STUFF[2]
266
			local MATERIAL = STUFF[3]
267
			local COLOR = STUFF[4]
268
			local TRANSPARENCY = STUFF[5]
269
			if PART:IsA("BasePart") and PART ~= RootPart then
270
				PART.Material = MATERIAL
271
				PART.Color = COLOR
272
				PART.Transparency = TRANSPARENCY + EXTRATRANS
273
			end
274
			if PART.Parent ~= PARENT then
275
				Humanoid:Destroy()
276
				PART.Parent = PARENT
277
				Humanoid = Instance.new("Humanoid", char)
278
			end
279
		end
280
	end
281
end
282
283
Humanoid.Died:connect(function()
284
	refit()
285
end)
286
287
--------------------------------------
288
289
max = 0
290
function music(id,pitch)
291
max = 0
292
if id == "Stop" then
293
if not torso:FindFirstChild("MusicRuin") then
294
soundz = Instance.new("Sound",torso)
295
end
296
soundz:Stop()
297
else
298
if not torso:FindFirstChild("MusicRuin") then
299
soundz = Instance.new("Sound",torso)
300
end
301
soundz.MaxDistance = 150*5
302
soundz.EmitterSize = 150/5
303
soundz.Volume = 10
304
soundz.Name = "MusicRuin"
305
soundz.Looped = true
306
soundz.PlaybackSpeed = pitch
307
soundz.SoundId = "rbxassetid://"..id
308
soundz:Stop()
309
soundz:Play()
310
end
311
end
312
313
----------------------------------------------------------------------------
314
315
function lerp(a, b, t)
316
  return a + (b - a)*t
317
end
318
319
----------------------------------------------------------------------------
320
321
function Lerp(c1,c2,al)
322
  local com1 = {c1.X,c1.Y,c1.Z,c1:toEulerAnglesXYZ()}
323
  local com2 = {c2.X,c2.Y,c2.Z,c2:toEulerAnglesXYZ()}
324
  for i,v in pairs(com1) do
325
    com1[i] = v+(com2[i]-v)*al
326
  end
327
  return CFrame.new(com1[1],com1[2],com1[3]) * CFrame.Angles(select(4,unpack(com1)))
328
end
329
330
----------------------------------------------------------------------------
331
332
function slerp(a, b, t)
333
  dot = a:Dot(b)
334
  if dot > 0.99999 or dot < -0.99999 then
335
    return t <= 0.5 and a or b
336
  else
337
    r = math.acos(dot)
338
    return (a*math.sin((1 - t)*r) + b*math.sin(t*r)) / math.sin(r)
339
  end
340
end
341
342
----------------------------------------------------------------------------
343
344
function clerp(c1,c2,al)
345
346
  local com1 = {c1.X,c1.Y,c1.Z,c1:toEulerAnglesXYZ()}
347
348
  local com2 = {c2.X,c2.Y,c2.Z,c2:toEulerAnglesXYZ()}
349
350
  for i,v in pairs(com1) do
351
352
    com1[i] = lerp(v,com2[i],al)
353
354
  end
355
356
  return CFrame.new(com1[1],com1[2],com1[3]) * CFrame.Angles(select(4,unpack(com1)))
357
358
end
359
360
----------------------------------------------------------------------------
361
362
function findAllNearestTorso(pos,dist)
363
    local list = game.Workspace:children()
364
    local torso = {}
365
    local temp = nil
366
    local human = nil
367
    local temp2 = nil
368
    for x = 1, #list do
369
        temp2 = list[x]
370
        if (temp2.className == "Model") and (temp2 ~= char) then
371
            local nayem = "Torso"
372
            if temp2:findFirstChild("UpperTorso") then nayem = "UpperTorso" end
373
            temp = temp2:findFirstChild(nayem)
374
            human = temp2:findFirstChildOfClass("Humanoid")
375
            if (temp ~= nil) and (human ~= nil) and (human.Health > 0) then
376
                if (temp.Position - pos).magnitude < dist then
377
                    table.insert(torso,temp)
378
                    dist = (temp.Position - pos).magnitude
379
                end
380
            end
381
        end
382
    end
383
    return torso
384
end
385
386
----------------------------------------------------------------------------
387
388
local isAPlayer
389
function checkIfNotPlayer(model)
390
coroutine.resume(coroutine.create(function()
391
if model ~= char and model.Parent ~= char and model.Parent.Parent ~= char and model.Parent ~= DebrisModel and model.Parent.Parent ~= DebrisModel and model.Parent.Parent.Parent ~= DebrisModel then
392
isAPlayer = true
393
else
394
isAPlayer = false
395
end
396
end))
397
return isAPlayer
398
end
399
400
----------------------------------------------------------------------------
401
402
function computeDirection(vec)
403
local lenSquared = vec.magnitude * vec.magnitude
404
local invSqrt = 1 / math.sqrt(lenSquared)
405
return Vector3.new(vec.x * invSqrt, vec.y * invSqrt, vec.z * invSqrt)
406
end
407
408
----------------------------------------------------------------------------
409
410
function newWeld(wp0, wp1, wc0x, wc0y, wc0z)
411
412
  local wld = Instance.new("Weld", wp1)
413
414
  wld.Part0 = wp0
415
416
  wld.Part1 = wp1
417
418
  wld.C0 = CFrame.new(wc0x, wc0y, wc0z)
419
420
  return wld
421
422
end
423
424
----------------------------------------------------------------------------
425
426
function weld(model)
427
	local parts,last = {}
428
	local function scan(parent)
429
		for _,v in pairs(parent:GetChildren()) do
430
			if (v:IsA("BasePart")) then
431
				if (last) then
432
					local w = Instance.new("Weld")
433
					w.Name = ("%s_Weld"):format(v.Name)
434
					w.Part0,w.Part1 = last,v
435
					w.C0 = last.CFrame:inverse()
436
					w.C1 = v.CFrame:inverse()
437
					w.Parent = last
438
				end
439
				last = v
440
				table.insert(parts,v)
441
			end
442
			scan(v)
443
		end
444
	end
445
	scan(model)
446
	for _,v in pairs(parts) do
447
		v.Anchored = false
448
		v.Locked = true
449
	end
450
end
451
452
----------------------------------------------------------------------------
453
454
function sound(id,position,vol,pitch,dist,start,finish)
455
  coroutine.resume(coroutine.create(function()
456
457
  local part = Instance.new("Part",DebrisModel)
458
  part.Anchored = true
459
  part.Position = position
460
  part.Size = Vector3.new(0,0,0)
461
  part.CanCollide = false
462
  part.Transparency = 1
463
464
  soundasd = Instance.new("Sound",part)
465
  
466
  soundasd.SoundId = "rbxassetid://"..id
467
  
468
  if vol ~= nil then
469
    soundasd.Volume = vol
470
  end
471
472
  if pitch ~= nil then
473
    soundasd.PlaybackSpeed = pitch
474
  end
475
  
476
  if dist ~= nil then
477
    soundasd.MaxDistance = dist*5
478
    soundasd.EmitterSize = dist/5
479
  end
480
481
  delay(0.5,function() debris:AddItem(part,soundasd.TimeLength+3) end)
482
  
483
  soundasd:Play()
484
  
485
  end))
486
  return soundasd
487
end
488
489
function createsound(id,parent)
490
491
  local soundz = Instance.new("Sound",parent)
492
493
  soundz.SoundId = "rbxassetid://"..id
494
495
  return soundz
496
497
end
498
499
function playsound(sond,vol,pitch,start)
500
  
501
  if vol ~= nil then
502
    sond.Volume = vol
503
  end
504
505
  if pitch ~= nil then
506
    sond.PlaybackSpeed = pitch
507
  end
508
 
509
  if start ~= nil then
510
    sond.TimePosition = start
511
  end
512
513
  sond:Play()
514
  
515
end
516
517
----------------------------------------------------------------------------
518
eColors={"Pastel green","Toothpaste"}
519
function Lightning(Part0,Part1,Times,Offset,Color,Thickness,Trans)
520
    local magz = (Part0 - Part1).magnitude
521
    local curpos = Part0
522
    local trz = {-Offset,Offset} 
523
    for i=1,Times do
524
        local li = Instance.new("Part", DebrisModel)
525
        li.TopSurface =0
526
        li.Material = Enum.Material.Neon
527
        li.BottomSurface = 0
528
        li.Anchored = true
529
        li.Locked = true
530
        li.Transparency = Trans or 0.4
531
        li.BrickColor = BrickColor.new(Color)
532
        li.formFactor = "Custom"
533
        li.CanCollide = false
534
        li.Size = Vector3.new(Thickness,Thickness,magz/Times)
535
        local lim = Instance.new("BlockMesh",li)
536
        local Offzet = Vector3.new(trz[math.random(1,2)],trz[math.random(1,2)],trz[math.random(1,2)])
537
        local trolpos = CFrame.new(curpos,Part1)*CFrame.new(0,0,magz/Times).p+Offzet
538
        if Times == i then
539
        local magz2 = (curpos - Part1).magnitude
540
        li.Size = Vector3.new(Thickness,Thickness,magz2)
541
        li.CFrame = CFrame.new(curpos,Part1)*CFrame.new(0,0,-magz2/2)
542
        else
543
        li.CFrame = CFrame.new(curpos,trolpos)*CFrame.new(0,0,magz/Times/2)
544
        end
545
        curpos = li.CFrame*CFrame.new(0,0,magz/Times/2).p
546
        li.Name = "LIGHTNING"
547
    end
548
end
549
550
----------------------------------------------------------------------------
551
552
local HBill = Instance.new("BillboardGui",hed)
553
local HMain, HBar = Instance.new("Frame", HBill), Instance.new("Frame")
554
local HName = Instance.new("TextLabel")
555
HBill.Size = UDim2.new(15,0,2.2,0)
556
HBill.StudsOffset = Vector3.new(3.675,1.2,0)
557
HBill.AlwaysOnTop = true
558
HBill.Enabled = true
559
HMain.BackgroundColor3 = Color3.new(0, 0, 0)
560
HMain.BackgroundTransparency = 1
561
HMain.Size = UDim2.new(.5,0,.2,0)
562
HName.Parent = HMain
563
HName.BackgroundTransparency = 1
564
HName.BackgroundColor3 = Color3.new(255,255,255)
565
HName.BorderColor3 = Color3.new(0,0,0)
566
HName.BorderSizePixel = 2
567
HName.Size = UDim2.new(1,0,.75,0)
568
HName.Font = "Code"
569-
HName.Text "Infinity God Mode"
569+
HName.Text = "Infinity God Mode"
570
HName.TextScaled = true
571
HName.TextColor3 = Color3.new(0,255,255)
572
local cR=255
573
local cG=0
574
local cB=0
575
local flg5=1 local omgidk=1
576
local add=15
577
game:GetService("RunService"):BindToRenderStep("Ghost",1,function()
578
	if omgidk>10000 then omgidk=0 end
579
	omgidk=omgidk+1
580
	if cR>=255 then flg5=1 end
581
	if cG>=255 then flg5=2 end
582
	if cB>=255 then flg5=3 end
583
	if flg5==1 then cR=cR-add cG=cG+add end
584
	if flg5==2 then cG=cG-add cB=cB+add end
585
	if flg5==3 then cB=cB-add cR=cR+add end
586
	color=Color3.fromRGB(cR,cG,cB)
587
HName.TextStrokeColor3 = color
588
HName.TextStrokeTransparency = 0
589
HName.TextYAlignment = "Bottom"
590
end)
591
592
local HBill = Instance.new("BillboardGui",hed)
593
local HMain, HBar = Instance.new("Frame", HBill), Instance.new("Frame")
594
local HName = Instance.new("TextLabel")
595
HBill.Size = UDim2.new(15,0,2.2,0)
596
HBill.StudsOffset = Vector3.new(3.675,2,0)
597
HBill.AlwaysOnTop = true
598
HBill.Enabled = true
599
HMain.BackgroundColor3 = Color3.new(0, 0, 0)
600
HMain.BackgroundTransparency = 1
601
HMain.Size = UDim2.new(.5,0,.5,0)
602
HName.Parent = HMain
603
HName.BackgroundTransparency = 1
604
HName.BackgroundColor3 = Color3.new(255,255,255)
605
HName.BorderColor3 = Color3.new(0,0,0)
606
HName.BorderSizePixel = 2
607
HName.Size = UDim2.new(1,0,.75,0)
608
HName.Font = "Code"
609
HName.Text = player.Name.. ", The Infinite All-Seeing Starlight OmniGod Guardian"
610
HName.TextScaled = true
611
HName.TextColor3 = Color3.new(51,255,153)
612
HName.TextStrokeColor3 = Color3.new(255,255,255)
613
HName.TextStrokeTransparency = 0
614
HName.TextYAlignment = "Bottom"
615
616
---------- BIG BOOM REKT
617
618
619
function bigboomrektxd()
620
coroutine.resume(coroutine.create(function()
621
local magnitude = nil
622
local Position = nil
623
if animid == 0 then
624
Position = larm.Position
625
else
626
Position = rarm.Position
627
end
628
--sound(743499393,Position,10,math.random(6,8)/10)
629
sound(440145223,Position,10,math.random(10,12)/10,50)
630
631
local Part1 = Instance.new("Part")
632
local mesh2 = Instance.new("SpecialMesh",Part1)
633
mesh2.MeshId = "rbxassetid://559831844"
634
mesh2.Scale = Vector3.new(0,0,0.4)
635
Part1.Material = Enum.Material.Neon
636
Part1.CanCollide = false
637
Part1.Color = Color3.fromHSV(0,0,main.v)
638
Part1.Parent = DebrisModel
639
Part1.Size = Vector3.new(0,0,0)
640
Part1.Anchored = true
641
Part1.CFrame = CFrame.new(Position,mouse.Hit.p)
642
Part1.Name = "EXPLOSION2"
643
644
local Part0 = Instance.new("Part",DebrisModel)
645
local PointLight2 = Instance.new("PointLight")
646
Part0.Name = "Bullet"
647
Part0.Material = Enum.Material.Neon
648
Part0.Color = Color3.ffromHSV(0,0,main.v)
649
Part0.Anchored = false
650
Part0.Size = Vector3.new(5, 5, 5)
651
local mesh = Instance.new("SpecialMesh",Part0)
652
mesh.MeshType = Enum.MeshType.Sphere
653
local bforce = Instance.new("BodyForce",Part0)
654
bforce.force = Vector3.new(0, ((bforce.Parent:getMass())*workspace.Gravity), 0)
655
Part0.CanCollide = false
656
PointLight2.Parent = Part0
657
PointLight2.Color = Part0.Color
658
local Target = mouse.Hit.p
659
local direction = Target - Position
660
local direction = computeDirection(direction)
661
local pos = Position + (direction * 2) 
662
Part0.CFrame = CFrame.new(pos,  pos + direction) * CFrame.Angles((math.pi/2)+math.rad(180), 0, 0)
663
Part0.Velocity = direction * 60
664
local asd = nil
665
local loop = nil
666
delay(5, function() Part0:Destroy() loop:disconnect() asd:disconnect() end)
667
loop = rs:connect(function()
668
local asdf = math.random(500,1000)/1000
669
local Part1 = Instance.new("Part")
670
local mesh2 = Instance.new("SpecialMesh",Part1)
671
mesh2.MeshType = Enum.MeshType.Sphere
672
Part1.Material = Enum.Material.Neon
673
Part1.CanCollide = false
674
Part1.Color = Color3.fromHSV(Color3.toHSV(main_color),math.random(0,10000)/10000,main.v)
675
Part1.Parent = DebrisModel
676
Part1.Size = Part0.Size + Vector3.new(asdf,asdf,asdf)
677
Part1.Anchored = true
678
Part1.CFrame = CFrame.new(Part0.Position + Vector3.new(math.random(-1000,1000)/750,math.random(-1000,1000)/750,math.random(-1000,1000)/750))
679
Part1.Name = "SMOKE"
680
end)
681
asd = Part0.Touched:connect(function(ht)
682
local hit=ht.Parent
683
if checkIfNotPlayer(ht) == true and ht.CanCollide == true then
684
asd:disconnect()
685
loop:disconnect()
686
Part0:Destroy()
687
688
sound(explosionid[math.random(1,#explosionid)],Part0.Position,10,math.random(6,9)/10,200)
689
for i,v in pairs(findAllNearestTorso(Part0.Position,50)) do
690
if v.Parent:FindFirstChildOfClass("Humanoid") ~= nil then
691
	Eviscerate(v.Parent)
692
end
693
local Position = Part0.Position
694
local Target = v.Position
695
local direction = Target - Position
696
local direction = computeDirection(direction)
697
local bv = Instance.new("BodyVelocity",v)
698
bv.Velocity = direction * (50 - ((Position - Target).magnitude/2))
699
debris:AddItem(bv,1)
700
end
701
for i=1,14,2 do for x=1,math.random(0,1) do rs:wait() end
702
for z=1,math.random(2,3) do
703
local asdf = math.random(-5,5)*10-(i/20)*8
704
local Part1 = Instance.new("Part")
705
local mesh2 = Instance.new("SpecialMesh",Part1)
706
mesh2.MeshType = Enum.MeshType.Sphere
707
mesh2.Scale = Vector3.new(0,0,0)
708
Part1.Material = Enum.Material.Neon
709
Part1.CanCollide = false
710
Part1.Color = Color3.fromHSV(Color3.toHSV(main_color),math.random(0,10000)/10000,main.v)
711
Part1.Parent = DebrisModel
712
Part1.Size = Vector3.new(asdf,asdf,asdf)
713
Part1.Anchored = true
714
local a = i*0.5
715
Part1.CFrame = CFrame.new(Part0.Position + Vector3.new(math.random(-2,2)*a,math.random(-10,10),math.random(-2,2)*a))
716
Part1.Name = "EXPLOSION"
717
end
718
end
719
720
end
721
end)
722
end))
723
end
724
725
holdclick=false
726
727
mouse.Button1Down:connect(function()
728
if debounce == false then
729
if animid == 0 then
730
animid = 1
731
else
732
animid = 0
733
end
734
debounce = true
735
holdclick = true
736
aiming_anim = true
737
wait(0.2)
738
repeat 
739
rs:wait()
740
timer = 150
741
until holdclick == false
742
bigboomrektxd()
743
744
local Position = mouse.Hit.p
745
local Target = root.Position
746
local direction = Target - Position
747
local direction = computeDirection(direction)
748
root.Velocity = direction * 150
749
750
aiming_anim = false
751
delay(0.3,function() debounce = false end)
752
end
753
end)
754
755
mouse.Button1Up:connect(function()
756
holdclick=false
757
end)
758
759
----------- CANCER
760
761
762
function dashasdf()
763
debounce = true
764
coroutine.resume(coroutine.create(function()
765
	rswait(0)
766
	debounce = false
767
end))
768
769
canjump = false
770
attack = true
771
772
for i,v in pairs(char:GetChildren()) do
773
if v ~= root then
774
if v:IsA("Part") then
775
v.Transparency = 1
776
elseif v:IsA("Accoutrement") then
777
v:FindFirstChildOfClass("Part").Transparency = 1
778
end
779
end
780
end
781
782
local tempattachment = Instance.new("Attachment",root)
783
tempattachment.Position = Vector3.new(0,0,-4)
784
785
for i=1,20 do rs:wait()
786
root.Velocity = Vector3.new(0,0,0)
787
root.CFrame = CFrame.new(tempattachment.WorldPosition) * CFrame.Angles(math.rad(root.Orientation.X),math.rad(root.Orientation.Y),math.rad(root.Orientation.Z))
788
local asdf = math.random(500,1000)/100
789
local Part1 = Instance.new("Part")
790
local mesh2 = Instance.new("SpecialMesh",Part1)
791
mesh2.MeshType = Enum.MeshType.Sphere
792
Part1.Material = Enum.Material.Neon
793
Part1.CanCollide = false
794
Part1.Color = Color3.fromHSV(Color3.toHSV(main_color),math.random(0,10000)/10000,main.v)
795
Part1.Parent = DebrisModel
796
Part1.Size = Vector3.new(asdf,asdf,asdf)
797
Part1.Anchored = true
798
Part1.CFrame = CFrame.new(root.Position + Vector3.new(math.random(-1000,1000)/500,math.random(-1000,1000)/500,math.random(-1000,1000)/500))
799
Part1.Name = "SMOKE"
800
end
801
802
tempattachment:Destroy()
803
804
for i,v in pairs(char:GetChildren()) do
805
if v ~= root then
806
if v:IsA("Part") then
807
v.Transparency = 0
808
elseif v:IsA("Accoutrement") then
809
v:FindFirstChildOfClass("Part").Transparency = 0
810
end
811
end
812
end
813
814
canjump = true
815
attack = false
816
817
delay(0.1,function() debounce = false end)
818
end
819
820
-----------------------  LAZOR
821
822
823
function laz0r()
824
825
local Position = nil
826
if animid == 0 then
827
Position = larm.Position
828
else
829
Position = rarm.Position
830
end
831
832
local Part1 = Instance.new("Part")
833
local mesh2 = Instance.new("SpecialMesh",Part1)
834
mesh2.MeshId = "rbxassetid://559831844"
835
mesh2.Scale = Vector3.new(0,0,0.4)
836
Part1.Material = Enum.Material.Neon
837
Part1.CanCollide = false
838
Part1.Color = Color3.fromHSV(0,0,main.v)
839
Part1.Parent = DebrisModel
840
Part1.Size = Vector3.new(0,0,0)
841
Part1.Anchored = true
842
Part1.CFrame = CFrame.new(Position,mouse.Hit.p)
843
Part1.Name = "EXPLOSION3"
844
845
local Part0 = Instance.new("Part",DebrisModel)
846
Part0.Name = "Bullet"
847
Part0.Material = Enum.Material.Neon
848
Part0.Color = Color3.fromHSV(0,0,main.v)
849
Part0.Anchored = true
850
local mesh = Instance.new("SpecialMesh",Part0)
851
mesh.MeshType = Enum.MeshType.Sphere
852
Part0.CanCollide = false
853
local Target = mouse.Hit.p
854
local direction = Target - Position
855
local direction = computeDirection(direction)
856
local ray = Ray.new(Position, (Target-Position).unit*1048)
857
local part, endPoint = workspace:FindPartOnRay(ray, char)
858
Part0.Size = Vector3.new(5,1,5)
859
mesh.Scale = Vector3.new(1,(Position-endPoint).magnitude,1)
860
local pos = Position + (direction * (mesh.Scale.Y/2))
861
Part0.CFrame = CFrame.new(pos,  pos + direction) * CFrame.Angles((math.pi/2)+math.rad(180), 0, 0)
862
863
clashpart = Instance.new("Part",DebrisModel)
864
clashpart.Size = Vector3.new(50,50,50)
865
clashpart.CanCollide = false
866
clashpart.Anchored = true
867
clashpart.Transparency = 1
868
clashpart.Color = main_color
869
clashpart.Name = "StarLightClash"
870
clashpart.CFrame = CFrame.new(endPoint, root.Position)
871
872
sound(1177475476,Position,10,math.random(5,6)/10,300)
873
874
local z = 10
875
for i = 1,100 do rs:wait()
876
if animid == 0 then
877
Position = larm.Position
878
else
879
Position = rarm.Position
880
end
881
local Target = mouse.Hit.p
882
local direction = Target - Position
883
local direction = computeDirection(direction)
884
local ray = Ray.new(Position, (Target-Position).unit*1048)
885
local part, endPoint = workspace:FindPartOnRay(ray, char)
886
Part0.Size = Vector3.new(5-((i/100)*5),1,5-((i/100)*5))
887
mesh.Scale = Vector3.new(1,(Position-endPoint).magnitude,1)
888
mesh.Offset = Vector3.new(math.random(-10000,10000)/20000,math.random(-10000,10000)/20000,0)
889
local pos = Position + (direction * (mesh.Scale.Y/2))
890
Part0.CFrame = CFrame.new(pos,  pos + direction) * CFrame.Angles((math.pi/2)+math.rad(180), 0, 0)
891
clashpart.CFrame = CFrame.new(endPoint, root.Position)
892
893
local Position = mouse.Hit.p
894
local Target = root.Position
895
local direction = Target - Position
896
local direction = computeDirection(direction)
897
root.Velocity = direction * 5
898
899
if i >= z then z = i + 10 sound(explosionid[math.random(1,#explosionid)],endPoint,10,math.random(6,9)/10,200) end
900
901
Part1 = Part0:Clone()
902
Part1.Parent = DebrisModel
903
Part1.Color = Color3.fromHSV(Color3.toHSV(main_color),math.random(0,10000)/10000,main.v)
904
Part1.Name = "SMOKE2"
905
906
if part ~= nil then
907
if part.Name == "StarLightClash" then
908
local asdf = math.random(0,5)*20
909
local Part1 = Instance.new("Part")
910
local mesh2 = Instance.new("SpecialMesh",Part1)
911
mesh2.MeshType = Enum.MeshType.Sphere
912
mesh2.Scale = Vector3.new(0,0,0)
913
Part1.Material = Enum.Material.Neon
914
Part1.CanCollide = false
915
Part1.Color = Color3.fromHSV(Color3.toHSV(Color3.fromRGB((main.r+(255*part.Color.r))/2,(main.g+(255*part.Color.g))/2,(main.b+(255*part.Color.b))/2)),math.random(5000,10000)/10000,main.v)
916
Part1.Parent = DebrisModel
917
Part1.Size = Vector3.new(asdf,asdf,asdf)
918
Part1.Anchored = true
919
local a = 1.5
920
Part1.CFrame = CFrame.new(endPoint + Vector3.new(math.random(-2,2)*a,math.random(-4,4),math.random(-2,2)*a))
921
Part1.Name = "EXPLOSION"
922
else
923
local asdf = math.random(0,5)*10
924
local Part1 = Instance.new("Part")
925
local mesh2 = Instance.new("SpecialMesh",Part1)
926
mesh2.MeshType = Enum.MeshType.Sphere
927
mesh2.Scale = Vector3.new(0,0,0)
928
Part1.Material = Enum.Material.Neon
929
Part1.CanCollide = false
930
Part1.Color = Color3.fromHSV(Color3.toHSV(main_color),math.random(0,10000)/10000,main.v)
931
Part1.Parent = DebrisModel
932
Part1.Size = Vector3.new(asdf,asdf,asdf)
933
Part1.Anchored = true
934
local a = 1.5
935
Part1.CFrame = CFrame.new(endPoint + Vector3.new(math.random(-2,2)*a,math.random(-4,4),math.random(-2,2)*a))
936
Part1.Name = "EXPLOSION"
937
end
938
end
939
940
for i,v in pairs(findAllNearestTorso(endPoint,50)) do
941
if v.Parent:FindFirstChildOfClass("Humanoid") then
942
	Eviscerate(v.Parent)
943
end
944
local Position = mouse.Hit.p
945
local Target = v.Position
946
local direction = Target - Position
947
local direction = computeDirection(direction)
948
local bv = Instance.new("BodyVelocity",v)
949
bv.Velocity = direction * (10 - ((Position - Target).magnitude/2))
950
debris:AddItem(bv,1)
951
end
952
953
end
954
clashpart:Destroy()
955
Part0:Destroy()
956
wait(0.3)
957
aiming_anim = false
958
delay(0.3,function() debounce = false end)
959
end
960
961
------------------------- ULTIMATE
962
963
964
function nukewelpo()
965
coroutine.resume(coroutine.create(function()
966
local magnitude = nil
967
local Position = nil
968
if animid == 0 then
969
Position = larm.Position
970
else
971
Position = rarm.Position
972
end
973
--sound(743499393,Position,10,math.random(6,8)/10)
974
sound(440145223,Position,10,math.random(4,5)/10,100)
975
976
local Part1 = Instance.new("Part")
977
local mesh2 = Instance.new("SpecialMesh",Part1)
978
mesh2.MeshId = "rbxassetid://559831844"
979
mesh2.Scale = Vector3.new(0,0,0.4)
980
Part1.Material = Enum.Material.Neon
981
Part1.CanCollide = false
982
Part1.Color = Color3.fromHSV(0,0,main.v)
983
Part1.Parent = DebrisModel
984
Part1.Size = Vector3.new(0,0,0)
985
Part1.Anchored = true
986
Part1.CFrame = CFrame.new(Position,mouse.Hit.p)
987
Part1.Name = "EXPLOSION3"
988
989
local Part0 = Instance.new("Part",DebrisModel)
990
local PointLight2 = Instance.new("PointLight")
991
Part0.Name = "Bullet"
992
Part0.Material = Enum.Material.Neon
993
Part0.Color = Color3.fromHSV(0,0,main.v)
994
Part0.Anchored = false
995
Part0.Size = Vector3.new(5, 5, 5)
996
local mesh = Instance.new("SpecialMesh",Part0)
997
mesh.MeshType = Enum.MeshType.Sphere
998
mesh.Scale = Vector3.new(3,3,3)
999
local bforce = Instance.new("BodyForce",Part0)
1000
bforce.force = Vector3.new(0, ((bforce.Parent:getMass())*workspace.Gravity), 0)
1001
Part0.CanCollide = false
1002
PointLight2.Parent = Part0
1003
PointLight2.Color = Part0.Color
1004
local Target = mouse.Hit.p
1005
local direction = Target - Position
1006
local direction = computeDirection(direction)
1007
local pos = Position + (direction * 2) 
1008
Part0.CFrame = CFrame.new(pos,  pos + direction) * CFrame.Angles((math.pi/2)+math.rad(180), 0, 0)
1009
Part0.Velocity = direction * 150
1010
local asd = nil
1011
local loop = nil
1012
delay(5, function() Part0:Destroy() loop:disconnect() asd:disconnect() end)
1013
loop = rs:connect(function()
1014
local asdf = math.random(500,1000)/1000
1015
local Part1 = Instance.new("Part")
1016
local mesh2 = Instance.new("SpecialMesh",Part1)
1017
mesh2.MeshType = Enum.MeshType.Sphere
1018
Part1.Material = Enum.Material.Neon
1019
Part1.CanCollide = false
1020
Part1.Color = Color3.fromHSV(Color3.toHSV(main_color),math.random(0,10000)/10000,main.v)
1021
Part1.Parent = DebrisModel
1022
Part1.Size = (Part0.Size*3) + Vector3.new(asdf,asdf,asdf)
1023
Part1.Anchored = true
1024
Part1.CFrame = CFrame.new(Part0.Position + Vector3.new(math.random(-3000,3000)/750,math.random(-3000,3000)/750,math.random(-3000,3000)/750))
1025
Part1.Name = "SMOKE"
1026
end)
1027
asd = Part0.Touched:connect(function(ht)
1028
local hit=ht.Parent
1029
if checkIfNotPlayer(ht) == true and ht.CanCollide == true then
1030
asd:disconnect()
1031
loop:disconnect()
1032
Part0:Destroy()
1033
1034
sound(explosionid[math.random(1,#explosionid)],Part0.Position,10,math.random(3,5)/10,500)
1035
for i,v in pairs(findAllNearestTorso(mouse.Hit.p,350)) do
1036
if v.Parent:FindFirstChildOfClass("Humanoid")then
1037
	Eviscerate(v.Parent)
1038
end
1039
local Position = Part0.Position
1040
local Target = v.Position
1041
local direction = Target - Position
1042
local direction = computeDirection(direction)
1043
end
1044
for i=1,10,0.5 do for x=1,math.random(0,1) do rs:wait() end
1045
for z=1,math.random(2,3) do
1046
local asdf = math.random(-5,5)*10-(i/20)*12
1047
local Part1 = Instance.new("Part")
1048
local mesh2 = Instance.new("SpecialMesh",Part1)
1049
mesh2.MeshType = Enum.MeshType.Sphere
1050
mesh2.Scale = Vector3.new(0,0,0)
1051
Part1.Material = Enum.Material.Neon
1052
Part1.CanCollide = false
1053
Part1.Color = Color3.fromHSV(Color3.toHSV(main_color),math.random(0,10000)/10000,main.v)
1054
Part1.Parent = DebrisModel
1055
Part1.Size = Vector3.new(asdf,asdf,asdf)
1056
Part1.Anchored = true
1057
local a = i*5
1058
Part1.CFrame = CFrame.new(Part0.Position + Vector3.new(math.random(-2,2)*a,math.random(-30,30),math.random(-2,2)*a))
1059
Part1.Name = "EXPLOSION4"
1060
end
1061
end
1062
1063
end
1064
end)
1065
end))
1066
end
1067
1068
holdq = false
1069
holdr = false
1070
cooldownult = false
1071
1072
------------------- ASSIGN THINGS TO KEYS ----------------------------
1073
1074
mouse.KeyDown:connect(function(key)
1075
if debounce == false then
1076
if key == "e" then
1077
dashasdf()
1078
elseif key == "r" and cooldownult == false then
1079
cooldownult = true
1080
if animid == 0 then
1081
animid = 1
1082
else
1083
animid = 0
1084
end
1085
debounce = false
1086
holdr = true
1087
aiming_anim = true
1088
wait(0.2)
1089
repeat 
1090
rs:wait()
1091
timer = 150
1092
until holdr == false
1093
nukewelpo()
1094
1095
local Position = mouse.Hit.p
1096
local Target = root.Position
1097
local direction = Target - Position
1098
local direction = computeDirection(direction)
1099
root.Velocity = direction * 300
1100
1101
aiming_anim = false
1102
delay(.5,function() cooldownult = false end)
1103
delay(1,function() debounce = false end)
1104
1105
elseif key == "q" then
1106
debounce = true
1107
if animid == 0 then
1108
animid = 1
1109
else
1110
animid = 0
1111
end
1112
holdq = true
1113
attack = true
1114
aiming_anim = true
1115
repeat rs:wait() timer = 150 until holdq == false
1116
laz0r()
1117
attack = false
1118
end
1119
end
1120
end)
1121
1122
mouse.KeyUp:connect(function(key)
1123
if key == "q" then
1124
holdq = false
1125
elseif key == "r" then
1126
holdr = false
1127
end
1128
end)
1129
1130
----------------------------------------------------------------------------
1131
music(themeid,themepitch)
1132
velocityYFall=0
1133
velocityYFall2=0
1134
velocityYFall3=0
1135
velocityYFall4=0
1136
neckrotY=0
1137
neckrotY2=0
1138
torsorotY=0
1139
torsorotY2=0
1140
torsoY=0
1141
torsoY2=0
1142
sine = 0
1143
newWeld(torso, larm, -1.5, 0.5, 0)
1144
larm.Weld.C1 = CFrame.new(0, 0.5, 0)
1145
newWeld(torso, rarm, 1.5, 0.5, 0)
1146
rarm.Weld.C1 = CFrame.new(0, 0.5, 0)
1147
newWeld(torso, hed, 0, 1.5, 0)
1148
newWeld(torso, lleg, -0.5, -1, 0)
1149
lleg.Weld.C1 = CFrame.new(0, 1, 0)
1150
newWeld(torso, rleg, 0.5, -1, 0)
1151
rleg.Weld.C1 = CFrame.new(0, 1, 0)
1152
newWeld(root, torso, 0, -1, 0)
1153
torso.Weld.C1 = CFrame.new(0, -1, 0)
1154
1155
rs:connect(function()
1156
1157
bg.MaxTorque = Vector3.new(0,0,0)
1158
1159
for i,v in pairs(DebrisModel:GetChildren()) do
1160
    
1161
1162
if v.Name == "EXPLOSION" then
1163
local change = 0.04-(v.Transparency*0.02)
1164
local vm = v:FindFirstChildOfClass("SpecialMesh")
1165
vm.Scale = vm.Scale + Vector3.new(change,change,change)
1166
v.Transparency = v.Transparency + 0.02
1167
if v.Transparency >= 1 then
1168
v:Destroy()
1169
end
1170
1171
elseif v.Name == "EXPLOSION2" then
1172
local change = 0.04-(v.Transparency*0.04)
1173
local vm = v:FindFirstChildOfClass("SpecialMesh")
1174
vm.Scale = vm.Scale + Vector3.new(change,change,0)
1175
v.Transparency = v.Transparency + 0.025
1176
if v.Transparency >= 1 then
1177
v:Destroy()
1178
end
1179
1180
elseif v.Name == "EXPLOSION3" then
1181
local change = 0.5-(v.Transparency*0.5)
1182
local vm = v:FindFirstChildOfClass("SpecialMesh")
1183
vm.Scale = vm.Scale + Vector3.new(change,change,0)
1184
v.Transparency = v.Transparency + 0.1
1185
if v.Transparency >= 1 then
1186
v:Destroy()
1187
end
1188
1189
elseif v.Name == "EXPLOSION4" then
1190
local change = 0.15-(v.Transparency*0.125)
1191
local vm = v:FindFirstChildOfClass("SpecialMesh")
1192
vm.Scale = vm.Scale + Vector3.new(change,change,change)
1193
v.Transparency = v.Transparency + 0.01
1194
if v.Transparency >= 1 then
1195
v:Destroy()
1196
end
1197
1198
elseif v.Name == "SMOKE" then
1199
local vm = v:FindFirstChildOfClass("SpecialMesh")
1200
vm.Scale = vm.Scale - Vector3.new(0.075,0.075,0.075)
1201
if vm.Scale.X <= 0 then
1202
v:Destroy()
1203
end
1204
1205
elseif v.Name == "SMOKE2" then
1206
local change = 2-(v.Transparency*2)
1207
local vm = v:FindFirstChildOfClass("SpecialMesh")
1208
local Position = nil
1209
if animid == 0 then
1210
Position = larm.Position
1211
else
1212
Position = rarm.Position
1213
end
1214
local Target = mouse.Hit.p
1215
local direction = Target - Position
1216
local direction = computeDirection(direction)
1217
local ray = Ray.new(Position, (Target-Position).unit*1048)
1218
local part, endPoint = workspace:FindPartOnRay(ray, char)
1219
vm.Scale = Vector3.new(vm.Scale.X,(Position-endPoint).magnitude,vm.Scale.Z) + Vector3.new(change,0,change)
1220
local pos = Position + (direction * (vm.Scale.Y/2))
1221
v.CFrame = CFrame.new(pos,  pos + direction) * CFrame.Angles((math.pi/2)+math.rad(180), 0, 0)
1222
vm.Offset = Vector3.new(math.random(-10000,10000)/10000,math.random(-10000,10000)/10000,0)
1223
v.Transparency = v.Transparency + 0.1
1224
if v.Transparency >= 1 then
1225
v:Destroy()
1226
end
1227
1228
1229
elseif v.Name == "LIGHTNING" then
1230
local vm = v:FindFirstChildOfClass("BlockMesh")
1231
vm.Scale = vm.Scale - Vector3.new(0.1,0.1,0)
1232
if vm.Scale.X <= 0 then
1233
v:Destroy()
1234
end
1235
1236
end
1237
end
1238
1239
if -root.Velocity.Y/1.5 > 0 and -root.Velocity.Y/1.5 < 160 then
1240
velocityYFall = root.Velocity.Y/1.5
1241
end
1242
if -root.Velocity.Y/180 > 0 and -root.Velocity.Y/180 < 1.2 then
1243
velocityYFall2 = root.Velocity.Y/180
1244
end
1245
if -root.Velocity.Y/1.5 > -5 and -root.Velocity.Y/1.5 < 50 then
1246
velocityYFall3 = root.Velocity.Y/1.5
1247
end
1248
if -root.Velocity.Y/1.5 > -50 and -root.Velocity.Y/1.5 < 20 then
1249
velocityYFall4 = root.Velocity.Y/1.5
1250
end
1251
if root.RotVelocity.Y/6 < 1 and root.RotVelocity.Y/6 > -1 then
1252
neckrotY = root.RotVelocity.Y/6
1253
end
1254
if root.RotVelocity.Y/8 < 0.6 and root.RotVelocity.Y/8 > -0.6 then
1255
neckrotY2 = root.RotVelocity.Y/8
1256
end
1257
1258
if root.RotVelocity.Y/6 < 0.2 and root.RotVelocity.Y/6 > -0.2 then
1259
torsorotY = root.RotVelocity.Y/6
1260
end
1261
if root.RotVelocity.Y/8 < 0.2 and root.RotVelocity.Y/8 > -0.2 then
1262
torsorotY2 = root.RotVelocity.Y/8
1263
end
1264
1265
1266
torsoY = -(torso.Velocity*Vector3.new(1, 0, 1)).magnitude/20
1267
torsoY2 = -(torso.Velocity*Vector3.new(1, 0, 1)).magnitude/36
1268
1269
if attack == true then
1270
hum.WalkSpeed = 1
1271
else
1272
hum.WalkSpeed = 8
1273
end
1274
1275
if canjump == true then
1276
hum.JumpPower = 50
1277
else
1278
hum.JumpPower = 0
1279
end
1280
1281
local jumped = false
1282
local ray1 = Ray.new(root.Position+Vector3.new(1,0,0),Vector3.new(0, -6, 0))
1283
local part1, endPoint = workspace:FindPartOnRay(ray1, char)
1284
local ray2 = Ray.new(root.Position-Vector3.new(1,0,0),Vector3.new(0, -6, 0))
1285
local part2, endPoint = workspace:FindPartOnRay(ray2, char)
1286
local ray3 = Ray.new(root.Position+Vector3.new(0,0,0.5),Vector3.new(0, -6, 0))
1287
local part3, endPoint = workspace:FindPartOnRay(ray3, char)
1288
local ray4 = Ray.new(root.Position-Vector3.new(0,0,0.5),Vector3.new(0, -6, 0))
1289
local part4, endPoint = workspace:FindPartOnRay(ray4, char)
1290
1291
if part1 or part2 or part3 or part4 then jumped = false else endPoint = 0 jumped = true end
1292
1293
local rlegray = Ray.new(rleg.Position+Vector3.new(0,0.5,0),Vector3.new(0, -1.75, 0))
1294
local rlegpart, rlegendPoint = workspace:FindPartOnRay(rlegray, char)
1295
1296
local llegray = Ray.new(lleg.Position+Vector3.new(0,0.5,0),Vector3.new(0, -1.75, 0))
1297
local llegpart, llegendPoint = workspace:FindPartOnRay(llegray, char)
1298
1299
if no_anim == false then
1300
if hum.Health > 0 then
1301
if (torso.Velocity*Vector3.new(1, 0, 1)).magnitude >= 5 and jumped == false then
1302
hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5,-.2)*CFrame.Angles(math.rad(-18),math.rad(0+math.rad(0+2*math.cos(sine/2))),0), 0.1)
1303
hed.Weld.C1 = Lerp(hed.Weld.C1, CFrame.Angles(math.rad(-10),0,0),0.1)
1304
rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5,0.62-(movement/30)*math.cos(sine/4)/2,(movement/50)*math.cos(sine/4))*CFrame.Angles(math.rad(-5-(movement*2)*math.cos(sine/4))+ -(movement/10)*math.sin(sine/4),math.rad(0-(movement*2)*math.cos(sine/4)),math.rad(0)), 0.2)
1305
larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.5,0.62+(movement/30)*math.cos(sine/4)/2,-(movement/50)*math.cos(sine/4))*CFrame.Angles(math.rad(-5+(movement*2)*math.cos(sine/4))+ (movement/10)*math.sin(sine/4),math.rad(0-(movement*2)*math.cos(sine/4)),math.rad(0)), 0.2)
1306
torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1+(movement/20)*math.cos(sine/2), 0) * CFrame.Angles(math.rad(-(change*20)-4*math.cos(sine/2)), torsorotY2+math.rad(0-4*math.cos(sine/4)), torsorotY2+math.rad(0-1*math.cos(sine/4))), 0.1)
1307
lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5,-0.85-(movement/10)*math.cos(sine/4)/2,-0.1+(movement/15)*math.cos(sine/4))*CFrame.Angles(math.rad(-10+(change*5)-movement*math.cos(sine/4))+ -(movement/10)*math.sin(sine/4),math.rad(0+(movement*2)*math.cos(sine/4)),math.rad(0)), 0.2)
1308
rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5,-0.85+(movement/10)*math.cos(sine/4)/2,-0.1-(movement/15)*math.cos(sine/4))*CFrame.Angles(math.rad(-10+(change*5)+movement*math.cos(sine/4))+ (movement/10)*math.sin(sine/4),math.rad(0+(movement*2)*math.cos(sine/4)),math.rad(0)), 0.2)
1309
elseif jumped == true then
1310
hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5,-.2)*CFrame.Angles(math.rad(-18),math.rad(0+math.rad(0+2*math.cos(sine/2))),0), 0.1)
1311
hed.Weld.C1 = Lerp(hed.Weld.C1, CFrame.Angles(0,0,0),0.1)
1312
larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.5,1-0.1*math.cos(sine/16)/2,0.1*math.cos(sine/16))*CFrame.Angles(math.rad(0),math.rad(0-1*math.cos(sine/16)),math.rad(-50-1*math.cos(sine/8))), 0.2)
1313
rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5,1-0.1*math.cos(sine/16)/2,0.1*math.cos(sine/16))*CFrame.Angles(math.rad(0),math.rad(0-1*math.cos(sine/16)),math.rad(50+1*math.cos(sine/8))), 0.2)
1314
torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1-0.1*math.cos(sine/16), 0) * CFrame.Angles(math.rad(0-2*math.cos(sine/16)),math.rad(0), math.rad(0-1*math.cos(sine/32))), 0.1)
1315
lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(-0.5,-0.925+0.1*math.cos(sine/16),0)*CFrame.Angles(math.rad(-35-1*math.cos(sine/16)),math.rad(0-1*math.cos(sine/16)),math.rad(-2-0.5*math.cos(sine/8))), 0.2)
1316
rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0.5,0+0.1*math.cos(sine/16),-0.8)*CFrame.Angles(math.rad(-25+1*math.cos(sine/16)),math.rad(0-1*math.cos(sine/16)),math.rad(2+0.5*math.cos(sine/8))), 0.2)
1317
elseif (torso.Velocity*Vector3.new(1, 0, 1)).magnitude < 5 then
1318
hed.Weld.C0 = Lerp(hed.Weld.C0, CFrame.new(0,1.5,-.1)*CFrame.Angles(math.rad(-18),math.rad(0+math.rad(0+2*math.cos(sine/2))),0), 0.1)
1319
hed.Weld.C1 = Lerp(hed.Weld.C1, CFrame.Angles(math.rad(-15),0,0),0.1)
1320
larm.Weld.C0 = Lerp(larm.Weld.C0, CFrame.new(-1.5,0.55-0.1*math.cos(sine/16)/2,-0.1*math.cos(sine/16))*CFrame.Angles(math.rad(0),math.rad(0-1*math.cos(sine/16)),math.rad(-5-1*math.cos(sine/8))), 0.2)
1321
rarm.Weld.C0 = Lerp(rarm.Weld.C0, CFrame.new(1.5,0.55-0.1*math.cos(sine/16)/2,-0.1*math.cos(sine/16))*CFrame.Angles(math.rad(0),math.rad(0-1*math.cos(sine/16)),math.rad(5+1*math.cos(sine/8))), 0.2)
1322
torso.Weld.C0 = Lerp(torso.Weld.C0, CFrame.new(0, -1.1-0.1*math.cos(sine/16), 0) * CFrame.Angles(math.rad(0-2*math.cos(sine/16)),math.rad(0), math.rad(0-1*math.cos(sine/32))), 0.1)
1323
lleg.Weld.C0 = Lerp(lleg.Weld.C0, CFrame.new(0,llegendPoint.Y-lleg.Position.Y,0)*CFrame.new(-0.5,0+0.1*math.cos(sine/16),0)*CFrame.Angles(math.rad(0-1*math.cos(sine/16)),math.rad(0-1*math.cos(sine/16)),math.rad(-2-0.5*math.cos(sine/8))), 0.2)
1324
rleg.Weld.C0 = Lerp(rleg.Weld.C0, CFrame.new(0,rlegendPoint.Y-rleg.Position.Y,0)*CFrame.new(0.5,0+0.1*math.cos(sine/16),0)*CFrame.Angles(math.rad(0+1*math.cos(sine/16)),math.rad(0-1*math.cos(sine/16)),math.rad(2+0.5*math.cos(sine/8))), 0.2)
1325
end
1326
for i=1,5 do
1327
if aiming_anim == true then
1328
bg.MaxTorque = Vector3.new(9e9,9e9,9e9)
1329
if jumped == false then
1330
bg.CFrame = CFrame.new(root.Position,Vector3.new(mouse.Hit.x,root.Position.Y,mouse.Hit.z))
1331
else
1332
bg.CFrame = CFrame.new(root.Position,mouse.Hit.p)
1333
end
1334
if animid == 0 then
1335
hed.Weld.C1 =  Lerp(hed.Weld.C1,CFrame.Angles(0,math.rad(-80),0),0.4)
1336
torso.Weld.C0 = Lerp(torso.Weld.C0,CFrame.new(0, -1.1-0.1*math.cos(sine/16), 0) * CFrame.Angles(math.rad(0-2*math.cos(sine/16)),math.rad(-80), math.rad(0-1*math.cos(sine/32))),0.2)
1337
larm.Weld.C0 = Lerp(larm.Weld.C0,CFrame.new(-1.5,0.55-0.1*math.cos(sine/16)/2,-0.1*math.cos(sine/16))*CFrame.Angles(math.rad(0),math.rad(-10-1*math.cos(sine/16)),math.rad(-90-1*math.cos(sine/8))),0.4)
1338
else
1339
hed.Weld.C1 =  Lerp(hed.Weld.C1,CFrame.Angles(0,math.rad(80),0),0.4)
1340
torso.Weld.C0 = Lerp(torso.Weld.C0,CFrame.new(0, -1.1-0.1*math.cos(sine/16), 0) * CFrame.Angles(math.rad(0-2*math.cos(sine/16)),math.rad(80), math.rad(0-1*math.cos(sine/32))),0.2)
1341
rarm.Weld.C0 = Lerp(rarm.Weld.C0,CFrame.new(1.5,0.55-0.1*math.cos(sine/16)/2,-0.1*math.cos(sine/16))*CFrame.Angles(math.rad(0),math.rad(10-1*math.cos(sine/16)),math.rad(90+1*math.cos(sine/8))),0.4)
1342
end
1343
else
1344
if timer <= 0 then
1345
animid = math.random(0,1)
1346
else
1347
timer = timer - 1
1348
end
1349
end
1350
end
1351
end
1352
end
1353
if hum.Health <= 0 then
1354-
pr.Value = main.r
1354+
1355-
pg.Value = main.g
1355+
1356-
pb.Value = main.b
1356+