Advertisement
Unspecifi_ed

Untitled

Feb 26th, 2018
182
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 41.58 KB | None | 0 0
  1. --//====================================================\\--
  2. --|| CREATED BY Shacluster
  3. --\\====================================================//--
  4.  
  5.  
  6.  
  7. wait(0.2)
  8.  
  9.  
  10.  
  11.  
  12. local naeeym2 = Instance.new("BillboardGui",Character)
  13. naeeym2.AlwaysOnTop = true
  14. naeeym2.Size = UDim2.new(5,35,2,35)
  15. naeeym2.StudsOffset = Vector3.new(0,3,0)
  16. naeeym2.Adornee = Character.Head
  17. naeeym2.Name = "Unspecifi_ed"
  18. --naeeym2.PlayerToHideFrom = Player
  19. naeeym2.MaxDistance = 200
  20. local tecks2 = Instance.new("TextLabel",naeeym2)
  21. tecks2.BackgroundTransparency = 1
  22. tecks2.TextScaled = true
  23. tecks2.BorderSizePixel = 0
  24. tecks2.Text = "The living singularity"
  25. tecks2.Font = "Antique"
  26. tecks2.TextSize = 30
  27. tecks2.TextStrokeTransparency = 1
  28. tecks2.TextColor3 = Color3.new(0,0,0)
  29. tecks2.TextStrokeColor3 = Color3.new(0,0,1)
  30. tecks2.Size = UDim2.new(1,0,0.5,0)
  31. tecks2.Parent = naeeym2
  32.  
  33. IT = Instance.new
  34. CF = CFrame.new
  35. VT = Vector3.new
  36. RAD = math.rad
  37. C3 = Color3.new
  38. UD2 = UDim2.new
  39. BRICKC = BrickColor.new
  40. ANGLES = CFrame.Angles
  41. EULER = CFrame.fromEulerAnglesXYZ
  42. COS = math.cos
  43. ACOS = math.acos
  44. SIN = math.sin
  45. ASIN = math.asin
  46. ABS = math.abs
  47. MRANDOM = math.random
  48. FLOOR = math.floor
  49.  
  50. function CreateMesh(MESH, PARENT, MESHTYPE, MESHID, TEXTUREID, SCALE, OFFSET)
  51. local NEWMESH = IT(MESH)
  52. if MESH == "SpecialMesh" then
  53. NEWMESH.MeshType = MESHTYPE
  54. if MESHID ~= "nil" and MESHID ~= "" then
  55. NEWMESH.MeshId = "http://www.roblox.com/asset/?id="..MESHID
  56. end
  57. if TEXTUREID ~= "nil" and TEXTUREID ~= "" then
  58. NEWMESH.TextureId = "http://www.roblox.com/asset/?id="..TEXTUREID
  59. end
  60. end
  61. NEWMESH.Offset = OFFSET or VT(0, 0, 0)
  62. NEWMESH.Scale = SCALE
  63. NEWMESH.Parent = PARENT
  64. return NEWMESH
  65. end
  66.  
  67. function CreatePart(FORMFACTOR, PARENT, MATERIAL, REFLECTANCE, TRANSPARENCY, BRICKCOLOR, NAME, SIZE)
  68. local NEWPART = IT("Part")
  69. NEWPART.formFactor = FORMFACTOR
  70. NEWPART.Reflectance = REFLECTANCE
  71. NEWPART.Transparency = TRANSPARENCY
  72. NEWPART.CanCollide = false
  73. NEWPART.Locked = true
  74. NEWPART.BrickColor = BRICKC(tostring(BRICKCOLOR))
  75. NEWPART.Name = NAME
  76. NEWPART.Size = SIZE
  77. NEWPART.Position = Torso.Position
  78. NEWPART.Material = MATERIAL
  79. NEWPART:BreakJoints()
  80. NEWPART.Parent = PARENT
  81. return NEWPART
  82. end
  83.  
  84.  
  85. --//=================================\\
  86. --|| CUSTOMIZATION
  87. --\\=================================//
  88.  
  89. Class_Name = "LivingSingularity.exe"
  90. Weapon_Name = "Add-ons"
  91.  
  92. Custom_Colors = {
  93. Custom_Color_1 = BRICKC("Institutional white"); --1st color for the weapon.
  94. Custom_Color_2 = BRICKC("Institutional white"); --2nd color for the weapon.
  95.  
  96. Custom_Color_3 = BRICKC("Institutional white"); --Color for the abilities.
  97. Custom_Color_4 = BRICKC("Institutional white"); --Color for the secondary bar.
  98. Custom_Color_5 = BRICKC("Institutional white"); --Color for the mana bar.
  99. Custom_Color_6 = BRICKC("Institutional white"); --Color for the health bar.
  100. Custom_Color_7 = BRICKC("Institutional white"); --Color for the stun bar.
  101.  
  102. Custom_Color_8 = BRICKC("Institutional white"); --Background for the mana bar.
  103. Custom_Color_9 = BRICKC("Institutional white"); --Background for the secondary mana bar.
  104. Custom_Color_10 = BRICKC("Institutional white"); --Background for the stun bar.
  105. Custom_Color_11 = BRICKC("Institutional white"); --Background for the health bar.
  106. Custom_Color_12 = BRICKC("Institutional white"); --Background for the abilities.
  107. }
  108.  
  109.  
  110. Player_Size = 1 --Size of the player.
  111. Animation_Speed = 3
  112. Frame_Speed = 1 / 60 -- (1 / 30) OR (1 / 60)
  113.  
  114. local Speed = 16
  115. local Effects2 = {}
  116.  
  117. --//=================================\\
  118. --|| END OF CUSTOMIZATION
  119. --\\=================================//
  120.  
  121. local function weldBetween(a, b)
  122. local weldd = Instance.new("ManualWeld")
  123. weldd.Part0 = a
  124. weldd.Part1 = b
  125. weldd.C0 = CFrame.new()
  126. weldd.C1 = b.CFrame:inverse() * a.CFrame
  127. weldd.Parent = a
  128. return weldd
  129. end
  130.  
  131. function createaccessory(attachmentpart,mesh,texture,scale,offset,color)
  132. local acs = Instance.new("Part")
  133. acs.CanCollide = false
  134. acs.Anchored = false
  135. acs.Size = Vector3.new(0,0,0)
  136. acs.CFrame = attachmentpart.CFrame
  137. acs.Parent = Character
  138. acs.BrickColor = color
  139. local meshs = Instance.new("SpecialMesh")
  140. meshs.MeshId = mesh
  141. meshs.TextureId = texture
  142. meshs.Parent = acs
  143. meshs.Scale = scale
  144. meshs.Offset = offset
  145. weldBetween(attachmentpart,acs)
  146. end
  147.  
  148. function createbodypart(TYPE,COLOR,PART,OFFSET,SIZE)
  149. if TYPE == "Gem" then
  150. local acs = CreatePart(3, Character, "Plastic", 0, 0, COLOR, "Part", VT(0,0,0))
  151. acs.Anchored = false
  152. acs.CanCollide = false
  153. acs.CFrame = PART.CFrame
  154. local acs2 = CreateMesh("SpecialMesh", acs, "FileMesh", "9756362", "", SIZE, OFFSET)
  155. weldBetween(PART,acs)
  156. elseif TYPE == "Skull" then
  157. local acs = CreatePart(3, Character, "Plastic", 0, 0, COLOR, "Part", VT(0,0,0))
  158. acs.Anchored = false
  159. acs.CanCollide = false
  160. acs.CFrame = PART.CFrame
  161. local acs2 = CreateMesh("SpecialMesh", acs, "FileMesh", "4770583", "", SIZE, OFFSET)
  162. weldBetween(PART,acs)
  163. elseif TYPE == "Eye" then
  164. local acs = CreatePart(3, Character, "Neon", 0, 0, COLOR, "Part", VT(0,0,0))
  165. acs.Anchored = false
  166. acs.CanCollide = false
  167. acs.CFrame = PART.CFrame
  168. local acs2 = CreateMesh("SpecialMesh", acs, "Sphere", "", "", SIZE, OFFSET)
  169. weldBetween(PART,acs)
  170. end
  171. end
  172.  
  173. --//=================================\\
  174. --|| USEFUL VALUES
  175. --\\=================================//
  176.  
  177. local ROOTC0 = CF(0, 0, 0) * ANGLES(RAD(-90), RAD(0), RAD(180))
  178. local NECKC0 = CF(0, 1, 0) * ANGLES(RAD(-90), RAD(0), RAD(180))
  179. local RIGHTSHOULDERC0 = CF(-0.5, 0, 0) * ANGLES(RAD(0), RAD(90), RAD(0))
  180. local LEFTSHOULDERC0 = CF(0.5, 0, 0) * ANGLES(RAD(0), RAD(-90), RAD(0))
  181. local CO1 = 0
  182. local CO2 = 0
  183. local CO3 = 0
  184. local CO4 = 0
  185. local CHANGEDEFENSE = 0
  186. local CHANGEDAMAGE = 0
  187. local CHANGEMOVEMENT = 0
  188. local ANIM = "Idle"
  189. local ATTACK = false
  190. local EQUIPPED = false
  191. local HOLD = false
  192. local COMBO = 1
  193. local LASTPOINT = nil
  194. local BLCF = nil
  195. local SCFR = nil
  196. local STAGGERHITANIM = false
  197. local STAGGERANIM = false
  198. local STUNANIM = false
  199. local CRITCHANCENUMBER = 0
  200. local IDLENUMBER = 0
  201. local DONUMBER = 0
  202. local HANDIDLE = false
  203. local SINE = 0
  204. local CHANGE = 2 / Animation_Speed
  205. local WALKINGANIM = false
  206. local WALK = 0
  207. local KEYHOLD = false
  208. local DISABLEJUMPING = false
  209. local HASBEENBLOCKED = false
  210. local STUNDELAYNUMBER = 0
  211. local MANADELAYNUMBER = 0
  212. local SECONDARYMANADELAYNUMBER = 0
  213. local ROBLOXIDLEANIMATION = IT("Animation")
  214. ROBLOXIDLEANIMATION.Name = "Roblox Idle Animation"
  215. ROBLOXIDLEANIMATION.AnimationId = "http://www.roblox.com/asset/?id=180435571"
  216. --ROBLOXIDLEANIMATION.Parent = Humanoid
  217. local WEAPONGUI = IT("ScreenGui", nil)
  218. WEAPONGUI.Name = "Weapon GUI"
  219. local WEAPONTOOL = IT("HopperBin", nil)
  220. WEAPONTOOL.Name = Weapon_Name
  221. local Weapon = IT("Model")
  222. Weapon.Name = Weapon_Name
  223. local Effects = IT("Folder", Weapon)
  224. Effects.Name = "Effects"
  225. local ANIMATOR = Humanoid.Animator
  226. local ANIMATE = Character.Animate
  227. local HITPLAYERSOUNDS = {--[["199149137", "199149186", "199149221", "199149235", "199149269", "199149297"--]]"263032172", "263032182", "263032200", "263032221", "263032252", "263033191"}
  228. local HITARMORSOUNDS = {"199149321", "199149338", "199149367", "199149409", "199149452"}
  229. local HITWEAPONSOUNDS = {"199148971", "199149025", "199149072", "199149109", "199149119"}
  230. local HITBLOCKSOUNDS = {"199148933", "199148947"}
  231. local CUTSOUNDS = {"645750958","645747150"}
  232. local VICIOUSWOOSH = "658941933"
  233. local RELEASESOUND = "565538688"
  234. local CHARGESOUND = "565538601"
  235. local UNANCHOR = true
  236. local MAGICPARTICLE = "1216996144"
  237.  
  238. --//=================================\\
  239. --\\=================================//
  240.  
  241. --//=================================\\
  242. --|| STATS
  243. --\\=================================//
  244.  
  245. if Character:FindFirstChild("Stats") ~= nil then
  246. Character:FindFirstChild("Stats").Parent = nil
  247. end
  248.  
  249. local Stats = IT("Folder", nil)
  250. Stats.Name = "Stats"
  251. local ChangeStat = IT("Folder", Stats)
  252. ChangeStat.Name = "ChangeStat"
  253. local Defense = IT("NumberValue", Stats)
  254. Defense.Name = "Defense"
  255. Defense.Value = 1
  256. local Movement = IT("NumberValue", Stats)
  257. Movement.Name = "Movement"
  258. Movement.Value = 1
  259. local Damage = IT("NumberValue", Stats)
  260. Damage.Name = "Damage"
  261. Damage.Value = 1
  262. local Mana = IT("NumberValue", Stats)
  263. Mana.Name = "Mana"
  264. Mana.Value = 0
  265. local SecondaryMana = IT("NumberValue", Stats)
  266. SecondaryMana.Name = "SecondaryMana"
  267. SecondaryMana.Value = 0
  268. local CanCrit = IT("BoolValue", Stats)
  269. CanCrit.Name = "CanCrit"
  270. CanCrit.Value = false
  271. local CritChance = IT("NumberValue", Stats)
  272. CritChance.Name = "CritChance"
  273. CritChance.Value = 20
  274. local CanPenetrateArmor = IT("BoolValue", Stats)
  275. CanPenetrateArmor.Name = "CanPenetrateArmor"
  276. CanPenetrateArmor.Value = false
  277. local AntiTeamKill = IT("BoolValue", Stats)
  278. AntiTeamKill.Name = "AntiTeamKill"
  279. AntiTeamKill.Value = false
  280. local Rooted = IT("BoolValue", Stats)
  281. Rooted.Name = "Rooted"
  282. Rooted.Value = false
  283. local Block = IT("BoolValue", Stats)
  284. Block.Name = "Block"
  285. Block.Value = false
  286. local RecentEnemy = IT("ObjectValue", Stats)
  287. RecentEnemy.Name = "RecentEnemy"
  288. RecentEnemy.Value = nil
  289. local StaggerHit = IT("BoolValue", Stats)
  290. StaggerHit.Name = "StaggerHit"
  291. StaggerHit.Value = false
  292. local Stagger = IT("BoolValue", Stats)
  293. Stagger.Name = "Stagger"
  294. Stagger.Value = false
  295. local Stun = IT("BoolValue", Stats)
  296. Stun.Name = "Stun"
  297. Stun.Value = false
  298. local StunValue = IT("NumberValue", Stats)
  299. StunValue.Name = "StunValue"
  300. StunValue.Value = 0
  301.  
  302.  
  303. --//=================================\\
  304. --\\=================================//
  305.  
  306.  
  307.  
  308.  
  309.  
  310. --//=================================\\
  311. --|| DEBUFFS / BUFFS
  312. --\\=================================//
  313.  
  314. local DEFENSECHANGE1 = IT("NumberValue", ChangeStat)
  315. DEFENSECHANGE1.Name = "ChangeDefense"
  316. DEFENSECHANGE1.Value = 0
  317.  
  318. local MOVEMENTCHANGE1 = IT("NumberValue", nil)
  319. MOVEMENTCHANGE1.Name = "ChangeMovement"
  320. MOVEMENTCHANGE1.Value = 0
  321.  
  322. --//=================================\\
  323. --\\=================================//
  324.  
  325.  
  326.  
  327.  
  328.  
  329. --//=================================\\
  330. --|| SAZERENOS' ARTIFICIAL HEARTBEAT
  331. --\\=================================//
  332.  
  333. ArtificialHB = Instance.new("BindableEvent", script)
  334. ArtificialHB.Name = "ArtificialHB"
  335.  
  336. script:WaitForChild("ArtificialHB")
  337.  
  338. frame = Frame_Speed
  339. tf = 0
  340. allowframeloss = false
  341. tossremainder = false
  342. lastframe = tick()
  343. script.ArtificialHB:Fire()
  344.  
  345. game:GetService("RunService").Heartbeat:connect(function(s, p)
  346. tf = tf + s
  347. if tf >= frame then
  348. if allowframeloss then
  349. script.ArtificialHB:Fire()
  350. lastframe = tick()
  351. else
  352. for i = 1, math.floor(tf / frame) do
  353. script.ArtificialHB:Fire()
  354. end
  355. lastframe = tick()
  356. end
  357. if tossremainder then
  358. tf = 0
  359. else
  360. tf = tf - frame * math.floor(tf / frame)
  361. end
  362. end
  363. end)
  364.  
  365. --//=================================\\
  366. --\\=================================//
  367.  
  368.  
  369.  
  370.  
  371.  
  372. --//=================================\\
  373. --|| SOME FUNCTIONS
  374. --\\=================================//
  375.  
  376. function Raycast(POSITION, DIRECTION, RANGE, IGNOREDECENDANTS)
  377. return workspace:FindPartOnRay(Ray.new(POSITION, DIRECTION.unit * RANGE), IGNOREDECENDANTS)
  378. end
  379.  
  380. function PositiveAngle(NUMBER)
  381. if NUMBER >= 0 then
  382. NUMBER = 0
  383. end
  384. return NUMBER
  385. end
  386.  
  387. function NegativeAngle(NUMBER)
  388. if NUMBER <= 0 then
  389. NUMBER = 0
  390. end
  391. return NUMBER
  392. end
  393.  
  394. function Swait(NUMBER)
  395. if NUMBER == 0 or NUMBER == nil then
  396. ArtificialHB.Event:wait()
  397. else
  398. for i = 1, NUMBER do
  399. ArtificialHB.Event:wait()
  400. end
  401. end
  402. end
  403.  
  404. function QuaternionFromCFrame(cf)
  405. local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components()
  406. local trace = m00 + m11 + m22
  407. if trace > 0 then
  408. local s = math.sqrt(1 + trace)
  409. local recip = 0.5 / s
  410. return (m21 - m12) * recip, (m02 - m20) * recip, (m10 - m01) * recip, s * 0.5
  411. else
  412. local i = 0
  413. if m11 > m00 then
  414. i = 1
  415. end
  416. if m22 > (i == 0 and m00 or m11) then
  417. i = 2
  418. end
  419. if i == 0 then
  420. local s = math.sqrt(m00 - m11 - m22 + 1)
  421. local recip = 0.5 / s
  422. return 0.5 * s, (m10 + m01) * recip, (m20 + m02) * recip, (m21 - m12) * recip
  423. elseif i == 1 then
  424. local s = math.sqrt(m11 - m22 - m00 + 1)
  425. local recip = 0.5 / s
  426. return (m01 + m10) * recip, 0.5 * s, (m21 + m12) * recip, (m02 - m20) * recip
  427. elseif i == 2 then
  428. local s = math.sqrt(m22 - m00 - m11 + 1)
  429. local recip = 0.5 / s return (m02 + m20) * recip, (m12 + m21) * recip, 0.5 * s, (m10 - m01) * recip
  430. end
  431. end
  432. end
  433.  
  434. function QuaternionToCFrame(px, py, pz, x, y, z, w)
  435. local xs, ys, zs = x + x, y + y, z + z
  436. local wx, wy, wz = w * xs, w * ys, w * zs
  437. local xx = x * xs
  438. local xy = x * ys
  439. local xz = x * zs
  440. local yy = y * ys
  441. local yz = y * zs
  442. local zz = z * zs
  443. 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))
  444. end
  445.  
  446. function QuaternionSlerp(a, b, t)
  447. local cosTheta = a[1] * b[1] + a[2] * b[2] + a[3] * b[3] + a[4] * b[4]
  448. local startInterp, finishInterp;
  449. if cosTheta >= 0.0001 then
  450. if (1 - cosTheta) > 0.0001 then
  451. local theta = ACOS(cosTheta)
  452. local invSinTheta = 1 / SIN(theta)
  453. startInterp = SIN((1 - t) * theta) * invSinTheta
  454. finishInterp = SIN(t * theta) * invSinTheta
  455. else
  456. startInterp = 1 - t
  457. finishInterp = t
  458. end
  459. else
  460. if (1 + cosTheta) > 0.0001 then
  461. local theta = ACOS(-cosTheta)
  462. local invSinTheta = 1 / SIN(theta)
  463. startInterp = SIN((t - 1) * theta) * invSinTheta
  464. finishInterp = SIN(t * theta) * invSinTheta
  465. else
  466. startInterp = t - 1
  467. finishInterp = t
  468. end
  469. end
  470. 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
  471. end
  472.  
  473. function Clerp(a, b, t)
  474. local qa = {QuaternionFromCFrame(a)}
  475. local qb = {QuaternionFromCFrame(b)}
  476. local ax, ay, az = a.x, a.y, a.z
  477. local bx, by, bz = b.x, b.y, b.z
  478. local _t = 1 - t
  479. return QuaternionToCFrame(_t * ax + t * bx, _t * ay + t * by, _t * az + t * bz, QuaternionSlerp(qa, qb, t))
  480. end
  481.  
  482. function CreateFrame(PARENT, TRANSPARENCY, BORDERSIZEPIXEL, POSITION, SIZE, COLOR, BORDERCOLOR, NAME)
  483. local frame = IT("Frame")
  484. frame.BackgroundTransparency = TRANSPARENCY
  485. frame.BorderSizePixel = BORDERSIZEPIXEL
  486. frame.Position = POSITION
  487. frame.Size = SIZE
  488. frame.BackgroundColor3 = COLOR
  489. frame.BorderColor3 = BORDERCOLOR
  490. frame.Name = NAME
  491. frame.Parent = PARENT
  492. return frame
  493. end
  494.  
  495. function CreateLabel(PARENT, TEXT, TEXTCOLOR, TEXTFONTSIZE, TEXTFONT, TRANSPARENCY, BORDERSIZEPIXEL, STROKETRANSPARENCY, NAME)
  496. local label = IT("TextLabel")
  497. label.BackgroundTransparency = 1
  498. label.Size = UD2(1, 0, 1, 0)
  499. label.Position = UD2(0, 0, 0, 0)
  500. label.TextColor3 = C3(255, 255, 255)
  501. label.TextStrokeTransparency = STROKETRANSPARENCY
  502. label.TextTransparency = TRANSPARENCY
  503. label.FontSize = TEXTFONTSIZE
  504. label.Font = TEXTFONT
  505. label.BorderSizePixel = BORDERSIZEPIXEL
  506. label.TextScaled = true
  507. label.Text = TEXT
  508. label.Name = NAME
  509. label.Parent = PARENT
  510. return label
  511. end
  512.  
  513. function NoOutlines(PART)
  514. PART.TopSurface, PART.BottomSurface, PART.LeftSurface, PART.RightSurface, PART.FrontSurface, PART.BackSurface = 10, 10, 10, 10, 10, 10
  515. end
  516.  
  517.  
  518. function CreateWeldOrSnapOrMotor(TYPE, PARENT, PART0, PART1, C0, C1)
  519. local NEWWELD = IT(TYPE)
  520. NEWWELD.Part0 = PART0
  521. NEWWELD.Part1 = PART1
  522. NEWWELD.C0 = C0
  523. NEWWELD.C1 = C1
  524. NEWWELD.Parent = PARENT
  525. return NEWWELD
  526. end
  527.  
  528. function CreateSound(ID, PARENT, VOLUME, PITCH, DOESLOOP)
  529. local NEWSOUND = nil
  530. coroutine.resume(coroutine.create(function()
  531. NEWSOUND = IT("Sound", PARENT)
  532. NEWSOUND.Volume = VOLUME
  533. NEWSOUND.Pitch = PITCH
  534. NEWSOUND.SoundId = "http://www.roblox.com/asset/?id="..ID
  535. --Swait()
  536. NEWSOUND:play()
  537. if DOESLOOP == false then
  538. repeat Swait() until NEWSOUND.Playing == false
  539. NEWSOUND:remove()
  540. elseif DOESLOOP == true then
  541. NEWSOUND.Looped = true
  542. end
  543. end))
  544. return NEWSOUND
  545. end
  546.  
  547. function CFrameFromTopBack(at, top, back)
  548. local right = top:Cross(back)
  549. 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)
  550. end
  551.  
  552. function CreateWave(inair,size,doesrotate,rotatedirection,waitt,part,offset,color)
  553. local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(color), "Effect", VT(0,0,0))
  554. local mesh = IT("SpecialMesh",wave)
  555. mesh.MeshType = "FileMesh"
  556. wave.Anchored = true
  557. mesh.MeshId = "http://www.roblox.com/asset/?id=20329976"
  558. mesh.Scale = VT(size,size,size)
  559. mesh.Offset = VT(0,0,-size/8)
  560. wave.CFrame = CF(part.p) * CF(0,offset,0) * ANGLES(RAD(inair),RAD(0),RAD(0))
  561. coroutine.resume(coroutine.create(function(PART)
  562. for i = 1, waitt do
  563. Swait()
  564. mesh.Scale = mesh.Scale + VT(size/5,0,size/5)
  565. mesh.Offset = VT(0,0,-(mesh.Scale.X/8))
  566. if doesrotate == true then
  567. wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(0, rotatedirection, 0)
  568. end
  569. wave.Transparency = wave.Transparency + (0.5/waitt)
  570. if wave.Transparency > 0.99 then
  571. wave:remove()
  572. end
  573. end
  574. end))
  575. end
  576.  
  577. function CreateSwirl(inair,size,doesrotate,rotatedirection,waitt,part,offset,color)
  578. local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(color), "Effect", VT(0,0,0))
  579. local mesh = IT("SpecialMesh",wave)
  580. mesh.MeshType = "FileMesh"
  581. wave.Anchored = true
  582. mesh.MeshId = "http://www.roblox.com/asset/?id=1051557"
  583. mesh.Scale = VT(size,size,size)
  584. wave.CFrame = CF(part.Position) * CF(0,offset,0) * ANGLES(RAD(inair),RAD(0),RAD(0))
  585. coroutine.resume(coroutine.create(function(PART)
  586. for i = 1, waitt do
  587. Swait()
  588. mesh.Scale = mesh.Scale + VT(size/5,size/5,size/5)
  589. if doesrotate == true then
  590. wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(0, rotatedirection, 0)
  591. end
  592. wave.Transparency = wave.Transparency + (0.5/waitt)
  593. if wave.Transparency > 0.99 then
  594. wave:remove()
  595. end
  596. end
  597. end))
  598. end
  599.  
  600. function CreateTornado(inair,size,doesrotate,rotatedirection,waitt,part,offset,color)
  601. local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(color), "Effect", VT(0,0,0))
  602. local mesh = IT("SpecialMesh",wave)
  603. mesh.MeshType = "FileMesh"
  604. wave.Anchored = true
  605. mesh.MeshId = "http://www.roblox.com/asset/?id=102638417"
  606. mesh.Scale = VT(size,size,size)
  607. wave.CFrame = CF(part.Position) * CF(0,offset,0) * ANGLES(RAD(inair),RAD(0),RAD(0))
  608. coroutine.resume(coroutine.create(function(PART)
  609. for i = 1, waitt do
  610. Swait()
  611. mesh.Scale = mesh.Scale + VT(size/5,0,size/5)
  612. if doesrotate == true then
  613. wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(0, rotatedirection, 0)
  614. end
  615. wave.Transparency = wave.Transparency + (0.5/waitt)
  616. if wave.Transparency > 0.99 then
  617. wave:remove()
  618. end
  619. end
  620. end))
  621. end
  622.  
  623. function CreateRing(inair,size,doesrotate,rotatedirection,waitt,part,offset,spin1,spin2,color)
  624. local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(color), "Effect", VT(0,0,0))
  625. local mesh = IT("SpecialMesh",wave)
  626. mesh.MeshType = "FileMesh"
  627. mesh.MeshId = "http://www.roblox.com/asset/?id=3270017"
  628. mesh.Scale = VT(size,size,size)
  629. wave.Anchored = true
  630. mesh.Offset = VT(0,0,0)
  631. wave.CFrame = CF(part.Position) * CF(0,offset,0) * ANGLES(RAD(inair),RAD(0),RAD(0))
  632. coroutine.resume(coroutine.create(function(PART)
  633. for i = 1, waitt do
  634. Swait()
  635. mesh.Scale = mesh.Scale + VT(size/5,size/5,size/5)
  636. if doesrotate == true then
  637. wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(spin2, rotatedirection, spin1)
  638. end
  639. wave.Transparency = wave.Transparency + (0.5/waitt)
  640. if wave.Transparency > 0.99 then
  641. wave:remove()
  642. end
  643. end
  644. end))
  645. end
  646.  
  647. function MagicSphere(size,waitt,part,color)
  648. local wave = CreatePart(3, Effects, "Neon", 0, 0, BRICKC(color), "Effect", VT(0,0,0))
  649. local mesh = IT("SpecialMesh",wave)
  650. mesh.MeshType = "Sphere"
  651. wave.Anchored = true
  652. mesh.Scale = VT(size,size,size)
  653. mesh.Offset = VT(0,0,0)
  654. wave.CFrame = part * ANGLES(RAD(0),RAD(0),RAD(0))
  655. coroutine.resume(coroutine.create(function(PART)
  656. for i = 1, waitt do
  657. Swait()
  658. mesh.Scale = mesh.Scale + VT(size/5,size/5,size/5)
  659. wave.Transparency = wave.Transparency + (1/waitt)
  660. if wave.Transparency > 0.99 then
  661. wave:remove()
  662. end
  663. end
  664. end))
  665. end
  666.  
  667. function MagicBlock(size,waitt,part,offset,color)
  668. local wave = CreatePart(3, Effects, "Neon", 0, 0, BRICKC(color), "Effect", VT(size,size,size))
  669. local mesh = IT("BlockMesh",wave)
  670. wave.Anchored = true
  671. wave.CFrame = CF(part.Position) * CF(0,offset,0) * ANGLES(RAD(0),RAD(0),RAD(0))
  672. coroutine.resume(coroutine.create(function(PART)
  673. for i = 1, waitt do
  674. Swait()
  675. mesh.Scale = mesh.Scale + VT(size/5,size/5,size/5)
  676. wave.CFrame = CF(wave.Position) * ANGLES(RAD(math(-360,360)),RAD(math(-360,360)),RAD(math(-360,360)))
  677. wave.Transparency = wave.Transparency + (1/waitt)
  678. if wave.Transparency > 0.99 then
  679. wave:remove()
  680. end
  681. end
  682. end))
  683. end
  684.  
  685. local EyeSizes={
  686. NumberSequenceKeypoint.new(0,0.5,0),
  687. NumberSequenceKeypoint.new(1,0.2,0)
  688. }
  689. local EyeTrans={
  690. NumberSequenceKeypoint.new(0,0,0),
  691. NumberSequenceKeypoint.new(1,1,0)
  692. }
  693. local PE=Instance.new("ParticleEmitter")
  694. PE.LightEmission=0.3
  695. PE.Size=NumberSequence.new(EyeSizes)
  696. PE.Transparency=NumberSequence.new(EyeTrans)
  697. PE.Rotation=NumberRange.new(0,360)
  698. PE.LockedToPart = false
  699. PE.Speed = NumberRange.new(0,0,0)
  700. PE.ZOffset = 0.3
  701. PE.Rate = 999
  702. PE.Name = "Particles"
  703.  
  704. function CreateParticles(art,text,accel,drag,lifetime,type,isenabledbydefault,locked)
  705. local particle = nil
  706. coroutine.resume(coroutine.create(function(PART)
  707. particle = PE:Clone()
  708. Swait()
  709. particle.Rate = 999
  710. particle.Parent = art
  711. particle.Acceleration = accel
  712. if type == "Fire" then
  713. local EyeSizes={
  714. NumberSequenceKeypoint.new(0,0.5,0.3),
  715. NumberSequenceKeypoint.new(1,0.2,0.2)
  716. }
  717. particle.Size = NumberSequence.new(EyeSizes)
  718. elseif type == "Smoke" then
  719. local EyeSizes={
  720. NumberSequenceKeypoint.new(0,0.5,0),
  721. NumberSequenceKeypoint.new(1,5,0.5)
  722. }
  723. particle.Size = NumberSequence.new(EyeSizes)
  724. elseif type == "Solid" then
  725. local EyeSizes={
  726. NumberSequenceKeypoint.new(0,0.5,0),
  727. NumberSequenceKeypoint.new(1,0.5,0)
  728. }
  729. particle.Size = NumberSequence.new(EyeSizes)
  730. end
  731. particle.Lifetime=NumberRange.new(lifetime)
  732. particle.Drag = drag
  733. if locked == true then
  734. particle.LockedToPart = true
  735. end
  736. particle.Texture = "http://www.roblox.com/asset/?id="..text
  737. particle.Enabled = isenabledbydefault
  738. end))
  739. return particle
  740. end
  741.  
  742. local EyeSizes={
  743. NumberSequenceKeypoint.new(0,0.5,0),
  744. NumberSequenceKeypoint.new(1,0.2,0)
  745. }
  746. local EyeTrans={
  747. NumberSequenceKeypoint.new(0,0,0),
  748. NumberSequenceKeypoint.new(1,1,0)
  749. }
  750. local PE2=Instance.new("ParticleEmitter")
  751. PE2.LightEmission=0.8
  752. PE2.Size=NumberSequence.new(EyeSizes)
  753. PE2.Transparency=NumberSequence.new(EyeTrans)
  754. PE2.Rotation=NumberRange.new(0,360)
  755. PE2.LockedToPart = false
  756. PE2.Speed = NumberRange.new(0,0,0)
  757. PE2.ZOffset = 0.3
  758. PE2.Rate = 999
  759. PE2.VelocitySpread = 90000
  760. PE2.Name = "Particles"
  761.  
  762. function CreateParticles2(art,accel,drag,lifetime,type,isenabledbydefault,locked,size,speed)
  763. local particle = nil
  764. coroutine.resume(coroutine.create(function(PART)
  765. particle = PE2:Clone()
  766. Swait()
  767. particle.Rate = 999
  768. particle.Parent = art
  769. particle.Acceleration = accel
  770. if type == "Fire" then
  771. local EyeSizes={
  772. NumberSequenceKeypoint.new(0,size,size/2),
  773. NumberSequenceKeypoint.new(1,size/4,size/8)
  774. }
  775. particle.Size = NumberSequence.new(EyeSizes)
  776. elseif type == "Smoke" then
  777. local EyeSizes={
  778. NumberSequenceKeypoint.new(0,0.5,0),
  779. NumberSequenceKeypoint.new(1,5,0.5)
  780. }
  781. particle.Size = NumberSequence.new(EyeSizes)
  782. elseif type == "Solid" then
  783. local EyeSizes={
  784. NumberSequenceKeypoint.new(0,0.5,0),
  785. NumberSequenceKeypoint.new(1,0.5,0)
  786. }
  787. particle.Size = NumberSequence.new(EyeSizes)
  788. end
  789. particle.Lifetime=NumberRange.new(lifetime)
  790. particle.Drag = drag
  791. if locked == true then
  792. particle.LockedToPart = true
  793. end
  794. particle.Speed = NumberRange.new(speed,speed,speed)
  795. particle.Texture = "http://www.roblox.com/asset/?id="..MAGICPARTICLE
  796. particle.Enabled = isenabledbydefault
  797. --particle.Color = ColorSequence.new(Color3.new(255/255, 176/255, 0))
  798. end))
  799. return particle
  800. end
  801.  
  802. local Decal = IT("Decal")
  803.  
  804. function CreateMagicCircle(size,doesrotate,rotatedirection,waitt,cframe,alwaysfade)
  805. local sinkhole = IT("Part")
  806. sinkhole.Size = VT(size,0,size)
  807. sinkhole.CFrame = cframe
  808. --sinkhole.Orientation = VT(0,0,0)
  809. sinkhole.Parent = Effects
  810. sinkhole.Material = "Neon"
  811. sinkhole.Color = C3(1,0,0)
  812. sinkhole.Anchored = true
  813. sinkhole.CanCollide = false
  814. sinkhole.Transparency = 1
  815. local decal = Decal:Clone()
  816. decal.Parent = sinkhole
  817. decal.Face = "Top"
  818. decal.Texture = "http://www.roblox.com/asset/?id=1216587766"
  819. local decal2 = Decal:Clone()
  820. decal2.Parent = sinkhole
  821. decal2.Face = "Bottom"
  822. decal2.Texture = "http://www.roblox.com/asset/?id=1216588034"
  823. coroutine.resume(coroutine.create(function(PART)
  824. for i = 1, waitt do
  825. Swait()
  826. if doesrotate == true then
  827. sinkhole.CFrame = sinkhole.CFrame * CFrame.fromEulerAnglesXYZ(0, rotatedirection, 0)
  828. end
  829. if alwaysfade == true then
  830. decal.Transparency = decal.Transparency + (1/waitt)
  831. decal2.Transparency = decal.Transparency + (1/waitt)
  832. end
  833. if i > waitt-11 and (alwaysfade ~= true) then
  834. decal.Transparency = decal.Transparency + 0.1
  835. decal2.Transparency = decal.Transparency + 0.1
  836. end
  837. end
  838. sinkhole.Parent = nil
  839. end))
  840. return sinkhole
  841. end
  842.  
  843. --//=================================\\
  844. --\\=================================//
  845.  
  846.  
  847. --//=================================\\
  848. --|| WEAPON CREATION
  849. --\\=================================//
  850.  
  851. if Player_Size ~= 1 then
  852. for _, v in pairs (Weapon:GetChildren()) do
  853. if v.ClassName == "Motor" or v.ClassName == "Weld" or v.ClassName == "Snap" then
  854. local p1 = v.Part1
  855. v.Part1 = nil
  856. local cf1, cf2, cf3, cf4, cf5, cf6, cf7, cf8, cf9, cf10, cf11, cf12 = v.C1:components()
  857. v.C1 = CF(cf1 * Player_Size, cf2 * Player_Size, cf3 * Player_Size, cf4, cf5, cf6, cf7, cf8, cf9, cf10, cf11, cf12)
  858. v.Part1 = p1
  859. elseif v.ClassName == "Part" then
  860. for _, b in pairs (v:GetChildren()) do
  861. if b.ClassName == "SpecialMesh" or b.ClassName == "BlockMesh" then
  862. b.Scale = VT(b.Scale.x * Player_Size, b.Scale.y * Player_Size, b.Scale.z * Player_Size)
  863. end
  864. end
  865. end
  866. end
  867. end
  868.  
  869. Swait()
  870.  
  871. local Plate = IT("Part",Weapon)
  872. Plate.Size = VT(1,0.1,1)
  873. Plate.Transparency = 1
  874. Plate.CanCollide = false
  875. Plate.CFrame = LeftLeg.CFrame * CF(0,-1.1,0)
  876. CreateParticles(Plate,MAGICPARTICLE,VT(0,2,0),2,2,"Fire",true,true)
  877. weldBetween(LeftLeg,Plate)
  878.  
  879. local Plate = IT("Part",Weapon)
  880. Plate.Size = VT(1,0.1,1)
  881. Plate.Transparency = 1
  882. Plate.CanCollide = false
  883. Plate.CFrame = RightLeg.CFrame * CF(0,-1.1,0)
  884. CreateParticles(Plate,MAGICPARTICLE,VT(0,2,0),2,2,"Fire",true,true)
  885. weldBetween(RightLeg,Plate)
  886.  
  887. local Plate = IT("Part",Weapon)
  888. Plate.Size = VT(1,0.1,1)
  889. Plate.Transparency = 1
  890. Plate.CanCollide = false
  891. Plate.CFrame = RightArm.CFrame * CF(0,-1.1,0)
  892. CreateParticles(Plate,MAGICPARTICLE,VT(0,2,0),2,2,"Fire",true,true)
  893. weldBetween(RightArm,Plate)
  894.  
  895. local Plate = IT("Part",Weapon)
  896. Plate.Size = VT(1,0.1,1)
  897. Plate.Transparency = 1
  898. Plate.CanCollide = false
  899. Plate.CFrame = LeftArm.CFrame * CF(0,-1.1,0)
  900. CreateParticles(Plate,MAGICPARTICLE,VT(0,2,0),2,2,"Fire",true,true)
  901. weldBetween(LeftArm,Plate)
  902.  
  903. local eye = IT("Part",Weapon)
  904. eye.Size = VT(0.2,0.2,0.2)
  905. eye.Shape = "Ball"
  906. eye.CFrame = Head.CFrame * CF(0.125,0.2,-0.55)
  907. eye.Material = "Neon"
  908. eye.BrickColor = BRICKC("Royal purple")
  909. weldBetween(Head,eye)
  910.  
  911.  
  912.  
  913. for _, c in pairs(Weapon:GetChildren()) do
  914. if c.ClassName == "Part" then
  915. c.CustomPhysicalProperties = PhysicalProperties.new(0, 0, 0, 0, 0)
  916. end
  917. end
  918.  
  919. Weapon.Parent = Character
  920.  
  921. Humanoid.Died:connect(function()
  922. ATTACK = true
  923. end)
  924.  
  925. print(Class_Name.." loaded.")
  926.  
  927. --//=================================\\
  928. --\\=================================//
  929.  
  930.  
  931.  
  932.  
  933.  
  934. --//=================================\\
  935. --|| DAMAGE FUNCTIONS
  936. --\\=================================//
  937.  
  938. function StatLabel(LABELTYPE, CFRAME, TEXT, COLOR)
  939. local STATPART = CreatePart(3, Effects, "SmoothPlastic", 0, 1, "Really black", "Effect", VT())
  940. STATPART.CFrame = CF(CFRAME.p + VT(0, 1.5, 0))
  941. local BODYGYRO = IT("BodyGyro", STATPART)
  942. local BODYPOSITION = IT("BodyPosition", STATPART)
  943. BODYPOSITION.P = 2000
  944. BODYPOSITION.D = 100
  945. BODYPOSITION.maxForce = VT(math.huge, math.huge, math.huge)
  946. if LABELTYPE == "Normal" then
  947. BODYPOSITION.position = STATPART.Position + VT(MRANDOM(-2, 2), 6, MRANDOM(-2, 2))
  948. elseif LABELTYPE == "Debuff" then
  949. BODYPOSITION.position = STATPART.Position + VT(MRANDOM(-2, 2), 8, MRANDOM(-2, 2))
  950. elseif LABELTYPE == "Interruption" then
  951. BODYPOSITION.position = STATPART.Position + VT(MRANDOM(-2,2), 8, MRANDOM(-2, 2))
  952. end
  953. game:GetService("Debris"):AddItem(STATPART ,5)
  954. local BILLBOARDGUI = Instance.new("BillboardGui", STATPART)
  955. BILLBOARDGUI.Adornee = STATPART
  956. BILLBOARDGUI.Size = UD2(2.5, 0, 2.5 ,0)
  957. BILLBOARDGUI.StudsOffset = VT(-2, 2, 0)
  958. BILLBOARDGUI.AlwaysOnTop = false
  959. local TEXTLABEL = Instance.new("TextLabel", BILLBOARDGUI)
  960. TEXTLABEL.BackgroundTransparency = 1
  961. TEXTLABEL.Size = UD2(2.5, 0, 2.5, 0)
  962. TEXTLABEL.Text = TEXT
  963. TEXTLABEL.Font = "SciFi"
  964. TEXTLABEL.FontSize="Size42"
  965. TEXTLABEL.TextColor3 = COLOR
  966. TEXTLABEL.TextStrokeTransparency = 1
  967. TEXTLABEL.TextScaled = true
  968. TEXTLABEL.TextWrapped = true
  969. coroutine.resume(coroutine.create(function(THEPART, THEBODYPOSITION, THETEXTLABEL)
  970. wait(0.2)
  971. for i=1, 5 do
  972. wait()
  973. THEBODYPOSITION.Position = THEPART.Position - VT(0, 0.5 ,0)
  974. end
  975. wait(1.2)
  976. for i=1, 5 do
  977. wait()
  978. THETEXTLABEL.TextTransparency = THETEXTLABEL.TextTransparency + 0.2
  979. THETEXTLABEL.TextStrokeTransparency = THETEXTLABEL.TextStrokeTransparency + 0.2
  980. THEBODYPOSITION.position = THEPART.Position + VT(0, 0.5, 0)
  981. end
  982. THEPART.Parent = nil
  983. end),STATPART, BODYPOSITION, TEXTLABEL)
  984. end
  985.  
  986.  
  987. --//=================================\\
  988. --|| DAMAGING
  989. --\\=================================//
  990.  
  991. function dealdamage(hit,min,max,maxstrength,beserk,critrate,critmultiplier)
  992. if hit.Parent:FindFirstChildOfClass("Humanoid") and hit.Parent:FindFirstChild("HitBy"..Player.Name) == nil then
  993. local humanoid = hit.Parent:FindFirstChildOfClass("Humanoid")
  994. local dmg = math.random(min,max)
  995. if humanoid.Health > 0 then
  996. if beserk == true then
  997. humanoid.Health = 0
  998. else
  999. CreateSound("260430060", hit, 1.2, MRANDOM(7, 12) / 10)
  1000. hit.Velocity = CFrame.new(Torso.Position,hit.Position).lookVector*5*maxstrength
  1001. if math.random(1,100) < critrate+1 then
  1002. humanoid.Health = humanoid.Health - dmg*critmultiplier
  1003. StatLabel("Normal", hit.CFrame * CF(0, 0 + (hit.Size.z - 1), 0), "CRIT/"..dmg*critmultiplier, C3(255/255, 0, 0))
  1004. else
  1005. humanoid.Health = humanoid.Health - dmg
  1006. StatLabel("Normal", hit.CFrame * CF(0, 0 + (hit.Size.z - 1), 0), dmg, C3(0, 0, 0))
  1007. end
  1008. local defence = Instance.new("BoolValue",hit.Parent)
  1009. defence.Name = ("HitBy"..Player.Name)
  1010. game:GetService("Debris"):AddItem(defence, 0.5)
  1011. end
  1012. end
  1013. end
  1014. end
  1015.  
  1016. function AoEDamage(position,radius,min,max,maxstrength,beserk,critrate,critmultiplier,CanBeDodgedByJumping)
  1017. local dmg = math.random(min,max)
  1018. for i,v in ipairs(workspace:GetChildren()) do
  1019. if v:FindFirstChild("HitBy"..Player.Name) == nil then
  1020. local body = v:GetChildren()
  1021. for part = 1, #body do
  1022. if(v:FindFirstChild("HitBy"..Player.Name) == nil and (body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character) then
  1023. if(body[part].Position - position).Magnitude < radius then
  1024. if v.ClassName == "Model" then
  1025. if v:FindFirstChild("Humanoid") then
  1026. if v.Humanoid.Health ~= 0 then
  1027. if CanBeDodgedByJumping == true then
  1028. if body[part].Position.Y < position.Y+5 then
  1029. if math.random(1,100) < critrate+1 then
  1030. v.Humanoid.Health = v.Humanoid.Health - dmg*critmultiplier
  1031. StatLabel("Normal", body[part].CFrame * CF(0, 0 + (body[part].Size.z - 1), 0), "CRIT/"..dmg*critmultiplier, C3(255/255, 0, 0))
  1032. else
  1033. v.Humanoid.Health = v.Humanoid.Health - dmg
  1034. StatLabel("Normal", body[part].CFrame * CF(0, 0 + (body[part].Size.z - 1), 0), dmg, C3(0, 0, 0))
  1035. end
  1036. local defence = Instance.new("BoolValue",v)
  1037. defence.Name = ("HitBy"..Player.Name)
  1038. game:GetService("Debris"):AddItem(defence, 0.5)
  1039. end
  1040. else
  1041. if beserk == true then
  1042. v.Humanoid.Health = 0
  1043. end
  1044. if math.random(1,100) < critrate+1 then
  1045. v.Humanoid.Health = v.Humanoid.Health - dmg*critmultiplier
  1046. StatLabel("Normal", body[part].CFrame * CF(0, 0 + (body[part].Size.z - 1), 0), "CRIT/"..dmg*critmultiplier, C3(255/255, 0, 0))
  1047. else
  1048. v.Humanoid.Health = v.Humanoid.Health - dmg
  1049. StatLabel("Normal", body[part].CFrame * CF(0, 0 + (body[part].Size.z - 1), 0), dmg, C3(0, 0, 0))
  1050. end
  1051. local defence = Instance.new("BoolValue",v)
  1052. defence.Name = ("HitBy"..Player.Name)
  1053. game:GetService("Debris"):AddItem(defence, 0.5)
  1054. end
  1055. end
  1056. end
  1057. end
  1058. body[part].Velocity = CFrame.new(position,body[part].Position).lookVector*5*maxstrength
  1059. end
  1060. end
  1061. end
  1062. if v.ClassName == "Part" then
  1063. if v.Anchored == false and (v.Position - position).Magnitude < radius then
  1064. v.Velocity = CFrame.new(position,v.Position).lookVector*5*maxstrength
  1065. end
  1066. end
  1067. end
  1068. end
  1069. end
  1070.  
  1071. function attractnearest(postype,position,range,maxstrength,last)
  1072. if postype == "Vector" then
  1073. for i,v in ipairs(workspace:GetChildren()) do
  1074. local body = v:GetChildren()
  1075. for part = 1, #body do
  1076. if((body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character) then
  1077. if(body[part].Position - position).Magnitude < range then
  1078. if body[part]:FindFirstChild("ATTRACT") == nil then
  1079. local bv = Instance.new("BodyVelocity")
  1080. bv.maxForce = Vector3.new(1e9, 1e9, 1e9)
  1081. bv.velocity = CF(body[part].Position,position).lookVector*maxstrength
  1082. bv.Parent = body[part]
  1083. bv.Name = "ATTRACT"
  1084. else
  1085. coroutine.resume(coroutine.create(function()
  1086. for i = 1, last/5 do
  1087. Swait(5)
  1088. body[part].ATTRACT.velocity = CF(body[part].Position,position).lookVector*maxstrength
  1089. end
  1090. body[part].ATTRACT:remove()
  1091. end))
  1092. end
  1093. end
  1094. end
  1095. end
  1096. if v.ClassName == "Part" then
  1097. if v.Anchored == false and (v.Position - position).Magnitude < range then
  1098. if v:FindFirstChild("ATTRACT") == nil then
  1099. local bv = Instance.new("BodyVelocity")
  1100. bv.maxForce = Vector3.new(1e9, 1e9, 1e9)
  1101. bv.velocity = CF(v.Position,position).lookVector*maxstrength
  1102. bv.Parent = v
  1103. bv.Name = "ATTRACT"
  1104. else
  1105. coroutine.resume(coroutine.create(function()
  1106. for i = 1, last/5 do
  1107. Swait(5)
  1108. v.ATTRACT.velocity = CF(v.Position,position).lookVector*maxstrength
  1109. end
  1110. v.ATTRACT:remove()
  1111. end))
  1112. end
  1113. end
  1114. end
  1115. end
  1116. elseif postype == "Part" then
  1117. for i,v in ipairs(workspace:GetChildren()) do
  1118. local body = v:GetChildren()
  1119. for part = 1, #body do
  1120. if((body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character) then
  1121. if(body[part].Position - position.Position).Magnitude < range then
  1122. if body[part]:FindFirstChild("ATTRACT") == nil then
  1123. local bv = Instance.new("BodyVelocity")
  1124. bv.maxForce = Vector3.new(1e9, 1e9, 1e9)
  1125. bv.velocity = CF(body[part].Position,position.Position).lookVector*maxstrength
  1126. bv.Parent = body[part]
  1127. bv.Name = "ATTRACT"
  1128. else
  1129. coroutine.resume(coroutine.create(function()
  1130. for i = 1, last/5 do
  1131. Swait(5)
  1132. body[part].ATTRACT.velocity = CF(body[part].Position,position.Position).lookVector*maxstrength
  1133. end
  1134. body[part].ATTRACT:remove()
  1135. end))
  1136. end
  1137. end
  1138. end
  1139. end
  1140. if v.ClassName == "Part" then
  1141. if v.Anchored == false and (v.Position - position.Position).Magnitude < range then
  1142. if v:FindFirstChild("ATTRACT") == nil then
  1143. local bv = Instance.new("BodyVelocity")
  1144. bv.maxForce = Vector3.new(1e9, 1e9, 1e9)
  1145. bv.velocity = CF(v.Position,position.Position).lookVector*maxstrength
  1146. bv.Parent = v
  1147. bv.Name = "ATTRACT"
  1148. else
  1149. coroutine.resume(coroutine.create(function()
  1150. for i = 1, last/5 do
  1151. Swait(5)
  1152. v.ATTRACT.velocity = CF(v.Position,position.Position).lookVector*maxstrength
  1153. end
  1154. v.ATTRACT:remove()
  1155. end))
  1156. end
  1157. end
  1158. end
  1159. end
  1160. end
  1161. end
  1162.  
  1163. function killnearest(position,range,maxstrength,candestroy)
  1164. for i,v in ipairs(workspace:GetChildren()) do
  1165. local body = v:GetChildren()
  1166. for part = 1, #body do
  1167. if((body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character) then
  1168. if(body[part].Position - position).Magnitude < range then
  1169. if v.ClassName == "Model" then
  1170. v:BreakJoints()
  1171. end
  1172. if candestroy == true then
  1173. table.insert(Effects2,{body[part],"Disappear",0.02,2,2,2,2})
  1174. end
  1175. body[part].Velocity = CFrame.new(position,body[part].Position).lookVector*5*maxstrength
  1176. end
  1177. end
  1178. end
  1179. if v.ClassName == "Part" then
  1180. if v.Anchored == false and (v.Position - position).Magnitude < range then
  1181. if candestroy == true then
  1182. table.insert(Effects2,{v,"Disappear",0.02,2,2,2,2})
  1183. end
  1184. v.Velocity = CFrame.new(position,v.Position).lookVector*5*maxstrength
  1185. end
  1186. end
  1187. end
  1188. end
  1189.  
  1190. --//=================================\\
  1191. --|| ATTACK FUNCTIONS AND STUFF
  1192. --\\=================================//
  1193.  
  1194. function CheckTableForString(Table, String)
  1195. for i, v in pairs(Table) do
  1196. if string.find(string.lower(String), string.lower(v)) then
  1197. return true
  1198. end
  1199. end
  1200. return false
  1201. end
  1202.  
  1203. function CheckIntangible(Hit)
  1204. local ProjectileNames = {"Water", "Arrow", "Projectile", "Effect", "Rail", "Lightning", "Bullet"}
  1205. if Hit and Hit.Parent then
  1206. if ((not Hit.CanCollide or CheckTableForString(ProjectileNames, Hit.Name)) and not Hit.Parent:FindFirstChild("Humanoid")) then
  1207. return true
  1208. end
  1209. end
  1210. return false
  1211. end
  1212.  
  1213. Debris = game:GetService("Debris")
  1214.  
  1215. function CastZapRay(StartPos, Vec, Length, Ignore, DelayIfHit)
  1216. local Direction = CFrame.new(StartPos, Vec).lookVector
  1217. local Ignore = ((type(Ignore) == "table" and Ignore) or {Ignore})
  1218. local RayHit, RayPos, RayNormal = game:GetService("Workspace"):FindPartOnRayWithIgnoreList(Ray.new(StartPos, Direction * Length), Ignore)
  1219. if RayHit and CheckIntangible(RayHit) then
  1220. if DelayIfHit then
  1221. wait()
  1222. end
  1223. RayHit, RayPos, RayNormal = CastZapRay((RayPos + (Vec * 0.01)), Vec, (Length - ((StartPos - RayPos).magnitude)), Ignore, DelayIfHit)
  1224. end
  1225. return RayHit, RayPos, RayNormal
  1226. end
  1227.  
  1228. function turnto(pos)
  1229. RootPart.CFrame = CF(RootPart.Position,VT(pos.X,RootPart.Position.Y,pos.Z))
  1230. end
  1231.  
  1232. function GraviBomb()
  1233. ATTACK = true
  1234. for i=0, 1, 0.1 / Animation_Speed do
  1235. Swait()
  1236. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0 * Player_Size, 0 * Player_Size, 0.7 * Player_Size) * ANGLES(RAD(5), RAD(0), RAD(-40)), 0.4 / Animation_Speed)
  1237. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * ANGLES(RAD(0), RAD(0), RAD(35)) * ANGLES(RAD(2.5), RAD(0), RAD(0)), 0.4 / Animation_Speed)
  1238. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(70), RAD(0), RAD(45)) * RIGHTSHOULDERC0, 0.4 / Animation_Speed)
  1239. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5 * Player_Size, 0.75 * Player_Size, -0.5 * Player_Size) * ANGLES(RAD(90), RAD(0), RAD(50)) * ANGLES(RAD(80), RAD(-20), RAD(-30)) * LEFTSHOULDERC0, 0.4 / Animation_Speed)
  1240. 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)
  1241. 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)
  1242. end
  1243. MagicSphere(25,25,LeftArm.CFrame*CF(0,-1,0),"Royal purple")
  1244. MagicSphere(20,25,LeftArm.CFrame*CF(0,-1,0),"Really black")
  1245. coroutine.resume(coroutine.create(function()
  1246. local cframe = CF(Mouse.Hit.p)
  1247. local circle = CreateMagicCircle(75,true,0.05,120,cframe,false)
  1248. for i = 1, 5 do
  1249. CreateSound(CUTSOUNDS[MRANDOM(1, #CUTSOUNDS)], Effects, 2, 1)
  1250. local sphere = IT("Part",Effects)
  1251. sphere.Shape = "Ball"
  1252. sphere.Size = VT(50,50,50)
  1253. sphere.Anchored = true
  1254. sphere.CanCollide = false
  1255. sphere.Material = "Neon"
  1256. sphere.BrickColor = BRICKC("Royal purple")
  1257. sphere.Transparency = 0
  1258. sphere.CFrame = cframe
  1259. for i = 1, 10 do
  1260. Swait(2)
  1261. attractnearest("Vector",cframe.p,75,50,10)
  1262. sphere.CFrame = cframe
  1263. sphere.Size = sphere.Size - VT(5,5,5)
  1264. sphere.CFrame = cframe
  1265. end
  1266. sphere:remove()
  1267. end
  1268. local scale = 5
  1269. coroutine.resume(coroutine.create(function()
  1270. CreateSound(RELEASESOUND, Effects, 2, 1)
  1271. MagicSphere(100,125,cframe,"Royal purple")
  1272. MagicSphere(75,125,cframe,"Really black")
  1273. CreateSwirl(180,6,true,0.3,225,circle,0,"Really black")
  1274. CreateSwirl(180,4,true,0.3,225,circle,0,"Really black")
  1275. CreateSwirl(180,2,true,0.3,225,circle,0,"Really black")
  1276. for i = 1, 15 do
  1277. Swait()
  1278. killnearest(cframe.p,25,150)
  1279. end
  1280. end))
  1281. end))
  1282. for i=0, 1, 0.1 / Animation_Speed do
  1283. Swait()
  1284. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0 * Player_Size, 0 * Player_Size, 0.7 * Player_Size) * ANGLES(RAD(5), RAD(0), RAD(-30)), 0.4 / Animation_Speed)
  1285. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement