Advertisement
Zebula_The_Scripter

Common Core

Sep 8th, 2018
338
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 82.39 KB | None | 0 0
  1. if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
  2. local Player,Mouse,mouse,UserInputService,ContextActionService = owner
  3. do
  4. print("FE Compatibility code by Mokiros")
  5. script.Parent = Player.Character
  6.  
  7. --RemoteEvent for communicating
  8. local Event = Instance.new("RemoteEvent")
  9. Event.Name = "UserInput_Event"
  10.  
  11. --Fake event to make stuff like Mouse.KeyDown work
  12. local function fakeEvent()
  13. local t = {_fakeEvent=true,Connect=function(self,f)self.Function=f end}
  14. t.connect = t.Connect
  15. return t
  16. end
  17.  
  18. --Creating fake input objects with fake variables
  19. local m = {Target=nil,Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent()}
  20. local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()}
  21. local CAS = {Actions={},BindAction=function(self,name,fun,touch,...)
  22. CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil
  23. end}
  24. --Merged 2 functions into one by checking amount of arguments
  25. CAS.UnbindAction = CAS.BindAction
  26.  
  27. --This function will trigger the events that have been :Connect()'ed
  28. local function te(self,ev,...)
  29. local t = m[ev]
  30. if t and t._fakeEvent and t.Function then
  31. t.Function(...)
  32. end
  33. end
  34. m.TrigEvent = te
  35. UIS.TrigEvent = te
  36.  
  37. Event.OnServerEvent:Connect(function(plr,io)
  38. if plr~=Player then return end
  39. if io.isMouse then
  40. m.Target = io.Target
  41. m.Hit = io.Hit
  42. else
  43. local b = io.UserInputState == Enum.UserInputState.Begin
  44. if io.UserInputType == Enum.UserInputType.MouseButton1 then
  45. return m:TrigEvent(b and "Button1Down" or "Button1Up")
  46. end
  47. for _,t in pairs(CAS.Actions) do
  48. for _,k in pairs(t.Keys) do
  49. if k==io.KeyCode then
  50. t.Function(t.Name,io.UserInputState,io)
  51. end
  52. end
  53. end
  54. m:TrigEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower())
  55. UIS:TrigEvent(b and "InputBegan" or "InputEnded",io,false)
  56. end
  57. end)
  58. Event.Parent = NLS([==[
  59. local Player = game:GetService("Players").LocalPlayer
  60. local Event = script:WaitForChild("UserInput_Event")
  61.  
  62. local UIS = game:GetService("UserInputService")
  63. local input = function(io,a)
  64. if a then return end
  65. --Since InputObject is a client-side instance, we create and pass table instead
  66. Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState})
  67. end
  68. UIS.InputBegan:Connect(input)
  69. UIS.InputEnded:Connect(input)
  70.  
  71. local Mouse = Player:GetMouse()
  72. local h,t
  73. --Give the server mouse data 30 times every second, but only if the values changed
  74. --If player is not moving their mouse, client won't fire events
  75. while wait(1/30) do
  76. if h~=Mouse.Hit or t~=Mouse.Target then
  77. h,t=Mouse.Hit,Mouse.Target
  78. Event:FireServer({isMouse=true,Target=t,Hit=h})
  79. end
  80. end]==],Player.Character)
  81. Mouse,mouse,UserInputService,ContextActionService = m,m,UIS,CAS
  82. end
  83.  
  84. --//====================================================\\--
  85. --|| CREATED BY SHACKLUSTER
  86. --\\====================================================//--
  87.  
  88.  
  89.  
  90. wait(0.2)
  91.  
  92.  
  93.  
  94. Player = owner
  95. PlayerGui = Player.PlayerGui
  96. Cam = workspace.CurrentCamera
  97. Backpack = Player.Backpack
  98. Character = Player.Character
  99. Humanoid = Character.Humanoid
  100. RootPart = Character["HumanoidRootPart"]
  101. Torso = Character["Torso"]
  102. Head = Character["Head"]
  103. RightArm = Character["Right Arm"]
  104. LeftArm = Character["Left Arm"]
  105. RightLeg = Character["Right Leg"]
  106. LeftLeg = Character["Left Leg"]
  107. RootJoint = RootPart["RootJoint"]
  108. Neck = Torso["Neck"]
  109. RightShoulder = Torso["Right Shoulder"]
  110. LeftShoulder = Torso["Left Shoulder"]
  111. RightHip = Torso["Right Hip"]
  112. LeftHip = Torso["Left Hip"]
  113.  
  114. IT = Instance.new
  115. CF = CFrame.new
  116. VT = Vector3.new
  117. RAD = math.rad
  118. C3 = Color3.new
  119. UD2 = UDim2.new
  120. BRICKC = BrickColor.new
  121. ANGLES = CFrame.Angles
  122. EULER = CFrame.fromEulerAnglesXYZ
  123. COS = math.cos
  124. ACOS = math.acos
  125. SIN = math.sin
  126. ASIN = math.asin
  127. ABS = math.abs
  128. MRANDOM = math.random
  129. FLOOR = math.floor
  130.  
  131. function CreateMesh(MESH, PARENT, MESHTYPE, MESHID, TEXTUREID, SCALE, OFFSET)
  132. local NEWMESH = IT(MESH)
  133. if MESH == "SpecialMesh" then
  134. NEWMESH.MeshType = MESHTYPE
  135. if MESHID ~= "nil" and MESHID ~= "" then
  136. NEWMESH.MeshId = "http://www.roblox.com/asset/?id="..MESHID
  137. end
  138. if TEXTUREID ~= "nil" and TEXTUREID ~= "" then
  139. NEWMESH.TextureId = "http://www.roblox.com/asset/?id="..TEXTUREID
  140. end
  141. end
  142. NEWMESH.Offset = OFFSET or VT(0, 0, 0)
  143. NEWMESH.Scale = SCALE
  144. NEWMESH.Parent = PARENT
  145. return NEWMESH
  146. end
  147.  
  148. function CreatePart(FORMFACTOR, PARENT, MATERIAL, REFLECTANCE, TRANSPARENCY, BRICKCOLOR, NAME, SIZE)
  149. local NEWPART = IT("Part")
  150. NEWPART.formFactor = FORMFACTOR
  151. NEWPART.Reflectance = REFLECTANCE
  152. NEWPART.Transparency = TRANSPARENCY
  153. NEWPART.CanCollide = false
  154. NEWPART.Locked = true
  155. NEWPART.BrickColor = BRICKC(tostring(BRICKCOLOR))
  156. NEWPART.Name = NAME
  157. NEWPART.Size = SIZE
  158. NEWPART.Position = Torso.Position
  159. NEWPART.Material = MATERIAL
  160. NEWPART:BreakJoints()
  161. NEWPART.Parent = PARENT
  162. return NEWPART
  163. end
  164.  
  165.  
  166. --//=================================\\
  167. --|| CUSTOMIZATION
  168. --\\=================================//
  169.  
  170. Class_Name = "Sharpshooter"
  171. Weapon_Name = "Add-ons"
  172.  
  173. Custom_Color_1 = BRICKC("Dark indigo"); --1st color for the weapon.
  174. Custom_Color_2 = BRICKC("Dark indigo"); --2nd color for the weapon.
  175.  
  176. Custom_Color_3 = BRICKC("Dark indigo"); --Color for the abilities.
  177. Custom_Color_4 = BRICKC("Dark indigo"); --Color for the secondary bar.
  178. Custom_Color_5 = BRICKC("Dark indigo"); --Color for the mana bar.
  179. Custom_Color_6 = BRICKC("Dark indigo"); --Color for the health bar.
  180. Custom_Color_7 = BRICKC("Dark indigo"); --Color for the stun bar.
  181.  
  182. Custom_Color_8 = BRICKC("Dark indigo"); --Background for the mana bar.
  183. Custom_Color_9 = BRICKC("Dark indigo"); --Background for the secondary mana bar.
  184. Custom_Color_10 = BRICKC("Dark indigo"); --Background for the stun bar.
  185. Custom_Color_11 = BRICKC("Dark indigo"); --Background for the health bar.
  186. Custom_Color_12 = BRICKC("Dark indigo"); --Background for the abilities.
  187.  
  188.  
  189. Player_Size = 1 --Size of the player.
  190. Animation_Speed = 3
  191. Frame_Speed = 1 / 60 -- (1 / 30) OR (1 / 60)
  192.  
  193. local Speed = 16
  194. local Effects2 = {}
  195.  
  196. --//=================================\\
  197. --|| END OF CUSTOMIZATION
  198. --\\=================================//
  199.  
  200. local function weldBetween(a, b)
  201. local weldd = Instance.new("ManualWeld")
  202. weldd.Part0 = a
  203. weldd.Part1 = b
  204. weldd.C0 = CFrame.new()
  205. weldd.C1 = b.CFrame:inverse() * a.CFrame
  206. weldd.Parent = a
  207. return weldd
  208. end
  209.  
  210. function createaccessory(attachmentpart,mesh,texture,scale,offset,color)
  211. local acs = Instance.new("Part")
  212. acs.CanCollide = false
  213. acs.Anchored = false
  214. acs.Size = Vector3.new(0,0,0)
  215. acs.CFrame = attachmentpart.CFrame
  216. acs.Parent = Character
  217. acs.BrickColor = color
  218. local meshs = Instance.new("SpecialMesh")
  219. meshs.MeshId = mesh
  220. meshs.TextureId = texture
  221. meshs.Parent = acs
  222. meshs.Scale = scale
  223. meshs.Offset = offset
  224. weldBetween(attachmentpart,acs)
  225. end
  226.  
  227. function createbodypart(TYPE,COLOR,PART,OFFSET,SIZE)
  228. if TYPE == "Gem" then
  229. local acs = CreatePart(3, Character, "Plastic", 0, 0, COLOR, "Part", VT(0,0,0))
  230. acs.Anchored = false
  231. acs.CanCollide = false
  232. acs.CFrame = PART.CFrame
  233. local acs2 = CreateMesh("SpecialMesh", acs, "FileMesh", "9756362", "", SIZE, OFFSET)
  234. weldBetween(PART,acs)
  235. elseif TYPE == "Skull" then
  236. local acs = CreatePart(3, Character, "Plastic", 0, 0, COLOR, "Part", VT(0,0,0))
  237. acs.Anchored = false
  238. acs.CanCollide = false
  239. acs.CFrame = PART.CFrame
  240. local acs2 = CreateMesh("SpecialMesh", acs, "FileMesh", "4770583", "", SIZE, OFFSET)
  241. weldBetween(PART,acs)
  242. elseif TYPE == "Eye" then
  243. local acs = CreatePart(3, Character, "Neon", 0, 0, COLOR, "Part", VT(0,0,0))
  244. acs.Anchored = false
  245. acs.CanCollide = false
  246. acs.CFrame = PART.CFrame
  247. local acs2 = CreateMesh("SpecialMesh", acs, "Sphere", "", "", SIZE, OFFSET)
  248. weldBetween(PART,acs)
  249. end
  250. end
  251.  
  252. --//=================================\\
  253. --|| USEFUL VALUES
  254. --\\=================================//
  255.  
  256. local ROOTC0 = CF(0, 0, 0) * ANGLES(RAD(-90), RAD(0), RAD(180))
  257. local NECKC0 = CF(0, 1, 0) * ANGLES(RAD(-90), RAD(0), RAD(180))
  258. local RIGHTSHOULDERC0 = CF(-0.5, 0, 0) * ANGLES(RAD(0), RAD(90), RAD(0))
  259. local LEFTSHOULDERC0 = CF(0.5, 0, 0) * ANGLES(RAD(0), RAD(-90), RAD(0))
  260. local CO1 = 0
  261. local CO2 = 0
  262. local CO3 = 0
  263. local CO4 = 0
  264. local CHANGEDEFENSE = 0
  265. local CHANGEDAMAGE = 0
  266. local CHANGEMOVEMENT = 0
  267. local ANIM = "Idle"
  268. local ATTACK = false
  269. local EQUIPPED = false
  270. local HOLD = false
  271. local COMBO = 1
  272. local LASTPOINT = nil
  273. local BLCF = nil
  274. local SCFR = nil
  275. local STAGGERHITANIM = false
  276. local STAGGERANIM = false
  277. local SPRINTING = false
  278. local STUNANIM = false
  279. local CRITCHANCENUMBER = 0
  280. local IDLENUMBER = 0
  281. local DONUMBER = 0
  282. local HANDIDLE = false
  283. local SINE = 0
  284. local CHANGE = 2 / Animation_Speed
  285. local WALKINGANIM = false
  286. local WALK = 0
  287. local DISABLEJUMPING = false
  288. local HASBEENBLOCKED = false
  289. local STUNDELAYNUMBER = 0
  290. local MANADELAYNUMBER = 0
  291. local SECONDARYMANADELAYNUMBER = 0
  292. local KEYHOLD = false
  293. local ROBLOXIDLEANIMATION = IT("Animation")
  294. ROBLOXIDLEANIMATION.Name = "Roblox Idle Animation"
  295. ROBLOXIDLEANIMATION.AnimationId = "http://www.roblox.com/asset/?id=180435571"
  296. --ROBLOXIDLEANIMATION.Parent = Humanoid
  297. local WEAPONGUI = IT("ScreenGui", nil)
  298. WEAPONGUI.Name = "Weapon GUI"
  299. local WEAPONTOOL = IT("HopperBin", nil)
  300. WEAPONTOOL.Name = Weapon_Name
  301. local Weapon = IT("Model")
  302. Weapon.Name = Weapon_Name
  303. local Effects = IT("Folder", Weapon)
  304. Effects.Name = "Effects"
  305. local ANIMATOR = Humanoid.Animator
  306. local ANIMATE = Character.Animate
  307. local HITPLAYERSOUNDS = {--[["199149137", "199149186", "199149221", "199149235", "199149269", "199149297"--]]"263032172", "263032182", "263032200", "263032221", "263032252", "263033191"}
  308. local HITARMORSOUNDS = {"199149321", "199149338", "199149367", "199149409", "199149452"}
  309. local HITWEAPONSOUNDS = {"199148971", "199149025", "199149072", "199149109", "199149119"}
  310. local HITBLOCKSOUNDS = {"199148933", "199148947"}
  311. local UNANCHOR = true
  312.  
  313. --//=================================\\
  314. --\\=================================//
  315.  
  316.  
  317.  
  318.  
  319. --//=================================\\
  320. --|| DEBUFFS / BUFFS
  321. --\\=================================//
  322.  
  323. local DEFENSECHANGE1 = IT("NumberValue", ChangeStat)
  324. DEFENSECHANGE1.Name = "ChangeDefense"
  325. DEFENSECHANGE1.Value = 0
  326.  
  327. local MOVEMENTCHANGE1 = IT("NumberValue", nil)
  328. MOVEMENTCHANGE1.Name = "ChangeMovement"
  329. MOVEMENTCHANGE1.Value = 0
  330.  
  331. --//=================================\\
  332. --\\=================================//
  333.  
  334.  
  335.  
  336.  
  337.  
  338. --//=================================\\
  339. --|| SAZERENOS' ARTIFICIAL HEARTBEAT
  340. --\\=================================//
  341.  
  342. ArtificialHB = Instance.new("BindableEvent", script)
  343. ArtificialHB.Name = "ArtificialHB"
  344.  
  345. script:WaitForChild("ArtificialHB")
  346.  
  347. frame = Frame_Speed
  348. tf = 0
  349. allowframeloss = false
  350. tossremainder = false
  351. lastframe = tick()
  352. script.ArtificialHB:Fire()
  353.  
  354. game:GetService("RunService").Heartbeat:connect(function(s, p)
  355. tf = tf + s
  356. if tf >= frame then
  357. if allowframeloss then
  358. script.ArtificialHB:Fire()
  359. lastframe = tick()
  360. else
  361. for i = 1, math.floor(tf / frame) do
  362. script.ArtificialHB:Fire()
  363. end
  364. lastframe = tick()
  365. end
  366. if tossremainder then
  367. tf = 0
  368. else
  369. tf = tf - frame * math.floor(tf / frame)
  370. end
  371. end
  372. end)
  373.  
  374. --//=================================\\
  375. --\\=================================//
  376.  
  377.  
  378.  
  379.  
  380.  
  381. --//=================================\\
  382. --|| SOME FUNCTIONS
  383. --\\=================================//
  384.  
  385. function Raycast(POSITION, DIRECTION, RANGE, IGNOREDECENDANTS)
  386. return workspace:FindPartOnRay(Ray.new(POSITION, DIRECTION.unit * RANGE), IGNOREDECENDANTS)
  387. end
  388.  
  389. function PositiveAngle(NUMBER)
  390. if NUMBER >= 0 then
  391. NUMBER = 0
  392. end
  393. return NUMBER
  394. end
  395.  
  396. function NegativeAngle(NUMBER)
  397. if NUMBER <= 0 then
  398. NUMBER = 0
  399. end
  400. return NUMBER
  401. end
  402.  
  403. function Swait(NUMBER)
  404. if NUMBER == 0 or NUMBER == nil then
  405. ArtificialHB.Event:wait()
  406. else
  407. for i = 1, NUMBER do
  408. ArtificialHB.Event:wait()
  409. end
  410. end
  411. end
  412.  
  413. function QuaternionFromCFrame(cf)
  414. local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components()
  415. local trace = m00 + m11 + m22
  416. if trace > 0 then
  417. local s = math.sqrt(1 + trace)
  418. local recip = 0.5 / s
  419. return (m21 - m12) * recip, (m02 - m20) * recip, (m10 - m01) * recip, s * 0.5
  420. else
  421. local i = 0
  422. if m11 > m00 then
  423. i = 1
  424. end
  425. if m22 > (i == 0 and m00 or m11) then
  426. i = 2
  427. end
  428. if i == 0 then
  429. local s = math.sqrt(m00 - m11 - m22 + 1)
  430. local recip = 0.5 / s
  431. return 0.5 * s, (m10 + m01) * recip, (m20 + m02) * recip, (m21 - m12) * recip
  432. elseif i == 1 then
  433. local s = math.sqrt(m11 - m22 - m00 + 1)
  434. local recip = 0.5 / s
  435. return (m01 + m10) * recip, 0.5 * s, (m21 + m12) * recip, (m02 - m20) * recip
  436. elseif i == 2 then
  437. local s = math.sqrt(m22 - m00 - m11 + 1)
  438. local recip = 0.5 / s return (m02 + m20) * recip, (m12 + m21) * recip, 0.5 * s, (m10 - m01) * recip
  439. end
  440. end
  441. end
  442.  
  443. function QuaternionToCFrame(px, py, pz, x, y, z, w)
  444. local xs, ys, zs = x + x, y + y, z + z
  445. local wx, wy, wz = w * xs, w * ys, w * zs
  446. local xx = x * xs
  447. local xy = x * ys
  448. local xz = x * zs
  449. local yy = y * ys
  450. local yz = y * zs
  451. local zz = z * zs
  452. return CFrame.new(px, py, pz, 1 - (yy + zz), xy - wz, xz + wy, xy + wz, 1 - (xx + zz), yz - wx, xz - wy, yz + wx, 1 - (xx + yy))
  453. end
  454.  
  455. function QuaternionSlerp(a, b, t)
  456. local cosTheta = a[1] * b[1] + a[2] * b[2] + a[3] * b[3] + a[4] * b[4]
  457. local startInterp, finishInterp;
  458. if cosTheta >= 0.0001 then
  459. if (1 - cosTheta) > 0.0001 then
  460. local theta = ACOS(cosTheta)
  461. local invSinTheta = 1 / SIN(theta)
  462. startInterp = SIN((1 - t) * theta) * invSinTheta
  463. finishInterp = SIN(t * theta) * invSinTheta
  464. else
  465. startInterp = 1 - t
  466. finishInterp = t
  467. end
  468. else
  469. if (1 + cosTheta) > 0.0001 then
  470. local theta = ACOS(-cosTheta)
  471. local invSinTheta = 1 / SIN(theta)
  472. startInterp = SIN((t - 1) * theta) * invSinTheta
  473. finishInterp = SIN(t * theta) * invSinTheta
  474. else
  475. startInterp = t - 1
  476. finishInterp = t
  477. end
  478. end
  479. return a[1] * startInterp + b[1] * finishInterp, a[2] * startInterp + b[2] * finishInterp, a[3] * startInterp + b[3] * finishInterp, a[4] * startInterp + b[4] * finishInterp
  480. end
  481.  
  482. function Clerp(a, b, t)
  483. local qa = {QuaternionFromCFrame(a)}
  484. local qb = {QuaternionFromCFrame(b)}
  485. local ax, ay, az = a.x, a.y, a.z
  486. local bx, by, bz = b.x, b.y, b.z
  487. local _t = 1 - t
  488. return QuaternionToCFrame(_t * ax + t * bx, _t * ay + t * by, _t * az + t * bz, QuaternionSlerp(qa, qb, t))
  489. end
  490.  
  491. function CreateFrame(PARENT, TRANSPARENCY, BORDERSIZEPIXEL, POSITION, SIZE, COLOR, BORDERCOLOR, NAME)
  492. local frame = IT("Frame")
  493. frame.BackgroundTransparency = TRANSPARENCY
  494. frame.BorderSizePixel = BORDERSIZEPIXEL
  495. frame.Position = POSITION
  496. frame.Size = SIZE
  497. frame.BackgroundColor3 = COLOR
  498. frame.BorderColor3 = BORDERCOLOR
  499. frame.Name = NAME
  500. frame.Parent = PARENT
  501. return frame
  502. end
  503.  
  504. function CreateLabel(PARENT, TEXT, TEXTCOLOR, TEXTFONTSIZE, TEXTFONT, TRANSPARENCY, BORDERSIZEPIXEL, STROKETRANSPARENCY, NAME)
  505. local label = IT("TextLabel")
  506. label.BackgroundTransparency = 1
  507. label.Size = UD2(1, 0, 1, 0)
  508. label.Position = UD2(0, 0, 0, 0)
  509. label.TextColor3 = C3(255, 255, 255)
  510. label.TextStrokeTransparency = STROKETRANSPARENCY
  511. label.TextTransparency = TRANSPARENCY
  512. label.FontSize = TEXTFONTSIZE
  513. label.Font = TEXTFONT
  514. label.BorderSizePixel = BORDERSIZEPIXEL
  515. label.TextScaled = true
  516. label.Text = TEXT
  517. label.Name = NAME
  518. label.Parent = PARENT
  519. return label
  520. end
  521.  
  522. function NoOutlines(PART)
  523. PART.TopSurface, PART.BottomSurface, PART.LeftSurface, PART.RightSurface, PART.FrontSurface, PART.BackSurface = 10, 10, 10, 10, 10, 10
  524. end
  525.  
  526.  
  527. function CreateWeldOrSnapOrMotor(TYPE, PARENT, PART0, PART1, C0, C1)
  528. local NEWWELD = IT(TYPE)
  529. NEWWELD.Part0 = PART0
  530. NEWWELD.Part1 = PART1
  531. NEWWELD.C0 = C0
  532. NEWWELD.C1 = C1
  533. NEWWELD.Parent = PARENT
  534. return NEWWELD
  535. end
  536.  
  537. function CreateSound(ID, PARENT, VOLUME, PITCH)
  538. coroutine.resume(coroutine.create(function()
  539. local NEWSOUND = IT("Sound", PARENT)
  540. NEWSOUND.Volume = VOLUME
  541. NEWSOUND.Pitch = PITCH
  542. NEWSOUND.SoundId = "http://www.roblox.com/asset/?id="..ID
  543. Swait()
  544. NEWSOUND:play()
  545. game:GetService("Debris"):AddItem(NEWSOUND, 10)
  546. end))
  547. end
  548.  
  549. function CFrameFromTopBack(at, top, back)
  550. local right = top:Cross(back)
  551. return CF(at.x, at.y, at.z, right.x, top.x, back.x, right.y, top.y, back.y, right.z, top.z, back.z)
  552. end
  553.  
  554. function Lightning(POSITION1, POSITION2, MULTIPLIERTIME, LIGHTNINGDELAY, OFFSET, BRICKCOLOR, MATERIAL, SIZE, TRANSPARENCY, LASTINGTIME)
  555. local MAGNITUDE = (POSITION1 - POSITION2).magnitude
  556. local CURRENTPOSITION = POSITION1
  557. local LIGHTNINGOFFSET = {-OFFSET, OFFSET}
  558. coroutine.resume(coroutine.create(function()
  559. for i = 1, MULTIPLIERTIME do
  560. local LIGHTNINGPART = CreatePart(3, Effects, MATERIAL, 0, 0, BRICKCOLOR,"Effect", VT(SIZE * Player_Size, SIZE * Player_Size, MAGNITUDE / MULTIPLIERTIME))
  561. LIGHTNINGPART.Anchored = true
  562. local LIGHTNINGOFFSET2 = VT(LIGHTNINGOFFSET[MRANDOM(1, 2)], LIGHTNINGOFFSET[MRANDOM(1, 2)], LIGHTNINGOFFSET[MRANDOM(1, 2)])
  563. local LIGHTNINGPOSITION1 = CF(CURRENTPOSITION, POSITION2) * CF(0, 0, MAGNITUDE / MULTIPLIERTIME).p + LIGHTNINGOFFSET2
  564. if MULTIPLIERTIME == i then
  565. local LIGHTNINGMAGNITUDE1 = (CURRENTPOSITION - POSITION2).magnitude
  566. LIGHTNINGPART.Size = VT(SIZE * Player_Size, SIZE * Player_Size, LIGHTNINGMAGNITUDE1)
  567. LIGHTNINGPART.CFrame = CF(CURRENTPOSITION, POSITION2) * CF(0, 0, -LIGHTNINGMAGNITUDE1 / 2)
  568. else
  569. LIGHTNINGPART.CFrame = CF(CURRENTPOSITION, LIGHTNINGPOSITION1) * CF(0, 0, MAGNITUDE / MULTIPLIERTIME / 2)
  570. end
  571. CURRENTPOSITION=LIGHTNINGPART.CFrame * CF(0, 0, MAGNITUDE / MULTIPLIERTIME / 2).p
  572. game.Debris:AddItem(LIGHTNINGPART, LASTINGTIME)
  573. coroutine.resume(coroutine.create(function()
  574. while LIGHTNINGPART.Transparency ~= 1 do
  575. --local StartTransparency = tra
  576. for i=0, 1, LASTINGTIME do
  577. Swait()
  578. LIGHTNINGPART.Transparency = LIGHTNINGPART.Transparency + (0.1 / LASTINGTIME)
  579. end
  580. end
  581. end))
  582. Swait(LIGHTNINGDELAY / Animation_Speed)
  583. end
  584. end))
  585. end
  586.  
  587. function MagicBlock(BRICKCOLOR, MATERIAL, CFRAME, ROTATION, OFFSET, X1, Y1, Z1, X2, Y2, Z2, delay)
  588. local EFFECTPART = CreatePart(3, Effects, MATERIAL, 0, 0, BRICKCOLOR, "Effect", VT())
  589. EFFECTPART.Anchored = true
  590. EFFECTPART.CFrame = CFRAME
  591. local EFFECTMESH = CreateMesh("BlockMesh", EFFECTPART, "", "", "", VT(X1 * Player_Size, Y1 * Player_Size, Z1 * Player_Size), OFFSET * Player_Size)
  592. game:GetService("Debris"):AddItem(EFFECTPART, 10)
  593. coroutine.resume(coroutine.create(function(PART, MESH)
  594. for i = 0, 1, delay do
  595. Swait()
  596. PART.CFrame = PART.CFrame * ROTATION
  597. PART.Transparency = i
  598. MESH.Scale = MESH.Scale + VT(X2 * Player_Size, Y2 * Player_Size, Z2 * Player_Size)
  599. end
  600. PART.Parent = nil
  601. end), EFFECTPART, EFFECTMESH)
  602. end
  603.  
  604. function MagicSphere(BRICKCOLOR, MATERIAL, CFRAME, ROTATION, OFFSET, X1, Y1, Z1, X2, Y2, Z2, delay)
  605. local EFFECTPART = CreatePart(3, Effects, MATERIAL, 0, 0, BRICKCOLOR, "Effect", VT())
  606. EFFECTPART.Anchored = true
  607. EFFECTPART.CFrame = CFRAME
  608. local EFFECTMESH = CreateMesh("SpecialMesh", EFFECTPART, "Sphere", "", "", VT(X1 * Player_Size, Y1 * Player_Size, Z1 * Player_Size), OFFSET * Player_Size)
  609. game:GetService("Debris"):AddItem(EFFECTPART, 10)
  610. coroutine.resume(coroutine.create(function(PART, MESH)
  611. for i = 0, 1, delay do
  612. Swait()
  613. PART.CFrame = PART.CFrame * ROTATION
  614. PART.Transparency = i
  615. MESH.Scale = MESH.Scale + VT(X2 * Player_Size, Y2 * Player_Size, Z2 * Player_Size)
  616. end
  617. PART.Parent = nil
  618. end), EFFECTPART, EFFECTMESH)
  619. end
  620.  
  621. function MagicCylinder(BRICKCOLOR, MATERIAL, CFRAME, ROTATION, OFFSET, X1, Y1, Z1, X2, Y2, Z2, delay)
  622. local EFFECTPART = CreatePart(3, Effects, MATERIAL, 0, 0, BRICKCOLOR, "Effect", VT())
  623. EFFECTPART.Anchored = true
  624. EFFECTPART.CFrame = CFRAME
  625. local EFFECTMESH = CreateMesh("CylinderMesh", EFFECTPART, "", "", "", VT(X1 * Player_Size, Y1 * Player_Size, Z1 * Player_Size), OFFSET * Player_Size)
  626. game:GetService("Debris"):AddItem(EFFECTPART, 10)
  627. coroutine.resume(coroutine.create(function(PART, MESH)
  628. for i = 0, 1, delay do
  629. Swait()
  630. PART.CFrame = PART.CFrame * ROTATION
  631. PART.Transparency = i
  632. MESH.Scale = MESH.Scale + VT(X2 * Player_Size, Y2 * Player_Size, Z2 * Player_Size)
  633. end
  634. PART.Parent = nil
  635. end), EFFECTPART, EFFECTMESH)
  636. end
  637.  
  638. function MagicHead(BRICKCOLOR, MATERIAL, CFRAME, ROTATION, OFFSET, X1, Y1, Z1, X2, Y2, Z2, delay)
  639. local EFFECTPART = CreatePart(3, Effects, MATERIAL, 0, 0, BRICKCOLOR, "Effect", VT())
  640. EFFECTPART.Anchored = true
  641. EFFECTPART.CFrame = CFRAME
  642. local EFFECTMESH = CreateMesh("SpecialMesh", EFFECTPART, "Head", "", "", VT(X1 * Player_Size, Y1 * Player_Size, Z1 * Player_Size), OFFSET * Player_Size)
  643. game:GetService("Debris"):AddItem(EFFECTPART, 10)
  644. coroutine.resume(coroutine.create(function(PART, MESH)
  645. for i = 0, 1, delay do
  646. Swait()
  647. PART.CFrame = PART.CFrame * ROTATION
  648. PART.Transparency = i
  649. MESH.Scale = MESH.Scale + VT(X2 * Player_Size, Y2 * Player_Size, Z2 * Player_Size)
  650. end
  651. PART.Parent = nil
  652. end), EFFECTPART, EFFECTMESH)
  653. end
  654.  
  655. function MagicRing(BRICKCOLOR, MATERIAL, CFRAME, ROTATION, OFFSET, X1, Y1, Z1, X2, Y2, Z2, delay)
  656. local EFFECTPART = CreatePart(3, Effects, MATERIAL, 0, 0, BRICKCOLOR, "Effect", VT())
  657. EFFECTPART.Anchored = true
  658. EFFECTPART.CFrame = CFRAME
  659. local EFFECTMESH = CreateMesh("SpecialMesh", EFFECTPART, "FileMesh", "3270017", "", VT(X1 * Player_Size, Y1 * Player_Size, Z1 * Player_Size), OFFSET * Player_Size)
  660. game:GetService("Debris"):AddItem(EFFECTPART, 10)
  661. coroutine.resume(coroutine.create(function(PART, MESH)
  662. for i = 0, 1, delay do
  663. Swait()
  664. PART.CFrame = PART.CFrame * ROTATION
  665. PART.Transparency = i
  666. MESH.Scale = MESH.Scale + VT(X2 * Player_Size, Y2 * Player_Size, Z2 * Player_Size)
  667. end
  668. PART.Parent = nil
  669. end), EFFECTPART, EFFECTMESH)
  670. end
  671.  
  672. function MagicWave(BRICKCOLOR, MATERIAL, CFRAME, ROTATION, OFFSET, X1, Y1, Z1, X2, Y2, Z2, delay)
  673. local EFFECTPART = CreatePart(3, Effects, MATERIAL, 0, 0, BRICKCOLOR, "Effect", VT())
  674. EFFECTPART.Anchored = true
  675. EFFECTPART.CFrame = CFRAME
  676. local EFFECTMESH = CreateMesh("SpecialMesh", EFFECTPART, "FileMesh", "20329976", "", VT(X1 * Player_Size, Y1 * Player_Size, Z1 * Player_Size), VT(0, 0, (-0.1 * Z1)) + (OFFSET * Player_Size))
  677. game:GetService("Debris"):AddItem(EFFECTPART, 10)
  678. coroutine.resume(coroutine.create(function(PART, MESH)
  679. for i = 0, 1, delay do
  680. Swait()
  681. PART.CFrame = PART.CFrame * ROTATION
  682. PART.Transparency = i
  683. MESH.Offset = VT(0, 0, (-0.1 * MESH.Scale.Z))
  684. MESH.Scale = MESH.Scale + VT(X2 * Player_Size, Y2 * Player_Size, Z2 * Player_Size)
  685. end
  686. PART.Parent = nil
  687. end), EFFECTPART, EFFECTMESH)
  688. end
  689.  
  690. function MagicCrystal(BRICKCOLOR, MATERIAL, CFRAME, ROTATION, OFFSET, X1, Y1, Z1, X2, Y2, Z2, delay)
  691. local EFFECTPART = CreatePart(3, Effects, MATERIAL, 0, 0, BRICKCOLOR, "Effect", VT())
  692. EFFECTPART.Anchored = true
  693. EFFECTPART.CFrame = CFRAME
  694. local EFFECTMESH = CreateMesh("SpecialMesh", EFFECTPART, "FileMesh", "9756362", "", VT(X1 * Player_Size, Y1 * Player_Size, Z1 * Player_Size), OFFSET * Player_Size)
  695. game:GetService("Debris"):AddItem(EFFECTPART, 10)
  696. coroutine.resume(coroutine.create(function(PART, MESH)
  697. for i = 0, 1, delay do
  698. Swait()
  699. PART.CFrame = PART.CFrame * ROTATION
  700. PART.Transparency = i
  701. MESH.Scale = MESH.Scale + VT(X2 * Player_Size, Y2 * Player_Size, Z2 * Player_Size)
  702. end
  703. PART.Parent = nil
  704. end), EFFECTPART, EFFECTMESH)
  705. end
  706.  
  707. function MagicSwirl(BRICKCOLOR, MATERIAL, CFRAME, ROTATION, OFFSET, X1, Y1, Z1, X2, Y2, Z2, delay)
  708. local EFFECTPART = CreatePart(3, Effects, MATERIAL, 0, 0, BRICKCOLOR, "Effect", VT())
  709. EFFECTPART.Anchored = true
  710. EFFECTPART.CFrame = CFRAME
  711. local EFFECTMESH = CreateMesh("SpecialMesh", EFFECTPART, "FileMesh", "1051557", "", VT(X1 * Player_Size, Y1 * Player_Size, Z1 * Player_Size), OFFSET * Player_Size)
  712. game:GetService("Debris"):AddItem(EFFECTPART, 10)
  713. coroutine.resume(coroutine.create(function(PART, MESH)
  714. for i = 0, 1, delay do
  715. Swait()
  716. PART.CFrame = PART.CFrame * ROTATION
  717. PART.Transparency = i
  718. MESH.Scale = MESH.Scale + VT(X2 * Player_Size, Y2 * Player_Size, Z2 * Player_Size)
  719. end
  720. PART.Parent = nil
  721. end), EFFECTPART, EFFECTMESH)
  722. end
  723.  
  724. function MagicSharpCone(BRICKCOLOR, MATERIAL, CFRAME, ROTATION, OFFSET, X1, Y1, Z1, X2, Y2, Z2, delay)
  725. local EFFECTPART = CreatePart(3, Effects, MATERIAL, 0, 0, BRICKCOLOR, "Effect", VT())
  726. EFFECTPART.Anchored = true
  727. EFFECTPART.CFrame = CFRAME
  728. local EFFECTMESH = CreateMesh("SpecialMesh", EFFECTPART, "FileMesh", "1778999", "", VT(X1 * Player_Size, Y1 * Player_Size, Z1 * Player_Size), OFFSET * Player_Size)
  729. game:GetService("Debris"):AddItem(EFFECTPART, 10)
  730. coroutine.resume(coroutine.create(function(PART, MESH)
  731. for i = 0, 1, delay do
  732. Swait()
  733. PART.CFrame = PART.CFrame * ROTATION
  734. PART.Transparency = i
  735. MESH.Scale = MESH.Scale + VT(X2 * Player_Size, Y2 * Player_Size, Z2 * Player_Size)
  736. end
  737. PART.Parent = nil
  738. end), EFFECTPART, EFFECTMESH)
  739. end
  740.  
  741. function MagicFlatCone(BRICKCOLOR, MATERIAL, CFRAME, ROTATION, OFFSET, X1, Y1, Z1, X2, Y2, Z2, delay)
  742. local EFFECTPART = CreatePart(3, Effects, MATERIAL, 0, 0, BRICKCOLOR, "Effect", VT())
  743. EFFECTPART.Anchored = true
  744. EFFECTPART.CFrame = CFRAME
  745. local EFFECTMESH = CreateMesh("SpecialMesh", EFFECTPART, "FileMesh", "1033714", "", VT(X1 * Player_Size, Y1 * Player_Size, Z1 * Player_Size), OFFSET * Player_Size)
  746. game:GetService("Debris"):AddItem(EFFECTPART, 10)
  747. coroutine.resume(coroutine.create(function(PART, MESH)
  748. for i = 0, 1, delay do
  749. Swait()
  750. PART.CFrame = PART.CFrame * ROTATION
  751. PART.Transparency = i
  752. MESH.Scale = MESH.Scale + VT(X2 * Player_Size, Y2 * Player_Size, Z2 * Player_Size)
  753. end
  754. PART.Parent = nil
  755. end), EFFECTPART, EFFECTMESH)
  756. end
  757.  
  758. function MagicSpikedCrown(BRICKCOLOR, MATERIAL, CFRAME, ROTATION, OFFSET, X1, Y1, Z1, X2, Y2, Z2, delay)
  759. local EFFECTPART = CreatePart(3, Effects, MATERIAL, 0, 0, BRICKCOLOR, "Effect", VT())
  760. EFFECTPART.Anchored = true
  761. EFFECTPART.CFrame = CFRAME
  762. local EFFECTMESH = CreateMesh("SpecialMesh", EFFECTPART, "FileMesh", "1323306", "", VT(X1 * Player_Size, Y1 * Player_Size, Z1 * Player_Size), OFFSET * Player_Size)
  763. game:GetService("Debris"):AddItem(EFFECTPART, 10)
  764. coroutine.resume(coroutine.create(function(PART, MESH)
  765. for i = 0, 1, delay do
  766. Swait()
  767. PART.CFrame = PART.CFrame * ROTATION
  768. PART.Transparency = i
  769. MESH.Scale = MESH.Scale + VT(X2 * Player_Size, Y2 * Player_Size, Z2 * Player_Size)
  770. end
  771. PART.Parent = nil
  772. end), EFFECTPART, EFFECTMESH)
  773. end
  774.  
  775. function MagicFlatCrown(BRICKCOLOR, MATERIAL, CFRAME, ROTATION, OFFSET, X1, Y1, Z1, X2, Y2, Z2, delay)
  776. local EFFECTPART = CreatePart(3, Effects, MATERIAL, 0, 0, BRICKCOLOR, "Effect", VT())
  777. EFFECTPART.Anchored = true
  778. EFFECTPART.CFrame = CFRAME
  779. local EFFECTMESH = CreateMesh("SpecialMesh", EFFECTPART, "FileMesh", "1078075", "", VT(X1 * Player_Size, Y1 * Player_Size, Z1 * Player_Size), OFFSET * Player_Size)
  780. game:GetService("Debris"):AddItem(EFFECTPART, 10)
  781. coroutine.resume(coroutine.create(function(PART, MESH)
  782. for i = 0, 1, delay do
  783. Swait()
  784. PART.CFrame = PART.CFrame * ROTATION
  785. PART.Transparency = i
  786. MESH.Scale = MESH.Scale + VT(X2 * Player_Size, Y2 * Player_Size, Z2 * Player_Size)
  787. end
  788. PART.Parent = nil
  789. end), EFFECTPART, EFFECTMESH)
  790. end
  791.  
  792. function MagicSkull(BRICKCOLOR, MATERIAL, CFRAME, ROTATION, OFFSET, X1, Y1, Z1, X2, Y2, Z2, delay)
  793. local EFFECTPART = CreatePart(3, Effects, MATERIAL, 0, 0, BRICKCOLOR, "Effect", VT())
  794. EFFECTPART.Anchored = true
  795. EFFECTPART.CFrame = CFRAME
  796. local EFFECTMESH = CreateMesh("SpecialMesh", EFFECTPART, "FileMesh", "4770583", "", VT(X1 * Player_Size, Y1 * Player_Size, Z1 * Player_Size), OFFSET * Player_Size)
  797. game:GetService("Debris"):AddItem(EFFECTPART, 10)
  798. coroutine.resume(coroutine.create(function(PART, MESH)
  799. for i = 0, 1, delay do
  800. Swait()
  801. PART.CFrame = PART.CFrame * ROTATION
  802. PART.Transparency = i
  803. MESH.Scale = MESH.Scale + VT(X2 * Player_Size, Y2 * Player_Size, Z2 * Player_Size)
  804. end
  805. PART.Parent = nil
  806. end), EFFECTPART, EFFECTMESH)
  807. end
  808.  
  809. function ElectricEffect(BRICKCOLOR, MATERIAL, CFRAME, ROTATION, OFFSET, X, Y, Z, delay)
  810. local EFFECTPART = CreatePart(3, Effects, MATERIAL, 0, 0, BRICKCOLOR, "Effect", VT())
  811. EFFECTPART.Anchored = true
  812. EFFECTPART.CFrame = CFRAME
  813. local EFFECTMESH = CreateMesh("SpecialMesh", EFFECTPART, "FileMesh", "4770583", "", VT(X * Player_Size, Y * Player_Size, Z * Player_Size), OFFSET * Player_Size)
  814. game:GetService("Debris"):AddItem(EFFECTPART, 10)
  815. local XVALUE = MRANDOM()
  816. local YVALUE = MRANDOM()
  817. local ZVALUE = MRANDOM()
  818. coroutine.resume(coroutine.create(function(PART, MESH, THEXVALUE, THEYVALUE, THEZVALUE)
  819. for i = 0, 1, delay do
  820. Swait()
  821. PART.CFrame = PART.CFrame * ROTATION
  822. PART.Transparency = i
  823. THEXVALUE = THEXVALUE - 0.1 * (delay * 10)
  824. THEYVALUE = THEYVALUE - 0.1 * (delay * 10)
  825. THEZVALUE = THEZVALUE - 0.1 * (delay * 10)
  826. MESH.Scale = MESH.Scale + VT(THEXVALUE * Player_Size, THEYVALUE * Player_Size, THEZVALUE * Player_Size)
  827. end
  828. PART.Parent = nil
  829. end), EFFECTPART, EFFECTMESH, XVALUE, YVALUE, ZVALUE)
  830. end
  831.  
  832. function TrailEffect(BRICKCOLOR, MATERIAL, CURRENTCFRAME, OLDCFRAME, MESHTYPE, REFLECTANCE, SIZE, ROTATION, X, Y, Z, delay)
  833. local MAGNITUDECFRAME = (CURRENTCFRAME.p - OLDCFRAME.p).magnitude
  834. if MAGNITUDECFRAME > (1 / 100) then
  835. local EFFECTPART = CreatePart(3, Effects, MATERIAL, 0, 0, BRICKCOLOR, "Effect", VT(1, MAGNITUDECFRAME, 1))
  836. EFFECTPART.Anchored = true
  837. EFFECTPART.CFrame = CF((CURRENTCFRAME.p + OLDCFRAME.p) / 2, OLDCFRAME.p) * ANGLES(RAD(90), 0, 0)
  838. local THEMESHTYPE = "BlockMesh"
  839. if MESHTYPE == "Cylinder" then
  840. THEMESHTYPE = "CylinderMesh"
  841. end
  842. local EFFECTMESH = CreateMesh(THEMESHTYPE, EFFECTPART, "", "", "", VT(0 + SIZE * Player_Size, 1, 0 + SIZE * Player_Size), VT(0, 0, 0))
  843. game:GetService("Debris"):AddItem(EFFECTPART, 10)
  844. coroutine.resume(coroutine.create(function(PART, MESH)
  845. for i = 0, 1, delay do
  846. Swait()
  847. PART.CFrame = PART.CFrame * ROTATION
  848. PART.Transparency = i
  849. MESH.Scale = MESH.Scale + VT(X * Player_Size, Y * Player_Size, Z * Player_Size)
  850. end
  851. PART.Parent = nil
  852. end), EFFECTPART, EFFECTMESH)
  853. end
  854. end
  855.  
  856. function ClangEffect(BRICKCOLOR, MATERIAL, CFRAME, ANGLE, DURATION, SIZE, POWER, REFLECTANCE, X, Y, Z, delay)
  857. local EFFECTPART = CreatePart(3, Effects, MATERIAL, 0, 1, BRICKCOLOR, "Effect", VT())
  858. EFFECTPART.Anchored = true
  859. EFFECTPART.CFrame = CFRAME
  860. local EFFECTMESH = CreateMesh("BlockMesh", EFFECTPART, "", "", "", VT(0, 0, 0), VT(0, 0, 0))
  861. game:GetService("Debris"):AddItem(EFFECTPART, 10)
  862. local THELASTPOINT = CFRAME
  863. coroutine.resume(coroutine.create(function(PART)
  864. for i = 1, DURATION do
  865. Swait()
  866. PART.CFrame = PART.CFrame * ANGLES(RAD(ANGLE), 0, 0) * CF(0, POWER * Player_Size, 0)
  867. TrailEffect(BRICKCOLOR, MATERIAL, PART.CFrame, THELASTPOINT, "Cylinder", REFLECTANCE, SIZE * Player_Size, ANGLES(0, 0, 0), X * Player_Size, Y * Player_Size, Z * Player_Size, delay)
  868. THELASTPOINT = PART.CFrame
  869. end
  870. PART.Parent = nil
  871. end), EFFECTPART)
  872. end
  873.  
  874. --local list={}
  875. function Triangle(Color, Material, a, b, c, delay)
  876. local edge1 = (c - a):Dot((b - a).unit)
  877. local edge2 = (a - b):Dot((c - b).unit)
  878. local edge3 = (b - c):Dot((a - c).unit)
  879. if edge1 <= (b - a).magnitude and edge1 >= 0 then
  880. a, b, c=a, b, c
  881. elseif edge2 <= (c - b).magnitude and edge2 >= 0 then
  882. a, b, c=b, c, a
  883. elseif edge3 <= (a - c).magnitude and edge3 >= 0 then
  884. a, b, c=c, a, b
  885. else
  886. assert(false, "unreachable")
  887. end
  888. local len1 = (c - a):Dot((b - a).unit)
  889. local len2 = (b - a).magnitude - len1
  890. local width = (a + (b - a).unit * len1 - c).magnitude
  891. local maincf = CFrameFromTopBack(a, (b - a):Cross(c - b).unit, - (b - a).unit)
  892. if len1 > 1 / 100 then
  893. local sz = VT(0.2, width, len1)
  894. local w1 = CreatePart(3, Effects, Material, 0, 0.5, Color, "Trail", sz)
  895. local sp = CreateMesh("SpecialMesh", w1, "Wedge", "", "", VT(0, 1, 1) * sz / w1.Size, VT(0, 0, 0))
  896. w1.Anchored = true
  897. w1.CFrame = maincf * ANGLES(math.pi, 0, math.pi / 2) * CF(0, width / 2, len1 / 2)
  898. coroutine.resume(coroutine.create(function()
  899. for i = 0.5, 1, delay * (2 / Animation_Speed) do
  900. Swait()
  901. w1.Transparency = i
  902. end
  903. w1.Parent = nil
  904. end))
  905. game:GetService("Debris"):AddItem(w1, 10)
  906. --table.insert(list, w1)
  907. end
  908. if len2 > 1 / 100 then
  909. local sz = VT(0.2, width, len2)
  910. local w2 = CreatePart(3, Effects, Material, 0, 0.5, Color, "Trail", sz)
  911. local sp = CreateMesh("SpecialMesh", w2, "Wedge", "", "", VT(0, 1, 1) * sz / w2.Size, VT(0, 0, 0))
  912. w2.Anchored = true
  913. w2.CFrame = maincf * ANGLES(math.pi, math.pi, -math.pi / 2) * CF(0, width / 2, -len1 - len2 / 2)
  914. coroutine.resume(coroutine.create(function()
  915. for i = 0.5, 1, delay * (2 / Animation_Speed) do
  916. Swait()
  917. w2.Transparency = i
  918. end
  919. w2.Parent = nil
  920. end))
  921. game:GetService("Debris"):AddItem(w2, 10)
  922. --table.insert(list, w2)
  923. end
  924. --return unpack(list)
  925. end
  926.  
  927. --[[Usage:
  928. local Pos = Part
  929. local Offset = Part.CFrame * CF(0, 0, 0)
  930. local Color = "Institutional white"
  931. local Material = "Neon"
  932. local TheDelay = 0.01
  933. local Height = 4
  934. BLCF = Offset
  935. if SCFR and (Pos.Position - SCFR.p).magnitude > 0.1 then
  936. local a, b = Triangle(Color, Material, (SCFR * CF(0, Height / 2,0)).p, (SCFR * CF(0, -Height / 2, 0)).p, (BLCF * CF(0, Height / 2,0)).p, TheDelay)
  937. if a then game:GetService("Debris"):AddItem(a, 1) end
  938. if b then game:GetService("Debris"):AddItem(b, 1) end
  939. local a, b = Triangle(Color, Material, (BLCF * CF(0, Height / 2, 0)).p, (BLCF * CF(0, -Height / 2, 0)).p, (SCFR * CF(0, -Height / 2, 0)).p, TheDelay)
  940. if a then game:GetService("Debris"):AddItem(a, 1) end
  941. if b then game:GetService("Debris"):AddItem(b, 1) end
  942. SCFR = BLCF
  943. elseif not SCFR then
  944. SCFR = BLCF
  945. end
  946. --
  947. BLCF = nil
  948. SCFR = nil
  949. --]]
  950.  
  951. --//=================================\\
  952. --\\=================================//
  953.  
  954. ------------------------------------------
  955. local SONG = 1338552084
  956. local SONG2 = 2157789451
  957. local Music = Instance.new("Sound",Torso)
  958. Music.Volume = 2.5
  959. Music.Looped = true
  960. Music.Pitch = 1.0 --Pitcher
  961. ------------------------------------------
  962.  
  963.  
  964. --//=================================\\
  965. --|| WEAPON CREATION
  966. --\\=================================//
  967.  
  968. local StartPart = CreatePart(3, Weapon, "DiamondPlate", 0, 0, "Stone grey", "Metal", VT(0.8,0.5,0.8),false)
  969. CreateWeldOrSnapOrMotor("Weld", Torso, Torso, StartPart, CF(-0.7, 0.7, 0.5) * ANGLES(RAD(50), RAD(0), RAD(15)), CF(0, 0, 0))
  970. local Part = CreatePart(3, Weapon, "DiamondPlate", 0, 0.5, "Stone grey", "Glass", VT(0.7,1.4,0.7),false)
  971. CreateWeldOrSnapOrMotor("Weld", StartPart, StartPart, Part, CF(0, 0.7, 0) * ANGLES(RAD(0), RAD(0), RAD(0)), CF(0, 0, 0))
  972. local Part = CreatePart(3, Weapon, "DiamondPlate", 0, 0, "Stone grey", "Acid", VT(0.65,1.4,0.65),false)
  973. CreateWeldOrSnapOrMotor("Weld", StartPart, StartPart, Part, CF(0, 0.7, 0) * ANGLES(RAD(0), RAD(0), RAD(0)), CF(0, 0, 0))
  974. local Part = CreatePart(3, Weapon, "DiamondPlate", 0, 0, "Stone grey", "Metal", VT(0.8,0.5,0.8),false)
  975. CreateWeldOrSnapOrMotor("Weld", StartPart, StartPart, Part, CF(0, 1.4, 0) * ANGLES(RAD(0), RAD(180), RAD(0)), CF(0, 0, 0))
  976.  
  977. local StartPart = CreatePart(3, Weapon, "DiamondPlate", 0, 0, "Stone grey", "Metal", VT(0.6,0.5,0.6),false)
  978. CreateWeldOrSnapOrMotor("Weld", Torso, Torso, StartPart, CF(-0.6, 0, 0.5) * ANGLES(RAD(80), RAD(0), RAD(15)), CF(0, 0, 0))
  979. local Part = CreatePart(3, Weapon, "DiamondPlate", 0, 0.5, "Stone grey", "Glass", VT(0.5,1.4,0.5),false)
  980. CreateWeldOrSnapOrMotor("Weld", StartPart, StartPart, Part, CF(0, 0.7, 0) * ANGLES(RAD(0), RAD(0), RAD(0)), CF(0, 0, 0))
  981. local Part = CreatePart(3, Weapon, "DiamondPlate", 0, 0, "Stone grey", "Acid", VT(0.45,1.4,0.45),false)
  982. CreateWeldOrSnapOrMotor("Weld", StartPart, StartPart, Part, CF(0, 0.7, 0) * ANGLES(RAD(0), RAD(0), RAD(0)), CF(0, 0, 0))
  983. local Part = CreatePart(3, Weapon, "DiamondPlate", 0, 0, "Stone grey", "Metal", VT(0.6,0.5,0.6),false)
  984. CreateWeldOrSnapOrMotor("Weld", StartPart, StartPart, Part, CF(0, 1.4, 0) * ANGLES(RAD(0), RAD(180), RAD(0)), CF(0, 0, 0))
  985.  
  986. local StartPart = CreatePart(3, Weapon, "DiamondPlate", 0, 0, "Stone grey", "Metal", VT(0.5,0.5,0.5),false)
  987. CreateWeldOrSnapOrMotor("Weld", Torso, Torso, StartPart, CF(-0.5, -0.5, 0.45) * ANGLES(RAD(110), RAD(0), RAD(15)), CF(0, 0, 0))
  988. local Part = CreatePart(3, Weapon, "DiamondPlate", 0, 0.5, "Stone grey", "Glass", VT(0.4,1.4,0.4),false)
  989. CreateWeldOrSnapOrMotor("Weld", StartPart, StartPart, Part, CF(0, 0.7, 0) * ANGLES(RAD(0), RAD(0), RAD(0)), CF(0, 0, 0))
  990. local Part = CreatePart(3, Weapon, "DiamondPlate", 0, 0, "Stone grey", "Acid", VT(0.35,1.4,0.35),false)
  991. CreateWeldOrSnapOrMotor("Weld", StartPart, StartPart, Part, CF(0, 0.7, 0) * ANGLES(RAD(0), RAD(0), RAD(0)), CF(0, 0, 0))
  992. local Part = CreatePart(3, Weapon, "DiamondPlate", 0, 0, "Stone grey", "Metal", VT(0.5,0.5,0.5),false)
  993. CreateWeldOrSnapOrMotor("Weld", StartPart, StartPart, Part, CF(0, 1.4, 0) * ANGLES(RAD(0), RAD(180), RAD(0)), CF(0, 0, 0))
  994.  
  995. local Part = CreatePart(3, Weapon, "DiamondPlate", 0, 0, "Stone grey", "Metal", VT(1.1,0.7,1.1),false)
  996. CreateWeldOrSnapOrMotor("Weld", LeftArm, LeftArm, Part, CF(0, 0.7, 0) * ANGLES(RAD(0), RAD(0), RAD(0)), CF(0, 0, 0))
  997. local Part = CreatePart(3, Weapon, "DiamondPlate", 0, 0, "Stone grey", "Metal", VT(0.55,0.7,1.1),false)
  998. CreateWeldOrSnapOrMotor("Weld", LeftArm, LeftArm, Part, CF(0.25, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(0)), CF(0, 0, 0))
  999. local Part = CreatePart(3, Weapon, "DiamondPlate", 0, 0, "Stone grey", "Metal", VT(1.1,0.7,0.525),false)
  1000. CreateWeldOrSnapOrMotor("Weld", LeftArm, LeftArm, Part, CF(-0.28, 0, 0) * ANGLES(RAD(180), RAD(90), RAD(0)), CF(0, 0, 0))
  1001. local Part = CreatePart(3, Weapon, "DiamondPlate", 0, 0, "Stone grey", "Metal", VT(1.1,1,0.525),false)
  1002. CreateWeldOrSnapOrMotor("Weld", Torso, Torso, Part, CF(-0.75, 0.51, 0) * ANGLES(RAD(180), RAD(-90), RAD(0)), CF(0, 0, 0))
  1003. local Part = CreatePart(3, Weapon, "DiamondPlate", 0, 0, "Stone grey", "Metal", VT(1,1,1.2),false)
  1004. CreateWeldOrSnapOrMotor("Weld", Torso, Torso, Part, CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(0)), CF(0, 0, 0))
  1005. local Part = CreatePart(3, Weapon, "DiamondPlate", 0, 0, "Stone grey", "Metal", VT(0.3,1.7,1.15),false)
  1006. CreateWeldOrSnapOrMotor("Weld", Torso, Torso, Part, CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(45)), CF(0, 0, 0))
  1007. local Part = CreatePart(3, Weapon, "DiamondPlate", 0, 0, "Stone grey", "Metal", VT(0.3,1.7,1.15),false)
  1008. CreateWeldOrSnapOrMotor("Weld", Torso, Torso, Part, CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(-45)), CF(0, 0, 0))
  1009. local Part = CreatePart(3, Weapon, "DiamondPlate", 0, 0, "Dark stone grey", "Metal", VT(0.8,0.8,1.225),false)
  1010. CreateWeldOrSnapOrMotor("Weld", Torso, Torso, Part, CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(0)), CF(0, 0, 0))
  1011. local Part = CreatePart(3, Weapon, "Neon", 0, 0, "Dark indigo", "Eon", VT(0.5,0.5,1.25),false)
  1012. CreateWeldOrSnapOrMotor("Weld", Torso, Torso, Part, CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(0)), CF(0, 0, 0))
  1013.  
  1014. local Part = CreatePart(3, Weapon, "Neon", 0, 0, "Dark indigo", "Eon", VT(0.1,0.2,0.1),false)
  1015. CreateWeldOrSnapOrMotor("Weld", Head, Head, Part, CF(-0.2, 0.2, -0.55) * ANGLES(RAD(0), RAD(0), RAD(0)), CF(0, 0, 0))
  1016. local Part = CreatePart(3, Weapon, "Neon", 0, 0, "Dark indigo", "Eon", VT(0.1,0.2,0.1),false)
  1017. CreateWeldOrSnapOrMotor("Weld", Head, Head, Part, CF(0.2, 0.2, -0.55) * ANGLES(RAD(0), RAD(0), RAD(0)), CF(0, 0, 0))
  1018. local beampart = CreatePart(3, Weapon, "Neon", 0, 0, "Dark indigo", "Handle", VT(0.6*Player_Size,0.1*Player_Size,0.6*Player_Size))
  1019.  
  1020. local beampart = CreatePart(3, Weapon, "Neon", 0, 0, "Dark indigo", "Handle", VT(0.6*Player_Size,0.1*Player_Size,0.6*Player_Size))
  1021. local weld = CreateWeldOrSnapOrMotor("Weld", beampart, RightArm, beampart, CF(0 * Player_Size, -1.02 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(0)), CF(0, 0, 0))
  1022. local mesh = IT("CylinderMesh",beampart)
  1023.  
  1024. for _, c in pairs(Weapon:GetChildren()) do
  1025. if c.ClassName == "Part" then
  1026. c.CustomPhysicalProperties = PhysicalProperties.new(0, 0, 0, 0, 0)
  1027. end
  1028. end
  1029.  
  1030. Character.Head.face.Texture = "rbxassetid://176217905"
  1031.  
  1032. Weapon.Parent = Character
  1033.  
  1034. Humanoid.Died:connect(function()
  1035. ATTACK = true
  1036. end)
  1037.  
  1038. print(Class_Name.." loaded.")
  1039.  
  1040. --//=================================\\
  1041. --\\=================================//
  1042.  
  1043.  
  1044.  
  1045.  
  1046.  
  1047. --//=================================\\
  1048. --|| DAMAGE FUNCTIONS
  1049. --\\=================================//
  1050.  
  1051. function StatLabel(LABELTYPE, CFRAME, TEXT, COLOR)
  1052. local STATPART = CreatePart(3, Effects, "SmoothPlastic", 0, 1, "Really black", "Effect", VT())
  1053. STATPART.CFrame = CF(CFRAME.p + VT(0, 1.5, 0))
  1054. local BODYGYRO = IT("BodyGyro", STATPART)
  1055. local BODYPOSITION = IT("BodyPosition", STATPART)
  1056. BODYPOSITION.P = 2000
  1057. BODYPOSITION.D = 100
  1058. BODYPOSITION.maxForce = VT(math.huge, math.huge, math.huge)
  1059. if LABELTYPE == "Normal" then
  1060. BODYPOSITION.position = STATPART.Position + VT(MRANDOM(-2, 2), 6, MRANDOM(-2, 2))
  1061. elseif LABELTYPE == "Debuff" then
  1062. BODYPOSITION.position = STATPART.Position + VT(MRANDOM(-2, 2), 8, MRANDOM(-2, 2))
  1063. elseif LABELTYPE == "Interruption" then
  1064. BODYPOSITION.position = STATPART.Position + VT(MRANDOM(-2,2), 8, MRANDOM(-2, 2))
  1065. end
  1066. game:GetService("Debris"):AddItem(STATPART ,5)
  1067. local BILLBOARDGUI = Instance.new("BillboardGui", STATPART)
  1068. BILLBOARDGUI.Adornee = STATPART
  1069. BILLBOARDGUI.Size = UD2(2.5, 0, 2.5 ,0)
  1070. BILLBOARDGUI.StudsOffset = VT(-2, 2, 0)
  1071. BILLBOARDGUI.AlwaysOnTop = false
  1072. local TEXTLABEL = Instance.new("TextLabel", BILLBOARDGUI)
  1073. TEXTLABEL.BackgroundTransparency = 1
  1074. TEXTLABEL.Size = UD2(2.5, 0, 2.5, 0)
  1075. TEXTLABEL.Text = TEXT
  1076. TEXTLABEL.Font = "SciFi"
  1077. TEXTLABEL.FontSize="Size42"
  1078. TEXTLABEL.TextColor3 = COLOR
  1079. TEXTLABEL.TextStrokeTransparency = 1
  1080. TEXTLABEL.TextScaled = true
  1081. TEXTLABEL.TextWrapped = true
  1082. coroutine.resume(coroutine.create(function(THEPART, THEBODYPOSITION, THETEXTLABEL)
  1083. wait(0.2)
  1084. for i=1, 5 do
  1085. wait()
  1086. THEBODYPOSITION.Position = THEPART.Position - VT(0, 0.5 ,0)
  1087. end
  1088. wait(1.2)
  1089. for i=1, 5 do
  1090. wait()
  1091. THETEXTLABEL.TextTransparency = THETEXTLABEL.TextTransparency + 0.2
  1092. THETEXTLABEL.TextStrokeTransparency = THETEXTLABEL.TextStrokeTransparency + 0.2
  1093. THEBODYPOSITION.position = THEPART.Position + VT(0, 0.5, 0)
  1094. end
  1095. THEPART.Parent = nil
  1096. end),STATPART, BODYPOSITION, TEXTLABEL)
  1097. end
  1098.  
  1099. function dealdamage(hit,min,max,maxstrength,beserk,critrate,critmultiplier)
  1100. if hit.Parent ~= Character and hit.Parent:FindFirstChildOfClass("Humanoid") and hit.Parent:FindFirstChild("HitBy"..Player.Name) == nil then
  1101. local humanoid = hit.Parent:FindFirstChildOfClass("Humanoid")
  1102. local dmg = math.random(min,max)
  1103. if humanoid.Health > 0 then
  1104. if beserk == true then
  1105. humanoid.Health = 0
  1106. humanoid.Parent:BreakJoints()
  1107. StatLabel("Normal", hit.CFrame * CF(0, 0 + (hit.Size.z - 1), 0), "BESERK/inf", C3(255/255, 0, 0))
  1108. else
  1109. CreateSound("260430060", hit, 1.2, MRANDOM(7, 12) / 10)
  1110. hit.Velocity = CFrame.new(Torso.Position,hit.Position).lookVector*5*maxstrength
  1111. if math.random(1,100) < critrate+1 then
  1112. humanoid.Health = humanoid.Health - dmg*critmultiplier
  1113. StatLabel("Normal", hit.CFrame * CF(0, 0 + (hit.Size.z - 1), 0), "CRIT/"..dmg*critmultiplier, C3(255/255, 0, 0))
  1114. else
  1115. humanoid.Health = humanoid.Health - dmg
  1116. StatLabel("Normal", hit.CFrame * CF(0, 0 + (hit.Size.z - 1), 0), dmg, C3(0, 0, 0))
  1117. end
  1118. local defence = Instance.new("BoolValue",hit.Parent)
  1119. defence.Name = ("HitBy"..Player.Name)
  1120. game:GetService("Debris"):AddItem(defence, 0.5)
  1121. end
  1122. end
  1123. end
  1124. end
  1125.  
  1126. function AoEDamage(position,radius,min,max,maxstrength,beserk,critrate,critmultiplier,CanBeDodgedByJumping)
  1127. local dmg = (math.random(min,max)/5)
  1128. for i,v in ipairs(workspace:GetChildren()) do
  1129. local body = v:GetChildren()
  1130. for part = 1, #body do
  1131. if((body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character) then
  1132. if(body[part].Position - position).Magnitude < radius then
  1133. if v.ClassName == "Model" then
  1134. if v:FindFirstChild("Humanoid") and v:FindFirstChild("HitBy"..Player.Name) == nil then
  1135. if CanBeDodgedByJumping == true then
  1136. if v.Humanoid.Jump == false then
  1137. if math.random(1,100) < critrate+1 then
  1138. v.Humanoid.Health = v.Humanoid.Health - dmg*critmultiplier
  1139. --StatLabel("Normal", body[part].CFrame * CF(0, 0 + (body[part].Size.z - 1), 0), "CRIT/"..dmg*critmultiplier, C3(255/255, 0, 0))
  1140. else
  1141. v.Humanoid.Health = v.Humanoid.Health - dmg
  1142. --StatLabel("Normal", body[part].CFrame * CF(0, 0 + (body[part].Size.z - 1), 0), dmg, C3(0, 0, 0))
  1143. end
  1144. local defence = Instance.new("BoolValue",v.Parent)
  1145. defence.Name = ("HitBy"..Player.Name)
  1146. game:GetService("Debris"):AddItem(defence, 0.5)
  1147. end
  1148. else
  1149. if beserk == true then
  1150. v.Humanoid.Health = 0
  1151. end
  1152. if math.random(1,100) < critrate+1 then
  1153. v.Humanoid.Health = v.Humanoid.Health - dmg*critmultiplier
  1154. --StatLabel("Normal", body[part].CFrame * CF(0, 0 + (body[part].Size.z - 1), 0), "CRIT/"..dmg*critmultiplier, C3(255/255, 0, 0))
  1155. else
  1156. v.Humanoid.Health = v.Humanoid.Health - dmg
  1157. --StatLabel("Normal", body[part].CFrame * CF(0, 0 + (body[part].Size.z - 1), 0), dmg, C3(0, 0, 0))
  1158. end
  1159. local defence = Instance.new("BoolValue",v.Parent)
  1160. defence.Name = ("HitBy"..Player.Name)
  1161. game:GetService("Debris"):AddItem(defence, 0.5)
  1162. end
  1163. end
  1164. end
  1165. body[part].Velocity = CFrame.new(position,body[part].Position).lookVector*5*maxstrength
  1166. end
  1167. end
  1168. end
  1169. if v.ClassName == "Part" then
  1170. if v.Anchored == false and (v.Position - position).Magnitude < radius then
  1171. v.Velocity = CFrame.new(position,v.Position).lookVector*5*maxstrength
  1172. end
  1173. end
  1174. end
  1175. end
  1176.  
  1177. --//=================================\\
  1178. --|| ATTACK FUNCTIONS AND STUFF
  1179. --\\=================================//
  1180.  
  1181. function turnto(position)
  1182. RootPart.CFrame=CFrame.new(RootPart.CFrame.p,VT(position.X,RootPart.Position.Y,position.Z)) * CFrame.new(0, 0, 0)
  1183. end
  1184.  
  1185. function CastRay(StartPos, Vec, Length, Ignore)
  1186. local Ignore = ((type(Ignore) == "table" and Ignore) or {Ignore})
  1187. local RayHit, RayPos, RayNormal = game:GetService("Workspace"):FindPartOnRayWithIgnoreList(Ray.new(StartPos, Vec * Length), Ignore)
  1188. return RayHit, RayPos
  1189. end
  1190.  
  1191. function Shoot()
  1192. Rooted = true
  1193. ATTACK = true
  1194. for i=0, 1, 0.1 / Animation_Speed do
  1195. Swait()
  1196. turnto(Mouse.Hit.p)
  1197. RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0.05 * Player_Size, 0 * Player_Size, -0.1 * Player_Size) * ANGLES(RAD(10), RAD(0), RAD(40)), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed/5)
  1198. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(0), RAD(0), RAD(-40)) * ANGLES(RAD(-5), RAD(0), RAD(0)), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
  1199. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1 * Player_Size, 0.5 * Player_Size, -1 * Player_Size) * ANGLES(RAD(90), RAD(0), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 0.4 / Animation_Speed)
  1200. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(10 - 2.5 * COS(SINE / 16)), RAD(0), RAD(-25 + 2.5 * SIN(SINE / 24))) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
  1201. RightHip.C0 = Clerp(RightHip.C0, CF(0.95 * Player_Size, -1 * Player_Size, -0.5 * Player_Size) * ANGLES(RAD(0), RAD(50), RAD(0)) * ANGLES(RAD(-1.25), RAD(0), RAD(0)), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
  1202. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -0.9 * Player_Size, 0.25 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-2.5), RAD(0), RAD(0)), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
  1203. end
  1204. --local RayHit, RayPos = CastRay(beampart.Position,Mouse.Hit.p,100,Character)
  1205. MagicBlock("Dark indigo", "Neon", beampart.CFrame * ANGLES(RAD(MRANDOM(-50, 50)), RAD(MRANDOM(-50, 50)), RAD(MRANDOM(-50, 50))), ANGLES(RAD(MRANDOM(-5, 5)), RAD(MRANDOM(-5, 5)), RAD(MRANDOM(-5, 5))), VT(0, 0, 0), 0.25, 0.25, 0.25, 1.5, 1.5, 1.5, 0.05)
  1206. CreateSound("379225925", beampart, 3, 1.1)
  1207. local laser = IT("Part",Effects)
  1208. laser.CanCollide = false
  1209. laser.Anchored = true
  1210. local distance = (beampart.Position - Mouse.Hit.p).magnitude
  1211. laser.Size = Vector3.new(0.2, 0.2, distance)
  1212. laser.CFrame = CFrame.new(beampart.Position,Mouse.Hit.p) * CFrame.new(0, 0, -distance/2)
  1213. laser.Material = "Neon"
  1214. laser.BrickColor = BRICKC("Dark indigo")
  1215. table.insert(Effects2,{laser,"Disappear",0.05,2,2,2,2})
  1216. AoEDamage(Mouse.Hit.p,5,25,35,12,false,10,2)
  1217. MagicSphere("Dark indigo", "Neon", CF(Mouse.Hit.p) * ANGLES(RAD(MRANDOM(-50, 50)), RAD(MRANDOM(-50, 50)), RAD(MRANDOM(-50, 50))), ANGLES(RAD(MRANDOM(-5, 5)), RAD(MRANDOM(-5, 5)), RAD(MRANDOM(-5, 5))), VT(0, 0, 0), 0.25, 0.25, 0.25, 7.5, 7.5, 7.5, 0.05)
  1218. MagicBlock("Dark indigo", "Neon", CF(Mouse.Hit.p) * ANGLES(RAD(MRANDOM(-50, 50)), RAD(MRANDOM(-50, 50)), RAD(MRANDOM(-50, 50))), ANGLES(RAD(MRANDOM(-5, 5)), RAD(MRANDOM(-5, 5)), RAD(MRANDOM(-5, 5))), VT(0, 0, 0), 0.25, 0.25, 0.25, 7.5, 7.5, 7.5, 0.05)
  1219. for i=0, 0.25, 0.1 / Animation_Speed do
  1220. Swait()
  1221. turnto(Mouse.Hit.p)
  1222. RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0.05 * Player_Size, 0 * Player_Size, -0.1 * Player_Size) * ANGLES(RAD(10), RAD(0), RAD(50)), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
  1223. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(0), RAD(0), RAD(-50)) * ANGLES(RAD(-5), RAD(0), RAD(0)), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
  1224. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1 * Player_Size, 0.5 * Player_Size, -1 * Player_Size) * ANGLES(RAD(160), RAD(0), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 0.4 / Animation_Speed)
  1225. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(10 - 2.5 * COS(SINE / 16)), RAD(0), RAD(-25 + 2.5 * SIN(SINE / 24))) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
  1226. RightHip.C0 = Clerp(RightHip.C0, CF(0.95 * Player_Size, -1 * Player_Size, -0.5 * Player_Size) * ANGLES(RAD(0), RAD(60), RAD(0)) * ANGLES(RAD(-1.25), RAD(0), RAD(0)), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
  1227. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -0.9 * Player_Size, 0.25 * Player_Size) * ANGLES(RAD(0), RAD(-100), RAD(0)) * ANGLES(RAD(-2.5), RAD(0), RAD(0)), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
  1228. end
  1229. ATTACK = false
  1230. Rooted = false
  1231. end
  1232.  
  1233. function ChargeShot()
  1234. Rooted = true
  1235. ATTACK = true
  1236. for i=0, 1, 0.1 / Animation_Speed do
  1237. Swait()
  1238. turnto(Mouse.Hit.p)
  1239. RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0.05 * Player_Size, 0 * Player_Size, -0.1 * Player_Size) * ANGLES(RAD(10), RAD(0), RAD(40)), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed/5)
  1240. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(0), RAD(0), RAD(-40)) * ANGLES(RAD(-5), RAD(0), RAD(0)), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
  1241. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1 * Player_Size, 0.5 * Player_Size, -1 * Player_Size) * ANGLES(RAD(90), RAD(0), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 0.4 / Animation_Speed)
  1242. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(10 - 2.5 * COS(SINE / 16)), RAD(0), RAD(-25 + 2.5 * SIN(SINE / 24))) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
  1243. RightHip.C0 = Clerp(RightHip.C0, CF(0.95 * Player_Size, -1 * Player_Size, -0.5 * Player_Size) * ANGLES(RAD(0), RAD(50), RAD(0)) * ANGLES(RAD(-1.25), RAD(0), RAD(0)), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
  1244. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -0.9 * Player_Size, 0.25 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-2.5), RAD(0), RAD(0)), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
  1245. end
  1246. local SIZE = 1
  1247. repeat
  1248. turnto(Mouse.Hit.p)
  1249. MagicSphere("Dark indigo", "Neon", beampart.CFrame * ANGLES(RAD(MRANDOM(-50, 50)), RAD(MRANDOM(-50, 50)), RAD(MRANDOM(-50, 50))), ANGLES(RAD(MRANDOM(-5, 5)), RAD(MRANDOM(-5, 5)), RAD(MRANDOM(-5, 5))), VT(0, 0, 0), 0.25, 0.25, 0.25, SIZE, SIZE, SIZE, 0.05)
  1250. Swait()
  1251. SIZE = SIZE + 0.01
  1252. until KEYHOLD == false
  1253. --local RayHit, RayPos = CastRay(beampart.Position,Mouse.Hit.p,100,Character)
  1254. MagicBlock("Dark indigo", "Neon", beampart.CFrame * ANGLES(RAD(MRANDOM(-50, 50)), RAD(MRANDOM(-50, 50)), RAD(MRANDOM(-50, 50))), ANGLES(RAD(MRANDOM(-5, 5)), RAD(MRANDOM(-5, 5)), RAD(MRANDOM(-5, 5))), VT(0, 0, 0), 0.25, 0.25, 0.25, SIZE*1.5, SIZE*1.5, SIZE*1.5, 0.05)
  1255. CreateSound("379225925", beampart, 3, 1.1)
  1256. local laser = IT("Part",Effects)
  1257. laser.CanCollide = false
  1258. laser.Anchored = true
  1259. local distance = (beampart.Position - Mouse.Hit.p).magnitude
  1260. laser.Size = Vector3.new(SIZE * 0.2, SIZE * 0.2, distance)
  1261. laser.CFrame = CFrame.new(beampart.Position,Mouse.Hit.p) * CFrame.new(0, 0, -distance/2)
  1262. laser.Material = "Neon"
  1263. laser.BrickColor = BRICKC("Dark indigo")
  1264. table.insert(Effects2,{laser,"Disappear",0.05,2,2,2,2})
  1265. AoEDamage(Mouse.Hit.p,SIZE * 5,SIZE*10,SIZE*15,SIZE*5,false,10,2)
  1266. MagicSphere("Dark indigo", "Neon", CF(Mouse.Hit.p) * ANGLES(RAD(MRANDOM(-50, 50)), RAD(MRANDOM(-50, 50)), RAD(MRANDOM(-50, 50))), ANGLES(RAD(MRANDOM(-5, 5)), RAD(MRANDOM(-5, 5)), RAD(MRANDOM(-5, 5))), VT(0, 0, 0), 0.25, 0.25, 0.25, SIZE * 7.5, SIZE * 7.5, SIZE * 7.5, 0.05)
  1267. MagicBlock("Dark indigo", "Neon", CF(Mouse.Hit.p) * ANGLES(RAD(MRANDOM(-50, 50)), RAD(MRANDOM(-50, 50)), RAD(MRANDOM(-50, 50))), ANGLES(RAD(MRANDOM(-5, 5)), RAD(MRANDOM(-5, 5)), RAD(MRANDOM(-5, 5))), VT(0, 0, 0), 0.25, 0.25, 0.25, SIZE * 7.5, SIZE * 7.5, SIZE * 7.5, 0.05)
  1268. for i=0, 0.25, 0.1 / Animation_Speed do
  1269. Swait()
  1270. turnto(Mouse.Hit.p)
  1271. RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0.05 * Player_Size, 0 * Player_Size, -0.1 * Player_Size) * ANGLES(RAD(10), RAD(0), RAD(50)), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
  1272. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(0), RAD(0), RAD(-50)) * ANGLES(RAD(-5), RAD(0), RAD(0)), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
  1273. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1 * Player_Size, 0.5 * Player_Size, -1 * Player_Size) * ANGLES(RAD(160), RAD(0), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 0.4 / Animation_Speed)
  1274. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(10 - 2.5 * COS(SINE / 16)), RAD(0), RAD(-25 + 2.5 * SIN(SINE / 24))) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
  1275. RightHip.C0 = Clerp(RightHip.C0, CF(0.95 * Player_Size, -1 * Player_Size, -0.5 * Player_Size) * ANGLES(RAD(0), RAD(60), RAD(0)) * ANGLES(RAD(-1.25), RAD(0), RAD(0)), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
  1276. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -0.9 * Player_Size, 0.25 * Player_Size) * ANGLES(RAD(0), RAD(-100), RAD(0)) * ANGLES(RAD(-2.5), RAD(0), RAD(0)), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
  1277. end
  1278. Rooted = false
  1279. ATTACK = false
  1280. end
  1281.  
  1282. function RayCast(Position, Direction, MaxDistance, IgnoreList)
  1283. return game:GetService("Workspace"):FindPartOnRayWithIgnoreList(Ray.new(Position, Direction.unit * (MaxDistance or 999.999)), IgnoreList)
  1284. end
  1285.  
  1286. function GroundUp()
  1287. local RayHit, RayPos = RayCast(Mouse.Hit.p, Vector3.new(0, -1, 0), (1), {Character})
  1288. local SpawnPosition = RayPos
  1289. if RayPos then
  1290. Rooted = true
  1291. ATTACK = true
  1292. CreateSound("588697034", RightArm, 2, 0.8)
  1293. for i=0, 1, 0.1 / Animation_Speed/6 do
  1294. Swait()
  1295. RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0 * Player_Size, 0 * Player_Size, -1 * Player_Size) * ANGLES(RAD(45), RAD(0), RAD(0)), 0.2 / Animation_Speed/8)
  1296. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed)
  1297. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5 * Player_Size, 1 * Player_Size, 1 * Player_Size) * ANGLES(RAD(30), RAD(-690), RAD(2 - 2.5 * COS(SINE / 12) + 2.5 * SIN(SINE / 24))) * RIGHTSHOULDERC0, 0.15 / Animation_Speed/8)
  1298. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(90), RAD(25), RAD(45)) * LEFTSHOULDERC0, 0.15 / Animation_Speed/8)
  1299. RightHip.C0 = Clerp(RightHip.C0, CF(1 * Player_Size, -0.3 * Player_Size, -1 * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(-20)), 0.2 / Animation_Speed/8)
  1300. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -0.3 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(5), RAD(0)) * ANGLES(RAD(45), RAD(0), RAD(10)), 0.2 / Animation_Speed/8)
  1301. end
  1302. for i=0, 1, 0.1 / Animation_Speed*2 do
  1303. Swait()
  1304. RootPart.Anchored = true
  1305. RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0 * Player_Size, 0 * Player_Size, -1 * Player_Size) * ANGLES(RAD(45), RAD(0), RAD(0)), 0.2 / Animation_Speed*3)
  1306. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed)
  1307. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5 * Player_Size, 1 * Player_Size, -1.4 * Player_Size) * ANGLES(RAD(30), RAD(-690), RAD(2 - 2.5 * COS(SINE / 12) + 2.5 * SIN(SINE / 24))) * RIGHTSHOULDERC0, 0.15 / Animation_Speed*5)
  1308. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(90), RAD(25), RAD(45)) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
  1309. RightHip.C0 = Clerp(RightHip.C0, CF(1 * Player_Size, -0.3 * Player_Size, -1 * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(-20)), 0.2 / Animation_Speed)
  1310. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -0.3 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(5), RAD(0)) * ANGLES(RAD(45), RAD(0), RAD(10)), 0.2 / Animation_Speed)
  1311. end
  1312. CreateSound("186772924", beampart, 5, 1)
  1313. local floor = IT("Part",Effects)
  1314. floor.Anchored = true
  1315. floor.Size = VT(15,0.2,15)
  1316. floor.Material = "Neon"
  1317. floor.BrickColor = BRICKC("Dark indigo")
  1318. floor.CanCollide = false
  1319. local cyl = Instance.new("CylinderMesh",floor)
  1320. floor.CFrame = CF(beampart.Position.X,beampart.Position.Y-0.2,beampart.Position.Z)
  1321. AoEDamage(floor.Position,25,10,25,15,false,10,5,true)
  1322. local scale = 25
  1323. table.insert(Effects2,{floor,"Block1",0.05,1,0,1,2})
  1324. coroutine.resume(coroutine.create(function()
  1325. repeat
  1326. Swait()
  1327. scale = scale + 5
  1328. AoEDamage(floor.Position,scale,1,2,5,false,10,5,true)
  1329. until floor.Parent == nil
  1330. end))
  1331. end
  1332. ATTACK = false
  1333. Rooted = false
  1334. end
  1335.  
  1336. function GET_OVER_HERE()
  1337. CreateSound("131228548", beampart, 5, 1)
  1338. end
  1339.  
  1340. function fromabove()
  1341. Rooted = true
  1342. ATTACK = true
  1343. for i=0, 1, 0.1 / Animation_Speed do
  1344. Swait()
  1345. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0 * Player_Size, 0 * Player_Size, -0.2 * Player_Size + 0.05 * COS(SINE / 12) * Player_Size) * ANGLES(RAD(10), RAD(0), RAD(-20)), 0.15 / Animation_Speed/5)
  1346. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(5 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(15)), 0.15 / Animation_Speed)
  1347. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(0.75 * Player_Size, 0.5 * Player_Size, -1 * Player_Size) * ANGLES(RAD(70), RAD(0), RAD(-70)) * ANGLES(RAD(20), RAD(25), RAD(-15)) * RIGHTSHOULDERC0, 0.4 / Animation_Speed)
  1348. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(10 - 2.5 * COS(SINE / 16)), RAD(0), RAD(-25 + 2.5 * SIN(SINE / 24))) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
  1349. RightHip.C0 = Clerp(RightHip.C0, CF(1 * Player_Size, -0.8 * Player_Size - 0.05 * COS(SINE / 12) * Player_Size, -0.2 * Player_Size) * ANGLES(RAD(0), RAD(85), RAD(0)) * ANGLES(RAD(-5), RAD(0), RAD(-2.5)), 0.15 / Animation_Speed)
  1350. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -0.8 * Player_Size - 0.05 * COS(SINE / 12) * Player_Size, -0.2 * Player_Size) * ANGLES(RAD(0), RAD(-65), RAD(0)) * ANGLES(RAD(-7.5), RAD(0), RAD(-15)), 0.15 / Animation_Speed)
  1351. end
  1352. CreateSound("132392101", Head, 10, 1.1)
  1353. Swait(175)
  1354. for i=0, 1, 0.1 / Animation_Speed do
  1355. Swait()
  1356. RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0.05 * Player_Size, 0 * Player_Size, -0.1 * Player_Size) * ANGLES(RAD(10), RAD(0), RAD(40)), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
  1357. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(0), RAD(0), RAD(-40)) * ANGLES(RAD(-5), RAD(0), RAD(0)), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
  1358. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1 * Player_Size, 0.5 * Player_Size, -1 * Player_Size) * ANGLES(RAD(180), RAD(0), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 0.4 / Animation_Speed)
  1359. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1 * Player_Size, 0.2 * Player_Size, -0.5 * Player_Size) * ANGLES(RAD(25), RAD(25), RAD(90)) * LEFTSHOULDERC0, 0.4 / Animation_Speed)
  1360. RightHip.C0 = Clerp(RightHip.C0, CF(0.95 * Player_Size, -1 * Player_Size, -0.5 * Player_Size) * ANGLES(RAD(0), RAD(50), RAD(0)) * ANGLES(RAD(-1.25), RAD(0), RAD(0)), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
  1361. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -0.9 * Player_Size, 0.25 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-2.5), RAD(0), RAD(0)), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
  1362. end
  1363. local SIZE = 1
  1364. for i = 1, 70 do
  1365. MagicSphere("Dark indigo", "Neon", beampart.CFrame * ANGLES(RAD(MRANDOM(-50, 50)), RAD(MRANDOM(-50, 50)), RAD(MRANDOM(-50, 50))), ANGLES(RAD(MRANDOM(-5, 5)), RAD(MRANDOM(-5, 5)), RAD(MRANDOM(-5, 5))), VT(0, 0, 0), 0.25, 0.25, 0.25, SIZE, SIZE, SIZE, 0.05)
  1366. Swait()
  1367. SIZE = SIZE + 0.06
  1368. end
  1369.  
  1370. local laser = IT("Part",Effects)
  1371. laser.CanCollide = false
  1372. laser.Anchored = true
  1373. local distance = (beampart.Position - VT(beampart.Position.X,beampart.Position.Y+1000,beampart.Position.Z)).magnitude
  1374. laser.Size = Vector3.new(0.2, 0.2, distance)
  1375. laser.CFrame = CFrame.new(beampart.Position,VT(beampart.Position.X,beampart.Position.Y+1000,beampart.Position.Z)) * CFrame.new(0, 0, -distance/2)
  1376. laser.Material = "Neon"
  1377. laser.BrickColor = BRICKC("Dark indigo")
  1378. table.insert(Effects2,{laser,"Disappear",0.05,2,2,2,2})
  1379. ATTACK = false
  1380. Rooted = false
  1381. local pos = Mouse.Hit.p
  1382. Swait(10)
  1383. for i = 1, 85 do
  1384. coroutine.resume(coroutine.create(function()
  1385. Swait(math.random(1,100))
  1386. local pos = VT(pos.X+math.random(-15,15),pos.Y,pos.Z+math.random(-15,15))
  1387. local laser = IT("Part",Effects)
  1388. laser.CanCollide = false
  1389. laser.Anchored = true
  1390. local distance = (pos - VT(pos.X,pos.Y+1000,pos.Z)).magnitude
  1391. laser.Size = Vector3.new(0.2, 0.2, distance)
  1392. laser.CFrame = CFrame.new(pos,VT(pos.X,pos.Y+1000,pos.Z)) * CFrame.new(0, 0, -distance/2)
  1393. laser.Material = "Neon"
  1394. laser.BrickColor = BRICKC("Dark indigo")
  1395. MagicSphere("Dark indigo", "Neon", CF(pos) * ANGLES(RAD(MRANDOM(-50, 50)), RAD(MRANDOM(-50, 50)), RAD(MRANDOM(-50, 50))), ANGLES(RAD(MRANDOM(-5, 5)), RAD(MRANDOM(-5, 5)), RAD(MRANDOM(-5, 5))), VT(0, 0, 0), 0.25, 0.25, 0.25, 7.5, 7.5, 7.5, 0.05)
  1396. MagicBlock("Dark indigo", "Neon", CF(pos) * ANGLES(RAD(MRANDOM(-50, 50)), RAD(MRANDOM(-50, 50)), RAD(MRANDOM(-50, 50))), ANGLES(RAD(MRANDOM(-5, 5)), RAD(MRANDOM(-5, 5)), RAD(MRANDOM(-5, 5))), VT(0, 0, 0), 0.25, 0.25, 0.25, 7.5, 7.5, 7.5, 0.05)
  1397. table.insert(Effects2,{laser,"Disappear",0.05,2,2,2,2})
  1398. AoEDamage(pos,5,15,25,12,false,10,2)
  1399. end))
  1400. end
  1401. end
  1402.  
  1403.  
  1404.  
  1405.  
  1406. --//=================================\\
  1407. --|| ASSIGN THINGS TO KEYS
  1408. --\\=================================//
  1409.  
  1410. Humanoid.Changed:connect(function(Jump)
  1411. if Jump == "Jump" and (Disable_Jump == true or DISABLEJUMPING == true) then
  1412. Humanoid.Jump = false
  1413. end
  1414. end)
  1415.  
  1416. function MouseDown(Mouse)
  1417. if ATTACK == false then
  1418. --HOLD = true
  1419. Shoot()
  1420. end
  1421. end
  1422.  
  1423. function MouseUp(Mouse)
  1424. HOLD = false
  1425. end
  1426.  
  1427. function KeyDown(Key)
  1428. KEYHOLD = true
  1429. if Key == "e" and ATTACK == false then
  1430. ChargeShot()
  1431. end
  1432. if Key == "g" and ATTACK == false then
  1433. GroundUp()
  1434. end
  1435. if Key == "p" then
  1436. if SPRINTING == false then
  1437. SPRINTING = true
  1438. elseif SPRINTING == true then
  1439. SPRINTING = false
  1440. end
  1441. end
  1442. if Key == "x" and ATTACK == false then
  1443. fromabove()
  1444. end
  1445. if Key == "t" and ATTACK == false then
  1446. CreateSound("132392118", Head, 10, 1.1)
  1447. end
  1448. if Key == "g" then
  1449. CreateSound("907332525", Head, 10, 1.1)
  1450. if Key == "v" then
  1451. GET_OVER_HERE()
  1452. end
  1453. end
  1454. end
  1455.  
  1456. function KeyUp(Key)
  1457. KEYHOLD = false
  1458. end
  1459.  
  1460. Mouse.Button1Down:connect(function(NEWKEY)
  1461. MouseDown(NEWKEY)
  1462. end)
  1463. Mouse.Button1Up:connect(function(NEWKEY)
  1464. MouseUp(NEWKEY)
  1465. end)
  1466. Mouse.KeyDown:connect(function(NEWKEY)
  1467. KeyDown(NEWKEY)
  1468. end)
  1469. Mouse.KeyUp:connect(function(NEWKEY)
  1470. KeyUp(NEWKEY)
  1471. end)
  1472.  
  1473. --//=================================\\
  1474. --\\=================================//
  1475.  
  1476.  
  1477. function unanchor()
  1478. if UNANCHOR == true then
  1479. g = Character:GetChildren()
  1480. for i = 1, #g do
  1481. if g[i].ClassName == "Part" then
  1482. g[i].Anchored = false
  1483. end
  1484. end
  1485. end
  1486. end
  1487.  
  1488. --//=================================\\
  1489. --|| WRAP THE WHOLE SCRIPT UP
  1490. --\\=================================//
  1491.  
  1492. Humanoid.Changed:connect(function(Jump)
  1493. if Jump == "Jump" and (Disable_Jump == true or DISABLEJUMPING == true) then
  1494. Humanoid.Jump = false
  1495. end
  1496. end)
  1497.  
  1498. Rooted = true
  1499. ANIMATE.Parent = nil
  1500. local IDLEANIMATION = Humanoid:LoadAnimation(ROBLOXIDLEANIMATION)
  1501. IDLEANIMATION:Play()
  1502. Swait(15)
  1503. Rooted = false
  1504.  
  1505. while true do
  1506. Swait()
  1507. SINE = SINE + CHANGE
  1508. local TORSOVELOCITY = (RootPart.Velocity * VT(1, 0, 1)).magnitude
  1509. local TORSOVERTICALVELOCITY = RootPart.Velocity.y
  1510. local LV = Torso.CFrame:pointToObjectSpace(Torso.Velocity - Torso.Position)
  1511. local HITFLOOR = Raycast(RootPart.Position, (CF(RootPart.Position, RootPart.Position + VT(0, -1, 0))).lookVector, 4 * Player_Size, Character)
  1512. local WALKSPEEDVALUE = 6 / (Humanoid.WalkSpeed / 16)
  1513. if ANIM == "Walk" and TORSOVELOCITY > 1 then
  1514. RootJoint.C1 = Clerp(RootJoint.C1, ROOTC0 * CF(0, 0, -0.1 * COS(SINE / (WALKSPEEDVALUE / 2)) * Player_Size) * ANGLES(RAD(0), RAD(0) - RootPart.RotVelocity.Y / 75, RAD(0)), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
  1515. Neck.C1 = Clerp(Neck.C1, CF(0 * Player_Size, -0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(-90), RAD(0), RAD(180)) * ANGLES(RAD(2.5 * SIN(SINE / (WALKSPEEDVALUE / 2))), RAD(0), RAD(0) - Head.RotVelocity.Y / 30), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
  1516. RightHip.C1 = Clerp(RightHip.C1, CF(0.5 * Player_Size, 0.875 * Player_Size - 0.125 * SIN(SINE / WALKSPEEDVALUE) * Player_Size, -0.125 * COS(SINE / WALKSPEEDVALUE) * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0) - RightLeg.RotVelocity.Y / 75, RAD(0), RAD(60 * COS(SINE / WALKSPEEDVALUE))), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
  1517. LeftHip.C1 = Clerp(LeftHip.C1, CF(-0.5 * Player_Size, 0.875 * Player_Size + 0.125 * SIN(SINE / WALKSPEEDVALUE) * Player_Size, 0.125 * COS(SINE / WALKSPEEDVALUE) * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0) + LeftLeg.RotVelocity.Y / 75, RAD(0), RAD(60 * COS(SINE / WALKSPEEDVALUE))), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
  1518. elseif (ANIM ~= "Walk") or (TORSOVELOCITY < 1) then
  1519. RootJoint.C1 = Clerp(RootJoint.C1, ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed)
  1520. Neck.C1 = Clerp(Neck.C1, CF(0 * Player_Size, -0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(-90), RAD(0), RAD(180)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed)
  1521. RightHip.C1 = Clerp(RightHip.C1, CF(0.5 * Player_Size, 1 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed)
  1522. LeftHip.C1 = Clerp(LeftHip.C1, CF(-0.5 * Player_Size, 1 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed)
  1523. end
  1524. if TORSOVERTICALVELOCITY > 1 and HITFLOOR == nil then
  1525. ANIM = "Jump"
  1526. if ATTACK == false then
  1527. RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0 * Player_Size, 0 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed)
  1528. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(-20), RAD(0), RAD(0)), 0.2 / Animation_Speed)
  1529. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(-40), RAD(0), RAD(20)) * RIGHTSHOULDERC0, 0.2 / Animation_Speed)
  1530. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(-40), RAD(0), RAD(-20)) * LEFTSHOULDERC0, 0.2 / Animation_Speed)
  1531. RightHip.C0 = Clerp(RightHip.C0, CF(1 * Player_Size, -1 * Player_Size, -0.3 * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-5), RAD(0), RAD(-20)), 0.2 / Animation_Speed)
  1532. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -1 * Player_Size, -0.3 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-5), RAD(0), RAD(20)), 0.2 / Animation_Speed)
  1533. end
  1534. elseif TORSOVERTICALVELOCITY < -1 and HITFLOOR == nil then
  1535. ANIM = "Fall"
  1536. if ATTACK == false then
  1537. RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0 * Player_Size, 0 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed)
  1538. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(20), RAD(0), RAD(0)), 0.2 / Animation_Speed)
  1539. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(60)) * RIGHTSHOULDERC0, 0.2 / Animation_Speed)
  1540. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(-60)) * LEFTSHOULDERC0, 0.2 / Animation_Speed)
  1541. RightHip.C0 = Clerp(RightHip.C0, CF(1 * Player_Size, -1 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(20)), 0.2 / Animation_Speed)
  1542. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1 * Player_Size, -1 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(10)), 0.2 / Animation_Speed)
  1543. end
  1544. elseif TORSOVELOCITY < 1 and HITFLOOR ~= nil then
  1545. ANIM = "Idle"
  1546. if ATTACK == false then
  1547. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(4 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed)
  1548. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15 + 4.5 * SIN(SINE / 12)), RAD(0), RAD(0 - 4 * SIN(SINE / 12))), 1 / Animation_Speed)
  1549. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1, 0.5 + 0.025 * COS(SINE / 12), -1) * ANGLES(RAD(0), RAD(0 - 7.5 * SIN(SINE / 12)), RAD(-90 + 7.5 * SIN(SINE / 12))) * RIGHTSHOULDERC0, 1 / Animation_Speed)
  1550. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1, 0 + 0.025 * COS(SINE / 12), -1) * ANGLES(RAD(25), RAD(0 + 7.5 * SIN(SINE / 12)), RAD(90 - 7.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed)
  1551. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.01) * ANGLES(RAD(-7.5 * SIN(SINE / 12)), RAD(75), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed)
  1552. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.5, -0.5) * ANGLES(RAD(-7.5 * SIN(SINE / 12)), RAD(-90), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed)
  1553. end
  1554. elseif TORSOVELOCITY > 1 and HITFLOOR ~= nil then
  1555. ANIM = "Walk"
  1556. WALK = WALK + 1 / Animation_Speed
  1557. if WALK >= 15 - (5 * (Humanoid.WalkSpeed / 16 / Player_Size)) then
  1558. WALK = 0
  1559. if WALKINGANIM == true then
  1560. WALKINGANIM = false
  1561. elseif WALKINGANIM == false then
  1562. WALKINGANIM = true
  1563. end
  1564. end
  1565. --RightHip.C1 = Clerp(RightHip.C1, CF(0.5 * Player_Size, 0.875 * Player_Size - 0.125 * SIN(SINE / WALKSPEEDVALUE) * Player_Size, -0.125 * COS(SINE / WALKSPEEDVALUE) * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0) - RightLeg.RotVelocity.Y / 75, RAD(0), RAD(60 * COS(SINE / WALKSPEEDVALUE))), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
  1566. --LeftHip.C1 = Clerp(LeftHip.C1, CF(-0.5 * Player_Size, 0.875 * Player_Size + 0.125 * SIN(SINE / WALKSPEEDVALUE) * Player_Size, 0.125 * COS(SINE / WALKSPEEDVALUE) * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0) + LeftLeg.RotVelocity.Y / 75, RAD(0), RAD(60 * COS(SINE / WALKSPEEDVALUE))), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
  1567. if ATTACK == false and SPRINTING == false then
  1568. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(15 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(2.5 + 2.5 * SIN(SINE / 12))), 1 / Animation_Speed)
  1569. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(-10 + 4.5 * SIN(SINE / 12)), RAD(0), RAD(-2.5 - 2.5 * SIN(SINE / 12))), 1 / Animation_Speed)
  1570. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1, 0.5 + 0.025 * COS(SINE / 12), -1) * ANGLES(RAD(0), RAD(0 - 7.5 * SIN(SINE / 12)), RAD(-90 + 7.5 * SIN(SINE / 12))) * RIGHTSHOULDERC0, 1 / Animation_Speed)
  1571. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1, 0 + 0.025 * COS(SINE / 12), -1) * ANGLES(RAD(25), RAD(0 + 7.5 * SIN(SINE / 12)), RAD(90 - 7.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed)
  1572. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.01) * ANGLES(RAD(-25-2.5 * SIN(SINE / 12)), RAD(75), RAD(0)) * ANGLES(RAD(-8 - 5.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed)
  1573. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.5, -0.5) * ANGLES(RAD(-2.5 * SIN(SINE / 12)), RAD(-90), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed)
  1574. elseif ATTACK == false and SPRINTING == true then
  1575. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(15 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(2.5 + 2.5 * SIN(SINE / 12))), 1 / Animation_Speed)
  1576. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(-10 + 4.5 * SIN(SINE / 12)), RAD(0), RAD(-2.5 - 2.5 * SIN(SINE / 12))), 1 / Animation_Speed)
  1577. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1, 0.5 + 0.025 * COS(SINE / 12), -1) * ANGLES(RAD(0), RAD(0 - 7.5 * SIN(SINE / 12)), RAD(-90 + 7.5 * SIN(SINE / 12))) * RIGHTSHOULDERC0, 1 / Animation_Speed)
  1578. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1, 0 + 0.025 * COS(SINE / 12), -1) * ANGLES(RAD(25), RAD(0 + 7.5 * SIN(SINE / 12)), RAD(90 - 7.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed)
  1579. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.01) * ANGLES(RAD(-25-2.5 * SIN(SINE / 12)), RAD(75), RAD(0)) * ANGLES(RAD(-8 - 5.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed)
  1580. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.5, -0.5) * ANGLES(RAD(-2.5 * SIN(SINE / 12)), RAD(-90), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed)
  1581. end
  1582. end
  1583. if #Effects2>0 then
  1584. for e=1,#Effects2 do
  1585. if Effects2[e]~=nil then
  1586. local Thing=Effects2[e]
  1587. if Thing~=nil then
  1588. local Part=Thing[1]
  1589. local Mode=Thing[2]
  1590. local Delay=Thing[3]
  1591. local IncX=Thing[4]
  1592. local IncY=Thing[5]
  1593. local IncZ=Thing[6]
  1594. local Part2=Thing[8]
  1595. if Thing[1].Transparency<=1 then
  1596. if Thing[2]=="Block1" then
  1597. Thing[1].CFrame=Thing[1].CFrame
  1598. Mesh=Thing[1].Mesh
  1599. Mesh.Scale=Mesh.Scale+VT(Thing[4],Thing[5],Thing[6])
  1600. Thing[1].Transparency=Thing[1].Transparency+Thing[3]
  1601. elseif Thing[2]=="Cylinder" then
  1602. Mesh=Thing[1].Mesh
  1603. Mesh.Scale=Mesh.Scale+VT(Thing[4],Thing[5],Thing[6])
  1604. Thing[1].Transparency=Thing[1].Transparency+Thing[3]
  1605. elseif Thing[2]=="Blood" then
  1606. Mesh=Thing[7]
  1607. Thing[1].CFrame=Thing[1].CFrame*CF(0,.5,0)
  1608. Mesh.Scale=Mesh.Scale+VT(Thing[4],Thing[5],Thing[6])
  1609. Thing[1].Transparency=Thing[1].Transparency+Thing[3]
  1610. elseif Thing[2]=="Elec" then
  1611. Mesh=Thing[1].Mesh
  1612. Mesh.Scale=Mesh.Scale+VT(Thing[7],Thing[8],Thing[9])
  1613. Thing[1].Transparency=Thing[1].Transparency+Thing[3]
  1614. elseif Thing[2]=="Disappear" then
  1615. Thing[1].Transparency=Thing[1].Transparency+Thing[3]
  1616. end
  1617. else
  1618. Part.Parent=nil
  1619. table.remove(Effects2,e)
  1620. end
  1621. end
  1622. end
  1623. end
  1624. end
  1625. unanchor()
  1626. Humanoid.MaxHealth = "inf"
  1627. Humanoid.Health = "inf"
  1628. if Rooted == false then
  1629. Disable_Jump = false
  1630. Humanoid.WalkSpeed = Speed
  1631. elseif Rooted == true then
  1632. Disable_Jump = true
  1633. Humanoid.WalkSpeed = 0
  1634. end
  1635. if SPRINTING == true then
  1636. Speed = 45
  1637. Humanoid.JumpPower = 100
  1638. elseif SPRINTING == false then
  1639. Speed = 16
  1640. Humanoid.JumpPower = 50
  1641. end
  1642. end
  1643.  
  1644. --//=================================\\
  1645. --\\=================================//
  1646.  
  1647.  
  1648.  
  1649.  
  1650.  
  1651. --//====================================================\\--
  1652. --|| END OF SCRIPT
  1653. --\\====================================================//--
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement