Advertisement
memberhero

Starlight Filtering Enabled

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