jericoalejo

wizzarad

Jul 5th, 2016
98
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 49.12 KB | None | 0 0
  1. Player = game:GetService("Players").LocalPlayer ---No name needed--
  2. local unlocks = Instance.new("StringValue")
  3. unlocks.Name = "Unlocks"
  4. unlocks.Parent = Player
  5. Character = Player.Character
  6. PlayerGui = Player.PlayerGui
  7. Backpack = Player.Backpack
  8. Torso = Character.Torso
  9. Head = Character.Head
  10. LeftArm = Character["Left Arm"]
  11. LeftLeg = Character["Left Leg"]
  12. RightArm = Character["Right Arm"]
  13. RightLeg = Character["Right Leg"]
  14. LS = Torso["Left Shoulder"]
  15. LH = Torso["Left Hip"]
  16. RS = Torso["Right Shoulder"]
  17. RH = Torso["Right Hip"]
  18. ModelName = "Weapon"
  19. attack = false
  20. attacktype = 1
  21. Hitdeb = 0
  22. Neck = Torso.Neck
  23. local neckcf0 = Neck.C0
  24.  
  25. ----------------------------
  26. --Customize
  27. if (string.match(Player.Unlocks.Value,"Dalahara Mana+") ~= nil) then
  28. Mana = 250
  29. MaxMana = 250
  30. else
  31. Mana = 150
  32. MaxMana = 150
  33. end
  34. mindamage = 5
  35. maxdamage = 30
  36. crtmaxdamage = 40
  37. omindamage = mindamage
  38. omaxdamage = maxdamage
  39. ocrtmaxdamage = crtmaxdamage
  40. crtrate = 100/5
  41. --100%/critpercentage
  42.  
  43.  
  44. oblkbrkr = 0
  45. blockbreaker = oblkbrkr
  46.  
  47. if (string.match(Player.Unlocks.Value,"Dalahara ManaCharge +") ~= nil) then
  48. manaregen = 2
  49. else
  50. manaregen = 1
  51. end
  52. if (string.match(Player.Unlocks.Value,"Dalahara Heal+") ~= nil) then
  53. HealPower = 5
  54. else
  55. HealPower = 3
  56. end
  57. handlecolor = BrickColor.new("White")
  58. bcolor = BrickColor.new("Bright blue")
  59. gemcolor = BrickColor.new("Mid gray")
  60.  
  61. ToolName = "Dalahara"
  62.  
  63. ---------------------------------------------------------------------------------------------------------------------------------------
  64. if Character:findFirstChild("EquippedVal",true) ~= nil then
  65. Character:findFirstChild("EquippedVal",true).Parent = nil
  66. end
  67. ev = Instance.new("BoolValue",Character)
  68. ev.Name = "EquippedVal"
  69. ev.Value = false
  70. if Character:findFirstChild("Block",true) ~= nil then
  71. Character:findFirstChild("Block",true).Parent = nil
  72. end
  73.  
  74.  
  75. --player
  76. player = nil
  77. --welds
  78. RW, LW , RWL, LWL = Instance.new("Weld"), Instance.new("Weld"), Instance.new("Weld"), Instance.new("Weld")
  79. --what anim
  80. anim = "none"
  81. --other var
  82. player = Player
  83. ch = Character
  84. --save shoulders
  85. AoETrue = {}
  86. RSH, LSH , RHL, LHL = ch.Torso["Right Shoulder"], ch.Torso["Left Shoulder"] , ch.Torso["Right Hip"] , ch.Torso["Left Hip"]
  87.  
  88.  
  89. function RWFunc()
  90. RW.Part1 = ch["Right Arm"]
  91. RSH.Part1 = nil
  92. end
  93. function LWFunc()
  94. LW.Part1 = ch["Left Arm"]
  95. LSH.Part1 = nil
  96. end
  97. function RWLFunc()
  98. RWL.Part1 = ch["Right Leg"]
  99. RHL.Part1 = nil
  100. ch["Right Leg"].Name = "RightLeg"
  101. RightLeg.CanCollide = false
  102. end
  103.  
  104. function LWLFunc()
  105. LWL.Part1 = ch["Left Leg"]
  106. LHL.Part1 = nil
  107. ch["Left Leg"].Name = "LeftLeg"
  108. LeftLeg.CanCollide = true
  109. end
  110.  
  111. function RWLRem()
  112. RightLeg.Name = "Right Leg"
  113. RWL.Part1 = nil
  114. RHL.Part1 = ch["Right Leg"]
  115. RightLeg.CanCollide = false
  116. end
  117. function LWLRem()
  118. LeftLeg.Name = "Left Leg"
  119. LWL.Part1 = nil
  120. LHL.Part1 = ch["Left Leg"]
  121. LeftLeg.CanCollide = false
  122. end
  123. function RWRem()
  124. RW.Part1 = nil
  125. RSH.Part1 = ch["Right Arm"]
  126. end
  127. function LWRem()
  128. LW.Part1 = nil
  129. LSH.Part1 = ch["Left Arm"]
  130. end
  131.  
  132.  
  133.  
  134.  
  135. if Character:findFirstChild(ModelName,true) ~= nil then
  136. Character:findFirstChild(ModelName,true).Parent = nil
  137. RHL.Part1 = ch["Right Leg"]
  138. LHL.Part1 = ch["Left Leg"]
  139. RSH.Part1 = ch["Right Arm"]
  140. LSH.Part1 = ch["Left Arm"]
  141. end
  142.  
  143.  
  144.  
  145.  
  146.  
  147.  
  148. local swordholder = Instance.new("Model")
  149. swordholder.Name = ModelName
  150. swordholder.Parent = Character
  151.  
  152. --derp
  153. RW.Part0 = ch.Torso
  154. RW.C0 = CFrame.new(1.5, 0.5, 0) * CFrame.fromEulerAnglesXYZ(0, 0, 0)
  155. RW.C1 = CFrame.new(0, 0.5, 0) * CFrame.fromEulerAnglesXYZ(0, 0, 0)
  156. RW.Parent = swordholder
  157. --
  158. LW.Part0 = ch.Torso
  159. LW.C0 = CFrame.new(-1.5, 0.5, 0) --* CFrame.fromEulerAnglesXYZ(1.7, 0, 0.8)
  160. LW.C1 = CFrame.new(0, 0.5, 0)
  161. LW.Parent = swordholder
  162. --
  163. RWL.Part0 = ch.Torso
  164. RWL.C0 = CFrame.new(1, -1, 0) * CFrame.Angles(0, 0, 0)
  165. RWL.C1 = CFrame.new(0.5, 1, 0)
  166. RWL.Parent = swordholder
  167. --
  168. LWL.Part0 = ch.Torso
  169. LWL.C0 = CFrame.new(-1, -1, 0) * CFrame.Angles(0, 0, 0)
  170. LWL.C1 = CFrame.new(-0.5, 1, 0)
  171. LWL.Parent = swordholder
  172.  
  173.  
  174.  
  175.  
  176. local msh1 = Instance.new("CylinderMesh")
  177. msh1.Scale = Vector3.new(1,1,1)
  178. local msh2 = Instance.new("CylinderMesh")
  179. msh2.Scale = Vector3.new(1,1,1)
  180. local msh3 = Instance.new("SpecialMesh")
  181. msh3.Scale = Vector3.new(1,1,1)
  182. msh3.MeshId = "http://www.roblox.com/asset/?id=3270017"
  183. local msh5 = Instance.new("SpecialMesh")
  184. msh5.Scale = Vector3.new(0.5,5,0.5)
  185. msh5.MeshId = "http://www.roblox.com/asset/?id=1051557"
  186.  
  187. local prt1 = Instance.new("Part")
  188. prt1.formFactor = 3
  189. prt1.CanCollide = false
  190. prt1.Name = "Handle"
  191. prt1.Locked = true
  192. prt1.Size = Vector3.new(0.3,5,0.3)
  193. prt1.Parent = swordholder
  194. msh1.Parent = prt1
  195. prt1.BrickColor = handlecolor
  196. local prt2 = Instance.new("Part")
  197. prt2.formFactor = 3
  198. prt2.CanCollide = false
  199. prt2.Name = "Handle2"
  200. prt2.Locked = true
  201. prt2.Size = Vector3.new(0.5,0.2,0.5)
  202. prt2.Parent = swordholder
  203. msh2.Parent = prt2
  204. prt2.BrickColor = handlecolor
  205. local prt3 = Instance.new("Part")
  206. prt3.formFactor = 3
  207. prt3.CanCollide = false
  208. prt3.Name = "Ring1"
  209. prt3.Locked = true
  210. prt3.Size = Vector3.new(0.2,0.2,0.2)
  211. prt3.Parent = swordholder
  212. msh3.Parent = prt3
  213. prt3.BrickColor = bcolor
  214. local prt5 = Instance.new("Part")
  215. prt5.formFactor = 3
  216. prt5.CanCollide = false
  217. prt5.Name = "Wrap"
  218. prt5.Locked = true
  219. prt5.Size = Vector3.new(0.2,0.2,0.2)
  220. prt5.Parent = swordholder
  221. msh5.Parent = prt5
  222. prt5.BrickColor = bcolor
  223.  
  224. local w1 = Instance.new("Weld")
  225. w1.Parent = prt1
  226. w1.Part0 = prt1
  227. local w2 = Instance.new("Weld")
  228. w2.Parent = prt2
  229. w2.Part0 = prt2
  230. w2.Part1 = prt1
  231. w2.C1 = CFrame.new(0, 0,0) * CFrame.Angles(0, 0, 0)
  232. w2.C0 = CFrame.new(0, 2.5,0) * CFrame.Angles(0, 0, 0)
  233. local w3 = Instance.new("Weld")
  234. w3.Parent = prt3
  235. w3.Part0 = prt3
  236. w3.Part1 = prt1
  237. w3.C1 = CFrame.new(0, 0,0) * CFrame.Angles(0, 0, 0)
  238. w3.C0 = CFrame.new(0, 3.1,0) * CFrame.Angles(0, 0, 0)
  239. local w5 = Instance.new("Weld")
  240. w5.Parent = prt5
  241. w5.Part0 = prt5
  242. w5.Part1 = prt1
  243. w5.C1 = CFrame.new(0, 0,0) * CFrame.Angles(0, 0, 0)
  244. w5.C0 = CFrame.new(0, 0,0) * CFrame.Angles(0, 0, math.rad(0)) * CFrame.new(0,0,0)
  245.  
  246. for i = 0 , 4 do
  247. local msh4 = Instance.new("SpecialMesh")
  248. msh4.Scale = Vector3.new(0.55,0.55,1)
  249. msh4.MeshId = "http://www.roblox.com/asset/?id=3270017"
  250. local prt4 = Instance.new("Part")
  251. prt4.formFactor = 3
  252. prt4.CanCollide = false
  253. prt4.Name = "Ring2"
  254. prt4.Locked = true
  255. prt4.Size = Vector3.new(0.2,0.2,0.2)
  256. prt4.Parent = swordholder
  257. msh4.Parent = prt4
  258. if math.fmod(i,2) == 0 then
  259. prt4.BrickColor = handlecolor
  260. else
  261. prt4.BrickColor = bcolor
  262. end
  263. local w4 = Instance.new("Weld")
  264. w4.Parent = prt4
  265. w4.Part0 = prt4
  266. w4.Part1 = prt3
  267. w4.C1 = CFrame.new(0, 0,0) * CFrame.Angles(0, 0, 0)
  268. w4.C0 = CFrame.new(0.8, 0,0) * CFrame.Angles(0, 0, math.rad((-i*45))) * CFrame.new(0,0,0)
  269. end
  270.  
  271. local RAP = Instance.new("Part")
  272. RAP.formFactor = 0
  273. RAP.CanCollide = false
  274. RAP.Name = "RAPart"
  275. RAP.Locked = true
  276. RAP.Size = Vector3.new(1,1,1)
  277. RAP.Parent = swordholder
  278. RAP.Transparency = 1
  279. local w = Instance.new("Weld")
  280. w.Parent = RAP
  281. w.Part0 = RAP
  282. w.Part1 = RightArm
  283. w.C1 = CFrame.fromEulerAnglesXYZ(0, 0, 0) * CFrame.new(0, 0,0)
  284. w.C0 = CFrame.fromEulerAnglesXYZ(math.rad(0), 0, 0) * CFrame.new(0, 1, 0)
  285.  
  286.  
  287. function unequipweld()
  288. w1.Part1 = Torso
  289. w1.C1 = CFrame.fromEulerAnglesXYZ(0, math.rad(0), math.rad(0)) * CFrame.new(0, 0,0)
  290. w1.C0 = CFrame.fromEulerAnglesXYZ(math.rad(180),math.rad(180), math.rad(0)) * CFrame.new(-1.15, 0.5, -0.6)
  291. end
  292.  
  293. unequipweld()
  294.  
  295.  
  296.  
  297. function equipweld()
  298. w1.Part1 = RAP
  299. w1.C1 = CFrame.fromEulerAnglesXYZ(0, 0, 0) * CFrame.new(0, 0,0)
  300. w1.C0 = CFrame.Angles(math.rad(-90), math.rad(0), math.rad(90)) * CFrame.new(0, 0, 0)
  301. end
  302.  
  303.  
  304. function ss(parent,p) --Slash
  305.  
  306. local SlashSound = Instance.new("Sound")
  307. SlashSound.SoundId = "rbxasset://sounds\\swordslash.wav"
  308. SlashSound.Parent = parent
  309. SlashSound.Volume = .7
  310. SlashSound.Pitch = p
  311. SlashSound.PlayOnRemove = true
  312. coroutine.resume(coroutine.create(function()
  313. wait()
  314. SlashSound.Parent = nil
  315. end))
  316. end
  317. function uss(parent,p) --unsheath
  318.  
  319. local SlashSound = Instance.new("Sound")
  320. SlashSound.SoundId = "rbxasset://sounds\\unsheath.wav"
  321. SlashSound.Parent = parent
  322. SlashSound.Volume = .7
  323. SlashSound.Pitch = p
  324. SlashSound.PlayOnRemove = true
  325. coroutine.resume(coroutine.create(function()
  326. wait()
  327. SlashSound.Parent = nil
  328. end))
  329. end
  330. function cs(parent,p) --Magic Charge
  331.  
  332. local SlashSound = Instance.new("Sound")
  333. SlashSound.SoundId = "http://www.roblox.com/asset/?id=2101137"
  334. SlashSound.Parent = parent
  335. SlashSound.Volume = .7
  336. SlashSound.Pitch = p
  337. SlashSound.PlayOnRemove = true
  338. coroutine.resume(coroutine.create(function()
  339. wait()
  340. SlashSound.Parent = nil
  341. end))
  342. end
  343. function ls(parent,p) --Lazer Sound
  344.  
  345. local SlashSound = Instance.new("Sound")
  346. SlashSound.SoundId = "http://www.roblox.com/asset?id=1369158"
  347. SlashSound.Parent = parent
  348. SlashSound.Volume = .7
  349. SlashSound.Pitch = p
  350. SlashSound.PlayOnRemove = true
  351. coroutine.resume(coroutine.create(function()
  352. wait()
  353. SlashSound.Parent = nil
  354. end))
  355. end
  356. function ts(parent,p)
  357.  
  358. local SlashSound = Instance.new("Sound")
  359. SlashSound.SoundId = "http://www.roblox.com/asset/?id=12222030"
  360. SlashSound.Parent = parent
  361. SlashSound.Volume = .7
  362. SlashSound.Pitch = p
  363. SlashSound.PlayOnRemove = true
  364. coroutine.resume(coroutine.create(function()
  365. wait()
  366. SlashSound.Parent = nil
  367. end))
  368. end
  369. function fs(parent,p) --Fire Sound
  370.  
  371. local SlashSound = Instance.new("Sound")
  372. SlashSound.SoundId = "http://www.roblox.com/asset/?id=31758982"
  373. SlashSound.Parent = parent
  374. SlashSound.Volume = .7
  375. SlashSound.Pitch = p
  376. SlashSound.PlayOnRemove = true
  377. coroutine.resume(coroutine.create(function()
  378. wait()
  379. SlashSound.Parent = nil
  380. end))
  381. end
  382. function ms(parent,p) --Metal Cling Sound
  383.  
  384. local SlashSound = Instance.new("Sound")
  385. SlashSound.SoundId = "rbxasset://sounds\\metal.ogg"
  386. SlashSound.Parent = parent
  387. SlashSound.Volume = 1
  388. SlashSound.Pitch = p
  389. SlashSound.PlayOnRemove = true
  390. coroutine.resume(coroutine.create(function()
  391. wait()
  392. SlashSound.Parent = nil
  393. end))
  394. end
  395. function bs(parent,p) --Berserk Sound
  396.  
  397. local SlashSound = Instance.new("Sound")
  398. SlashSound.SoundId = "http://www.roblox.com/asset/?id=2676305"
  399. SlashSound.Parent = parent
  400. SlashSound.Volume = 1
  401. SlashSound.Pitch = p
  402. SlashSound.PlayOnRemove = true
  403. coroutine.resume(coroutine.create(function()
  404. wait()
  405. SlashSound.Parent = nil
  406. end))
  407. end
  408. function is(parent,p) --Ice Sound
  409.  
  410. local SlashSound = Instance.new("Sound")
  411. SlashSound.SoundId = "rbxasset://sounds\\ice2.ogg"
  412. SlashSound.Parent = parent
  413. SlashSound.Volume = 1
  414. SlashSound.Pitch = p
  415. SlashSound.PlayOnRemove = true
  416. coroutine.resume(coroutine.create(function()
  417. wait()
  418. SlashSound.Parent = nil
  419. end))
  420. end
  421. function hs(parent,p) --Heal Sound
  422.  
  423. local SlashSound = Instance.new("Sound")
  424. SlashSound.SoundId = "http://www.roblox.com/asset/?id=2101144"
  425. SlashSound.Parent = parent
  426. SlashSound.Volume = 1
  427. SlashSound.Pitch = p
  428. SlashSound.PlayOnRemove = true
  429. coroutine.resume(coroutine.create(function()
  430. wait()
  431. SlashSound.Parent = nil
  432. end))
  433. end
  434. --
  435.  
  436. function returndmg()
  437. mindamage = omindamage
  438. maxdamage = omaxdamage
  439. crtmaxdamage = ocrtmaxdamage
  440. end
  441.  
  442. function subdmg(sub)
  443. mindamage = omindamage - sub
  444. maxdamage = omaxdamage - sub
  445. crtmaxdamage = ocrtmaxdamage - sub
  446. end
  447.  
  448. function prcntdmg(sub)
  449. mindamage = math.floor(omindamage - (omindamage*(sub/100)))
  450. maxdamage = math.floor(omaxdamage - (omaxdamage*(sub/100)))
  451. crtmaxdamage = math.floor(ocrtmaxdamage - (ocrtmaxdamage*(sub/100)))
  452. end
  453.  
  454. function tagHumanoid(humanoid, player)
  455. local creator_tag = Instance.new("ObjectValue")
  456. creator_tag.Value = player
  457. creator_tag.Name = "creator"
  458. creator_tag.Parent = humanoid
  459. end
  460.  
  461. function untagHumanoid(humanoid)
  462. if humanoid ~= nil then
  463. local tag = humanoid:findFirstChild("creator")
  464. if tag ~= nil then
  465. tag.Parent = nil
  466. end
  467. end
  468. end
  469.  
  470. local function rayCast(Pos, Dir, Max, Ignore) -- Origin Position , Direction, MaxDistance , IgnoreDescendants
  471. return game.Workspace:FindPartOnRay(Ray.new(Pos, Dir.unit * (Max or 999.999)), Ignore)
  472. end
  473.  
  474.  
  475.  
  476.  
  477. function hideanim()
  478. attack = true
  479. for i = 0 , 1 , 0.1 do
  480. wait()
  481. RW.C0 = CFrame.new(1+0.5*i, 0.5, -0.5+0.5*i) * CFrame.Angles(math.rad(90+135*i),math.rad(0),math.rad(-65+65*i))
  482. RW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  483. LW.C0 = CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(0),math.rad(0),math.rad(-20+20*i))
  484. LW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  485. w1.C0 = CFrame.Angles(math.rad(300), math.rad(180*i), math.rad(0)) * CFrame.new(0, -0.5, -1+2*i)
  486. end
  487. LWRem()
  488. unequipweld()
  489. for i = 0 , 1 , 0.1 do
  490. wait()
  491. RW.C0 = CFrame.new(1.5, 0.5, 0) * CFrame.Angles(math.rad(235-235*i),math.rad(0),math.rad(0))
  492. RW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  493. LW.C0 = CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(0),math.rad(0),math.rad(0))
  494. LW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  495. end
  496. RWRem()
  497. attack = false
  498. end
  499.  
  500.  
  501. function equipanim()
  502. attack = true
  503. RWFunc()
  504. for i = 0 , 1 , 0.2 do
  505. wait()
  506. RW.C0 = CFrame.new(1.5, 0.5, 0) * CFrame.Angles(math.rad(-20*i),math.rad(0),math.rad(0))
  507. RW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  508. LW.C0 = CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(0),math.rad(0),math.rad(0))
  509. LW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  510. end
  511. equipweld()
  512. LWFunc()
  513. w1.C0 = CFrame.Angles(math.rad(-90), math.rad(-110), math.rad(90)) * CFrame.new(0, 0, 0)
  514. for i = 0 , 1 , 0.2 do
  515. wait()
  516. RW.C0 = CFrame.new(1.5-0.5*i, 0.5+0.5*i, -1*i) * CFrame.Angles(math.rad(-20+110*i),math.rad(0),math.rad(-25*i))
  517. RW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  518. LW.C0 = CFrame.new(-1.5+0.5*i, 0.5+0.5*i, -1*i) * CFrame.Angles(math.rad(90*i),math.rad(0),math.rad(25*i))
  519. LW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  520. w1.C0 = CFrame.Angles(math.rad(-90+90*i), math.rad(-110+110*i), math.rad(90-45*i)) * CFrame.new(0, 0, 0)
  521. w1.C1 = CFrame.new(0,0,0)
  522. end
  523. for i = 0 , 1 , 0.1 do
  524. wait()
  525. RW.C0 = CFrame.new(1, 1, -1) * CFrame.Angles(math.rad(90+45*i),math.rad(0),math.rad(-25-20*i))
  526. RW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  527. LW.C0 = CFrame.new(-1, 1, -1) * CFrame.Angles(math.rad(90+45*i),math.rad(0),math.rad(25+20*i))
  528. LW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  529. w1.C0 = CFrame.Angles(math.rad(210*i), math.rad(0), math.rad(45)) * CFrame.new(0, 0, 0)
  530. w1.C1 = CFrame.new(0,0,0)
  531. end
  532. for i = 0 , 1 , 0.1 do
  533. wait()
  534. RW.C0 = CFrame.new(1, 1-0.5*i, -1+0.5*i) * CFrame.Angles(math.rad(135-45*i),math.rad(0),math.rad(-45-20*i))
  535. RW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  536. LW.C0 = CFrame.new(-1-0.5*i, 1-0.5*i, -1+1*i) * CFrame.Angles(math.rad(135-135*i),math.rad(0),math.rad(45-65*i))
  537. LW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  538. w1.C0 = CFrame.Angles(math.rad(210+90*i), math.rad(0), math.rad(45-45*i)) * CFrame.new(0, -0.5*i, -1*i)
  539. w1.C1 = CFrame.new(0,0,0)
  540. end
  541. attack = false
  542. end
  543.  
  544.  
  545. if (script.Parent.className ~= "HopperBin") then
  546. Tool = Instance.new("HopperBin")
  547. Tool.Parent = Backpack
  548. Tool.Name = ToolName
  549. script.Parent = Tool
  550. end
  551. Bin = script.Parent
  552.  
  553. function damagesplat(dmg,hit,crit,blocked)
  554. local mo = Instance.new("Model")
  555. mo.Name = dmg
  556. local pa = Instance.new("Part",mo)
  557. pa.formFactor = 3
  558. pa.Size = Vector3.new(0.8,0.3,0.8)
  559. if crit then
  560. pa.BrickColor = BrickColor.new("Bright yellow")
  561. elseif not crit then
  562. pa.BrickColor = BrickColor.new("Bright red")
  563. end
  564. if blocked then pa.BrickColor = BrickColor.new("Bright blue") end
  565. pa.CFrame = CFrame.new(hit.Position) * CFrame.new(0, 3, 0)
  566. pa.Name = "Head"
  567. local hah = Instance.new("Humanoid")
  568. hah.Parent = mo
  569. hah.MaxHealth = 0
  570. hah.Health = 0
  571. local bp = Instance.new("BodyPosition")
  572. bp.P = 14000
  573. bp.maxForce = Vector3.new(math.huge, math.huge, math.huge)
  574. bp.position = hit.Position + Vector3.new(0, 5, 0)
  575. coroutine.resume(coroutine.create(function()
  576. wait()
  577. mo.Parent = workspace
  578. bp.Parent = pa
  579. wait(1.4)
  580. mo:remove()
  581. end))
  582. end
  583.  
  584. function damage(hum,dmg,critornot)
  585. damagesplat(dmg,hum.Torso,critornot)
  586. hum:TakeDamage(dmg)
  587. coroutine.resume(coroutine.create(function()
  588. tagHumanoid(hum,Player)
  589. wait(1)
  590. untagHumanoid(hum)
  591. end))
  592. end
  593.  
  594. function AddMana(add)
  595. Mana = Mana + add
  596. if Mana > MaxMana then
  597. Mana = MaxMana
  598. end
  599. end
  600.  
  601. function OT(hit) --Normal Damage
  602. if Hitdeb == 1 then return end
  603. if hit.Parent == nil then return end
  604. local hum = hit.Parent:findFirstChild("Humanoid") if hum ~= nil and hum ~= Character.Humanoid then
  605. if hum.Health <= 0 then return end
  606. if hit.Parent:findFirstChild("Block") ~= nil then
  607. if hit.Parent.Block.Value then
  608. damagesplat(0,hum.Torso,false,true)
  609. Hitdeb = 1
  610. if hit.Parent.Block:findFirstChild("BlockPower") ~= nil then
  611. if hit.Parent.Block.BlockPower.Value <= 1 then
  612. hit.Parent.Block.Value = false
  613. elseif hit.Parent.Block.BlockPower.Value > 1 then
  614. local critrandomizer = math.random(crtrate)
  615. if critrandomizer ~= 1 then
  616. hit.Parent.Block.BlockPower.Value = hit.Parent.Block.BlockPower.Value - blockbreaker
  617. elseif critrandomizer == 1 then
  618. hit.Parent.Block.BlockPower.Value = hit.Parent.Block.BlockPower.Value - blockbreaker + 2
  619. end
  620. end
  621. end
  622. return end end
  623. local critrandomizer = math.random(crtrate)
  624. if critrandomizer ~= 1 then
  625. local rndmdamage = math.random(mindamage,maxdamage)
  626. damage(hum,rndmdamage,false)
  627. elseif critrandomizer == 1 then
  628. local rndmdamage = math.random(maxdamage,crtmaxdamage)
  629. damage(hum,rndmdamage,true)
  630. end
  631. Hitdeb = 1
  632. end
  633. end
  634.  
  635. function OT2(hit) --StealHP Damage
  636. if Hitdeb == 1 then return end
  637. if hit.Parent == nil then return end
  638. local hum = hit.Parent:findFirstChild("Humanoid") if hum ~= nil and hum ~= Character.Humanoid then
  639. if hum.Health <= 0 then return end
  640. local vel = Instance.new("BodyVelocity",hum.Torso)
  641. vel.maxForce = Vector3.new(1,1,1) * math.huge
  642. vel.P = vel.P * 2
  643. vel.velocity = Vector3.new(0,2,0) + CFrame.new(Torso.Position,hum.Torso.Position).lookVector * 75
  644. coroutine.resume(coroutine.create(function()
  645. wait(0.1)
  646. vel.Parent=nil
  647. end))
  648. if hit.Parent:findFirstChild("Block") ~= nil then
  649. if hit.Parent.Block.Value then
  650. damagesplat(0,hum.Torso,false,true)
  651. Hitdeb = 1
  652. if hit.Parent.Block:findFirstChild("BlockPower") ~= nil then
  653. if hit.Parent.Block.BlockPower.Value <= 1 then
  654. hit.Parent.Block.Value = false
  655. elseif hit.Parent.Block.BlockPower.Value > 1 then
  656. local critrandomizer = math.random(crtrate)
  657. if critrandomizer ~= 1 then
  658. hit.Parent.Block.BlockPower.Value = hit.Parent.Block.BlockPower.Value - blockbreaker
  659. elseif critrandomizer == 1 then
  660. hit.Parent.Block.BlockPower.Value = hit.Parent.Block.BlockPower.Value - blockbreaker + 2
  661. end
  662. end
  663. end
  664. return end end
  665. local critrandomizer = math.random(crtrate)
  666. if critrandomizer ~= 1 then
  667. local rndmdamage = math.random(mindamage,maxdamage)
  668. damage(hum,rndmdamage,false)
  669. Character.Humanoid:TakeDamage(-rndmdamage)
  670. if game.Players:findFirstChild(hit.Parent.Name) ~= nil then
  671. local plyr = game.Players[hit.Parent.Name]
  672. if plyr:findFirstChild("Class") ~= nil then
  673. if plyr.Class.Value == "Magic" then
  674. AddMana(math.floor(rndmdamage/2))
  675. end
  676. end
  677. end
  678. elseif critrandomizer == 1 then
  679. local rndmdamage = math.random(maxdamage,crtmaxdamage)
  680. damage(hum,rndmdamage,true)
  681. Character.Humanoid:TakeDamage(-rndmdamage)
  682. if game.Players:findFirstChild(hit.Parent.Name) ~= nil then
  683. local plyr = game.Players[hit.Parent.Name]
  684. if plyr:findFirstChild("Class") ~= nil then
  685. if plyr.Class.Value == "Magic" then
  686. AddMana(math.floor(rndmdamage/2))
  687. end
  688. end
  689. end
  690. end
  691. Hitdeb = 1
  692. end
  693. end
  694.  
  695. function AoE(p,magnitude)
  696. local c = game.Workspace:GetChildren();
  697. for i = 1, #c do
  698. local hum = c[i]:findFirstChild("Humanoid")
  699. if hum ~= nil and hum.Health ~= 0 then
  700. local head = c[i]:findFirstChild("Head");
  701. if head ~= nil then
  702. local mag = (head.Position - p).magnitude;
  703. if mag <= magnitude and c[i].Name ~= Character.Name then
  704. local foundd = false
  705. for ii = 1 , #AoETrue do
  706. if AoETrue[ii] == c[i].Name then
  707.  
  708. foundd = true
  709. end
  710. end
  711. if foundd then
  712.  
  713. end
  714. --
  715. if not foundd then
  716. local critrandomizer = math.random(crtrate)
  717. if critrandomizer ~= 1 then
  718. local rndmdamage = math.random(mindamage,maxdamage)
  719. damage(hum,rndmdamage,false)
  720. elseif critrandomizer == 1 then
  721. local rndmdamage = math.random(maxdamage,crtmaxdamage)
  722. damage(hum,rndmdamage,true)
  723. end
  724. table.insert(AoETrue,c[i].Name)
  725. end
  726. end
  727. end
  728. end
  729. end
  730. for ii = 1 , #AoETrue do
  731. table.remove(AoETrue,#AoETrue)
  732. end
  733. end
  734.  
  735. --
  736.  
  737.  
  738. --
  739.  
  740. function effect(Color,Ref,LP,P1)
  741. local effectsmsh = Instance.new("BlockMesh")
  742. effectsmsh.Scale = Vector3.new(1,1,1)
  743. effectsmsh.Name = "Mesh"
  744. local effectsg = Instance.new("Part")
  745. effectsg.formFactor = 3
  746. effectsg.CanCollide = false
  747. effectsg.Name = "Eff"
  748. effectsg.Locked = true
  749. effectsg.Anchored = true
  750. effectsg.Size = Vector3.new(0.2,1,0.2)
  751. effectsg.Parent = swordholder
  752. effectsmsh.Parent = effectsg
  753. effectsg.BrickColor = BrickColor.new(Color)
  754. effectsg.Reflectance = Ref
  755. local point1 = P1
  756. local mg = (LP.p - point1.p).magnitude
  757. effectsg.Size = Vector3.new(0.2,mg,0.2)
  758. effectsg.CFrame = CFrame.new((LP.p+point1.p)/2,point1.p) * CFrame.Angles(math.rad(90),0,0)
  759. coroutine.resume(coroutine.create(function()
  760. for i = 0 , 1 , 0.1 do
  761. wait()
  762. effectsg.Transparency = 1*i
  763. effectsmsh.Scale = Vector3.new(1-1*i,1,1-1*i)
  764. end
  765. wait()
  766. effectsg.Parent = nil
  767. end))
  768. end
  769. --
  770.  
  771.  
  772. con = nil
  773.  
  774.  
  775. function dmgcnnct()
  776. if con ~= nil then
  777. con:disconnect()
  778. Hitdeb = 0
  779. end
  780. con = prt1.Touched:connect(OT)
  781. end
  782.  
  783. function dmg2cnnct()
  784. if con ~= nil then
  785. con:disconnect()
  786. Hitdeb = 0
  787. end
  788. con = prt1.Touched:connect(OT2)
  789. end
  790.  
  791. function dmgdc()
  792. if con ~= nil then
  793. con:disconnect()
  794. Hitdeb = 0
  795. end
  796. end
  797.  
  798. function rptddmg(value,des,inc)
  799. coroutine.resume(coroutine.create(function()
  800. repeat
  801. wait(inc)
  802. Hitdeb = 0
  803. until value == des
  804. end))
  805. end
  806.  
  807. function atktype(s,e)
  808. coroutine.resume(coroutine.create(function ()
  809. attacktype = e
  810. wait(0.25)
  811. attacktype = s
  812. end))
  813. end
  814.  
  815. function Slash1()
  816. attack = true
  817. ss(Head,1)
  818. for i = 0 , 1 , 0.1 do
  819. wait()
  820. RW.C0 = CFrame.new(1+0.5*i, 0.5, -0.5+0.5*i) * CFrame.Angles(math.rad(90),math.rad(90*i),math.rad(-65+65*i))
  821. RW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(math.rad(45*i), 0, 0)
  822. LW.C0 = CFrame.new(-1.5+1.5*i, 0.5, -1*i) * CFrame.Angles(math.rad(90*i),math.rad(0),math.rad(-20+90*i))
  823. LW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  824. w1.C0 = CFrame.Angles(math.rad(300-30*i), math.rad(0), math.rad(0)) * CFrame.new(0, -0.5+0.5*i, -1)
  825. end
  826. prcntdmg(50)
  827. dmgcnnct()
  828. LastPoint = prt1.CFrame * CFrame.new(0,prt1.Size.Y/2,0)
  829. for i = 0 , 1 , 0.4 do
  830. wait()
  831. RW.C0 = CFrame.new(1.5-1*i, 0.5, -1*i) * CFrame.Angles(math.rad(90),math.rad(90),math.rad(0))
  832. RW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(math.rad(45-105*i), 0, 0)
  833. LW.C0 = CFrame.new(-1.25*i, 0.5, -1+1*i) * CFrame.Angles(math.rad(90),math.rad(0),math.rad(70-80*i))
  834. LW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  835. w1.C0 = CFrame.Angles(math.rad(270+30*i), math.rad(0), math.rad(0)) * CFrame.new(0,-0.5*i, -1)
  836. local Point = prt1.CFrame * CFrame.new(0,prt1.Size.Y/2,0)
  837. effect("White",0.5,LastPoint,Point)
  838. LastPoint = Point
  839. end
  840. for i = 0 , 1 , 0.2 do
  841. wait()
  842. RW.C0 = CFrame.new(0.5-0.5*i, 0.5, -1) * CFrame.Angles(math.rad(90),math.rad(90),math.rad(0))
  843. RW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(math.rad(-60-30*i), 0, 0)
  844. LW.C0 = CFrame.new(-1.25, 0.5, 1*i) * CFrame.Angles(math.rad(90),math.rad(0),math.rad(-10-10*i))
  845. LW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  846. w1.C0 = CFrame.Angles(math.rad(300-30*i), math.rad(0), math.rad(0)) * CFrame.new(0,-0.5, -1)
  847. local Point = prt1.CFrame * CFrame.new(0,prt1.Size.Y/2,0)
  848. effect("White",0.5,LastPoint,Point)
  849. LastPoint = Point
  850. end
  851. dmgdc()
  852. returndmg()
  853. for i = 0 , 1 , 0.1 do
  854. wait()
  855. RW.C0 = CFrame.new(1*i, 0.5, -1+0.5) * CFrame.Angles(math.rad(90),math.rad(90-90*i),math.rad(-65*i))
  856. RW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(math.rad(-90+90*i), 0, 0)
  857. LW.C0 = CFrame.new(-1.25-0.25*i, 0.5, 1-1*i) * CFrame.Angles(math.rad(90-90*i),math.rad(0),math.rad(-20))
  858. LW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  859. w1.C0 = CFrame.Angles(math.rad(270+30*i), math.rad(0), math.rad(0)) * CFrame.new(0,-0.5, -1)
  860. end
  861. attack = false
  862. end
  863.  
  864. function Heal(mouse)
  865. local target = nil
  866. local c = game.Workspace:GetChildren();
  867. for i = 1, #c do
  868. local hum = c[i]:findFirstChild("Humanoid")
  869. if hum ~= nil and hum.Health ~= 0 then
  870. local head = c[i]:findFirstChild("Head");
  871. if head ~= nil then
  872. local mag = (head.Position - mouse.Hit.p).magnitude;
  873. if mag <= 10 and c[i].Name ~= Character.Name then
  874. local foundd = false
  875. for ii = 1 , #AoETrue do
  876. if AoETrue[ii] == c[i].Name then
  877. foundd = true
  878. end
  879. end
  880. if foundd then
  881. end
  882. --
  883. if not foundd and target == nil then
  884. if game.Players:findFirstChild(c[i].Name) ~= nil then
  885. local plyr = game.Players[c[i].Name]
  886. if plyr.TeamColor == Player.TeamColor and plyr.Neutral == false then
  887. target = c[i]
  888. elseif plyr.Neutral == true then
  889. target = c[i]
  890. end
  891. elseif game.Players:findFirstChild(c[i].Name) == nil then
  892. target = c[i]
  893. end
  894. end
  895. end
  896. end
  897. end
  898. end
  899. if target == nil then return end
  900. if (Torso.Position-target.Torso.Position).magnitude > 75 then return end
  901. attack = true
  902. for i = 0.1 ,1 , 0.1 do
  903. wait()
  904. RW.C0 = CFrame.new(1, 0.5, -0.5) * CFrame.Angles(math.rad(90+45*i),math.rad(0),math.rad(-65+45*i))
  905. RW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  906. LW.C0 = CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(0),math.rad(0),math.rad(-20-30*i))
  907. LW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  908. end
  909.  
  910. local msh1z = Instance.new("CylinderMesh")
  911. local prt1z = Instance.new("Part")
  912. prt1z.formFactor = 3
  913. prt1z.Name = "HealRay"
  914. prt1z.Locked = true
  915. prt1z.Size = Vector3.new(0.2,0.2,0.2)
  916. prt1z.Parent = swordholder
  917. msh1z.Parent = prt1z
  918. prt1z.BrickColor = BrickColor.new("White")
  919. prt1z.CanCollide = false
  920. prt1z.Anchored = true
  921. local msh2z = Instance.new("CylinderMesh")
  922. local prt2z = Instance.new("Part")
  923. prt2z.formFactor = 3
  924. prt2z.Name = "HealRay"
  925. prt2z.Locked = true
  926. prt2z.Size = Vector3.new(0.2,0.2,0.2)
  927. prt2z.Parent = swordholder
  928. msh2z.Parent = prt2z
  929. prt2z.BrickColor = BrickColor.new("White")
  930. prt2z.CanCollide = false
  931. prt2z.Anchored = true
  932. local msh3z = Instance.new("CylinderMesh")
  933. local prt3z = Instance.new("Part")
  934. prt3z.formFactor = 3
  935. prt3z.Name = "HealRay"
  936. prt3z.Locked = true
  937. prt3z.Size = Vector3.new(0.2,0.2,0.2)
  938. prt3z.Parent = swordholder
  939. msh3z.Parent = prt3z
  940. prt3z.BrickColor = BrickColor.new("White")
  941. prt3z.CanCollide = false
  942. prt3z.Anchored = true
  943. local msh4z = Instance.new("CylinderMesh")
  944. local prt4z = Instance.new("Part")
  945. prt4z.formFactor = 3
  946. prt4z.Name = "HealRay"
  947. prt4z.Locked = true
  948. prt4z.Size = Vector3.new(0.2,0.2,0.2)
  949. prt4z.Parent = swordholder
  950. msh4z.Parent = prt4z
  951. prt4z.BrickColor = BrickColor.new("White")
  952. prt4z.CanCollide = false
  953. prt4z.Anchored = true
  954. hs(Head,1)
  955. repeat
  956. wait(0.15)
  957. local start = prt1.CFrame * CFrame.new(0,-prt1.Size.y/2,0)
  958. local oristrpos1 = Vector3.new(math.random(-2,2),math.random(-2,2),math.random(-2,2)) + (start.p+target.Torso.Position)/2
  959. local oristrpos2 = Vector3.new(math.random(-2,2),math.random(-2,2),math.random(-2,2)) + (oristrpos1+target.Torso.Position)/2
  960. local oristrpos3 = Vector3.new(math.random(-2,2),math.random(-2,2),math.random(-2,2)) + (oristrpos2+target.Torso.Position)/2
  961. local oristrpos4 = target.Torso.Position
  962. local mg1 = (start.p - oristrpos1).magnitude
  963. local mg2 = (oristrpos1 - oristrpos2).magnitude
  964. local mg3 = (oristrpos2- oristrpos3).magnitude
  965. local mg4 = (oristrpos3 - oristrpos4).magnitude
  966. prt1z.Size = Vector3.new(0.5,mg1,0.5)
  967. prt1z.CFrame = CFrame.new((start.p+oristrpos1)/2,oristrpos1) * CFrame.Angles(math.rad(90),0,0)
  968. prt2z.Size = Vector3.new(0.75,mg2,0.75)
  969. prt2z.CFrame = CFrame.new((oristrpos1+oristrpos2)/2,oristrpos2) * CFrame.Angles(math.rad(90),0,0)
  970. prt3z.Size = Vector3.new(1,mg3,1)
  971. prt3z.CFrame = CFrame.new((oristrpos2+oristrpos3)/2,oristrpos3) * CFrame.Angles(math.rad(90),0,0)
  972. prt4z.Size = Vector3.new(1.25,mg4,1.25)
  973. prt4z.CFrame = CFrame.new((oristrpos3+oristrpos4)/2,oristrpos4) * CFrame.Angles(math.rad(90),0,0)
  974. target.Humanoid:TakeDamage(-HealPower)
  975. Mana = Mana - 2
  976. coroutine.resume(coroutine.create(function()
  977. for i = 0.1 , 1 ,0.1 do
  978. wait()
  979. msh1z.Scale = Vector3.new(1-0.75*i,1,1-0.75*i)
  980. msh2z.Scale = Vector3.new(1-0.75*i,1,1-0.75*i)
  981. msh3z.Scale = Vector3.new(1-0.75*i,1,1-0.75*i)
  982. msh4z.Scale = Vector3.new(1-0.75*i,1,1-0.75*i)
  983. prt1z.Transparency = 1*i
  984. prt2z.Transparency = 1*i
  985. prt3z.Transparency = 1*i
  986. prt4z.Transparency = 1*i
  987. end
  988. end))
  989. until not buttonhold or target.Humanoid.Health <= 0 or Mana < 2 or target.Parent == nil or (Torso.Position-target.Torso.Position).magnitude > 75
  990. for i = 0.1 , 1 ,0.1 do
  991. wait()
  992. msh1z.Scale = Vector3.new(0.5-0.5*i,1,0.5-0.5*i)
  993. msh2z.Scale = Vector3.new(0.5-0.5*i,1,0.5-0.5*i)
  994. msh3z.Scale = Vector3.new(0.5-0.5*i,1,0.5-0.5*i)
  995. msh4z.Scale = Vector3.new(0.5-0.5*i,1,0.5-0.5*i)
  996. prt1z.Transparency = 0.5+0.5*i
  997. prt2z.Transparency = 0.5+0.5*i
  998. prt3z.Transparency = 0.5+0.5*i
  999. prt4z.Transparency = 0.5+0.5*i
  1000. end
  1001. prt1z.Parent = nil
  1002. prt2z.Parent = nil
  1003. prt3z.Parent = nil
  1004. prt4z.Parent = nil
  1005. for i = 0.1 ,1 , 0.1 do
  1006. wait()
  1007. RW.C0 = CFrame.new(1, 0.5, -0.5) * CFrame.Angles(math.rad(135-45*i),math.rad(0),math.rad(-20-45*i))
  1008. RW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  1009. LW.C0 = CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(0),math.rad(0),math.rad(-50+30*i))
  1010. LW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  1011. end
  1012. attack = false
  1013. end
  1014.  
  1015.  
  1016. function ManaCharge()
  1017. attack = true
  1018. for i = 0 , 1 , 0.1 do
  1019. wait()
  1020. RW.C0 = CFrame.new(1, 0.5, -0.5) * CFrame.Angles(math.rad(90),math.rad(0),math.rad(-65+20*i))
  1021. RW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(math.rad(-45*i), 0, 0)
  1022. LW.C0 = CFrame.new(-1.5+0.5*i, 0.5, -0.5*i) * CFrame.Angles(math.rad(90*i),math.rad(0),math.rad(-20+65*i))
  1023. LW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(math.rad(-45)*i, 0, 0)
  1024. w1.C0 = CFrame.Angles(math.rad(300-30*i), math.rad(0), math.rad(0)) * CFrame.new(0, -0.5+0.5*i, -1)
  1025. Neck.C0 = neckcf0 * CFrame.Angles(math.rad(-20*i),0,math.rad(-20*i))
  1026. end
  1027. wait(0.1)
  1028. for i = 0 , 1 , 0.2 do
  1029. wait()
  1030. RW.C0 = CFrame.new(1, 0.5, -0.5) * CFrame.Angles(math.rad(90),math.rad(0),math.rad(-45))
  1031. RW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(math.rad(-45+45*i), 0, 0)
  1032. LW.C0 = CFrame.new(-1, 0.5, -0.5) * CFrame.Angles(math.rad(90),math.rad(0),math.rad(45))
  1033. LW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(math.rad(-45+45*i), 0, 0)
  1034. w1.C0 = CFrame.Angles(math.rad(270), math.rad(0), math.rad(0)) * CFrame.new(0, 0, -1)
  1035. Neck.C0 = neckcf0 * CFrame.Angles(math.rad(-20+20*i),0,math.rad(-20+20*i))
  1036. end
  1037. ii = 0
  1038. d = false
  1039. Character.Humanoid.WalkSpeed = 5
  1040. cs(Head,0.5)
  1041. repeat
  1042. wait(0.1)
  1043. ii = ii + 10
  1044. AddMana(manaregen)
  1045. coroutine.resume(coroutine.create(function()
  1046. local meshb1 = Instance.new("SpecialMesh")
  1047. meshb1.Scale = Vector3.new(3,2,3)
  1048. meshb1.MeshId = "http://www.roblox.com/asset/?id=20329976"
  1049. local shellb1 = Instance.new("Part")
  1050. meshb1.Parent = shellb1
  1051. shellb1.Anchored = true
  1052. shellb1.formFactor = 3
  1053. shellb1.Size = Vector3.new(1,1,1)
  1054. shellb1.CFrame = CFrame.new(Torso.Position) * CFrame.new(0,-2,0)* CFrame.Angles(0,math.rad(ii),0)
  1055. shellb1.Parent = swordholder
  1056. shellb1.Transparency = 1
  1057. shellb1.BrickColor = BrickColor.new("Bright blue")
  1058. shellb1.CanCollide = false
  1059. for i = 0 , 1 , 0.05 do
  1060. wait()
  1061. shellb1.Transparency = 1-1*i
  1062. meshb1.Scale = Vector3.new(3+1*i,2-0.5*i,3+1*i)
  1063. end
  1064. for i = 0 , 1 , 0.05 do
  1065. wait()
  1066. shellb1.Transparency = 1*i
  1067. meshb1.Scale = Vector3.new(4+1*i,1.5-1.5*i,4+1*i)
  1068. end
  1069. shellb1.Parent = nil
  1070. end))
  1071. coroutine.resume(coroutine.create(function()
  1072. if not d then
  1073. local meshb = Instance.new("SpecialMesh")
  1074. meshb.Scale = Vector3.new(0,0,0)
  1075. meshb.MeshId = "http://www.roblox.com/Asset/?id=9756362"
  1076. local shellb = Instance.new("Part")
  1077. meshb.Parent = shellb
  1078. shellb.Anchored = true
  1079. shellb.formFactor = 3
  1080. shellb.Size = Vector3.new(1,1,1)
  1081. shellb.CFrame = CFrame.new(Torso.Position) * CFrame.new(math.random(-5,5),math.random(-2,5),math.random(-5,5))
  1082. shellb.Parent = swordholder
  1083. shellb.Reflectance = 0.2
  1084. shellb.Transparency = 1
  1085. if math.random(1,2) == 1 then
  1086. shellb.BrickColor = BrickColor.new("Bright blue")
  1087. else
  1088. shellb.BrickColor = BrickColor.new("Light blue")
  1089. end
  1090. shellb.CanCollide = false
  1091. d = true
  1092. coroutine.resume(coroutine.create(function()
  1093. wait(0.1)
  1094. d = false
  1095. end))
  1096. for i = 0 ,1 , 0.1 do
  1097. wait()
  1098. meshb.Scale = Vector3.new(0.5*i,1*i,0.5*i)
  1099. shellb.Transparency = 1-1*i
  1100. end
  1101. for i = 0 ,1 , 0.1 do
  1102. wait()
  1103. meshb.Scale = Vector3.new(0.5+0.5*i,1+1*i,0.5+0.5*i)
  1104. shellb.Transparency = 1*i
  1105. end
  1106. shellb.Parent = nil
  1107. end
  1108. end))
  1109. until not buttonhold or Mana >= MaxMana
  1110. Character.Humanoid.WalkSpeed = 16
  1111. buttonhold = false
  1112. for i = 0 , 1 , 0.2 do
  1113. wait()
  1114. RW.C0 = CFrame.new(1, 0.5, -0.5) * CFrame.Angles(math.rad(90),math.rad(0),math.rad(-45-20*i))
  1115. RW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(math.rad(0), 0, 0)
  1116. LW.C0 = CFrame.new(-1-0.5*i, 0.5, -0.5+0.5*i) * CFrame.Angles(math.rad(90-90*i),math.rad(0),math.rad(45-65*i))
  1117. LW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(math.rad(0), 0, 0)
  1118. w1.C0 = CFrame.Angles(math.rad(270+30*i), math.rad(0), math.rad(0)) * CFrame.new(0, -0.5*i, -1)
  1119. Neck.C0 = neckcf0
  1120. end
  1121. Neck.C0 = neckcf0
  1122. attack = false
  1123. end
  1124.  
  1125.  
  1126. function ADmg(pos)
  1127. local c = game.Workspace:GetChildren();
  1128. for i = 1, #c do
  1129. local hum = c[i]:findFirstChild("Humanoid")
  1130. if hum ~= nil and hum.Health ~= 0 then
  1131. local head = c[i]:findFirstChild("Torso");
  1132. if head ~= nil then
  1133. local mag = (head.Position - pos).magnitude;
  1134. if mag <= 3 and c[i].Name ~= Character.Name then
  1135. local foundd = false
  1136. for ii = 1 , #AoETrue do
  1137. if AoETrue[ii] == c[i].Name then
  1138. foundd = true
  1139. end
  1140. end
  1141. if foundd then
  1142. end
  1143. --
  1144. if not foundd then
  1145. local critrandomizer = math.random(crtrate)
  1146. if critrandomizer ~= 1 then
  1147. local rndmdamage = math.random(mindamage,maxdamage)
  1148. damage(hum,rndmdamage,false)
  1149. elseif critrandomizer == 1 then
  1150. local rndmdamage = math.random(maxdamage,crtmaxdamage)
  1151. damage(hum,rndmdamage,true)
  1152. end
  1153.  
  1154. table.insert(AoETrue,c[i].Name)
  1155. end
  1156. end
  1157. end
  1158. end
  1159. end
  1160. end
  1161.  
  1162.  
  1163. function shooticeneedle(mouse)
  1164. local p1 = (Torso.CFrame).p
  1165. local spread = 50
  1166. local spreadvector = (Vector3.new(math.random(-spread,spread),math.random(-spread,spread),math.random(-spread,spread)) / 100) * (p1-mouse.Hit.p).magnitude/100
  1167. local dir = CFrame.new((p1+mouse.Hit.p)/2,mouse.Hit.p+spreadvector)
  1168. local hit,pos = rayCast(p1,dir.lookVector,10,Character)
  1169. local rangepos = 100
  1170. local function drawtrail(From,To)
  1171. local effectsmsh = Instance.new("CylinderMesh")
  1172. effectsmsh.Scale = Vector3.new(0,0,0)
  1173. effectsmsh.Name = "Mesh"
  1174. local effectsg = Instance.new("Part")
  1175. effectsg.formFactor = 3
  1176. effectsg.CanCollide = false
  1177. effectsg.Name = "Eff"
  1178. effectsg.Locked = true
  1179. effectsg.Anchored = true
  1180. effectsg.Size = Vector3.new(2,0.2,2)
  1181. effectsg.Parent = swordholder
  1182. effectsmsh.Parent = effectsg
  1183. effectsg.BrickColor = BrickColor.new("Light blue")
  1184. effectsg.Reflectance = 0.25
  1185. local LP = From
  1186. local point1 = To
  1187. local mg = (LP - point1).magnitude
  1188. effectsmsh.Scale = Vector3.new(0,mg*5,0)
  1189. effectsg.CFrame = CFrame.new((LP+point1)/2,point1) * CFrame.Angles(math.rad(90),0,0)
  1190. coroutine.resume(coroutine.create(function()
  1191. for i = 0 , 1 , 0.05 do
  1192. wait()
  1193. effectsg.Transparency = 1*i
  1194. effectsmsh.Scale = Vector3.new(1.5*i,mg*5,1.5*i)
  1195. end
  1196. effectsg.Parent = nil
  1197. end))
  1198. end
  1199. local newpos = p1
  1200. local inc = 10
  1201. is(Head,1)
  1202. repeat
  1203. wait()
  1204. rangepos = rangepos - 10
  1205. dir = dir
  1206. hit,pos = rayCast(newpos,dir.lookVector,inc,Character)
  1207. drawtrail(newpos,pos)
  1208. newpos = newpos + (dir.lookVector * inc)
  1209. if inc >= 20 then
  1210. inc = inc - 10
  1211. end
  1212. if hit ~= nil then
  1213. rangepos = 0
  1214. local effectsmsh = Instance.new("CylinderMesh")
  1215. effectsmsh.Scale = Vector3.new(0.1,1,0.1)
  1216. effectsmsh.Name = "Mesh"
  1217. local effectsg = Instance.new("Part")
  1218. effectsg.formFactor = 3
  1219. effectsg.CanCollide = false
  1220. effectsg.Name = "Eff"
  1221. effectsg.Locked = true
  1222. effectsg.Anchored = true
  1223. effectsg.Size = Vector3.new(1,3,1)
  1224. effectsg.Parent = swordholder
  1225. effectsmsh.Parent = effectsg
  1226. effectsg.BrickColor = BrickColor.new("Light blue")
  1227. effectsg.Reflectance = 0.25
  1228. effectsg.CFrame = (CFrame.new(pos,p1) * CFrame.Angles(math.rad(90),0,0)) + CFrame.new(pos,p1).lookVector*effectsg.Size.y/2
  1229. coroutine.resume(coroutine.create(function()
  1230. wait(10)
  1231. for i = 0.1 , 1 , 0.1 do
  1232. wait()
  1233. effectsg.Transparency = 1*i
  1234. end
  1235. effectsg.Parent = nil
  1236. end))
  1237. end
  1238. until rangepos <= 0
  1239. is(effectsgb,0.5)
  1240. ADmg(pos)
  1241. for ii = 1 , #AoETrue do
  1242. table.remove(AoETrue,#AoETrue)
  1243. end
  1244. end
  1245.  
  1246.  
  1247. function IceNeedles(mouse)
  1248. if Mana < 10 then return else Mana = Mana - 10 end
  1249. attack = true
  1250. for i = 0.1 , 1 , 0.1 do
  1251. wait()
  1252. RW.C0 = CFrame.new(1, 0.5, -0.5) * CFrame.Angles(math.rad(90),math.rad(0),math.rad(-65+20*i))
  1253. RW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  1254. LW.C0 = CFrame.new(-1.5+0.5*i, 0.5, -0.5*i) * CFrame.Angles(math.rad(90*i),math.rad(0),math.rad(-20+65*i))
  1255. LW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  1256. w1.C0 = CFrame.Angles(math.rad(300-30*i), math.rad(0), math.rad(0)) * CFrame.new(0, -0.5+0.5*i, -1)
  1257. Neck.C0 = neckcf0 * CFrame.Angles(math.rad(20*i),0,0)
  1258. end
  1259. coroutine.resume(coroutine.create(function() shooticeneedle(mouse) end))
  1260. for i = 0.2 , 1 , 0.2 do
  1261. wait()
  1262. RW.C0 = CFrame.new(1+0.5*i, 0.5, -0.5+0.5*i) * CFrame.Angles(math.rad(90),math.rad(0),math.rad(-45+90*i))
  1263. RW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  1264. LW.C0 = CFrame.new(-1-0.5*i, 0.5, -0.5+0.5*i) * CFrame.Angles(math.rad(90),math.rad(0),math.rad(45-90*i))
  1265. LW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  1266. w1.C0 = CFrame.Angles(math.rad(270), math.rad(0), math.rad(0)) * CFrame.new(0, -0, -1)
  1267. Neck.C0 = neckcf0 * CFrame.Angles(math.rad(20-40*i),0,0)
  1268. end
  1269. for i = 0.1 , 1 , 0.1 do
  1270. wait()
  1271. RW.C0 = CFrame.new(1.5, 0.5, 0) * CFrame.Angles(math.rad(90),math.rad(0),math.rad(45+20*i))
  1272. RW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  1273. LW.C0 = CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(90),math.rad(0),math.rad(-45-20*i))
  1274. LW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  1275. w1.C0 = CFrame.Angles(math.rad(270), math.rad(0), math.rad(0)) * CFrame.new(0, -0, -1)
  1276. Neck.C0 = neckcf0 * CFrame.Angles(math.rad(-20-5*i),0,0)
  1277. end
  1278. for i = 0.1 , 1 , 0.1 do
  1279. wait()
  1280. RW.C0 = CFrame.new(1.5-0.5*i, 0.5, -0.5*i) * CFrame.Angles(math.rad(90),math.rad(0),math.rad(65-135*i))
  1281. RW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  1282. LW.C0 = CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(90-90*i),math.rad(0),math.rad(-65+45*i))
  1283. LW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  1284. w1.C0 = CFrame.Angles(math.rad(270+30*i), math.rad(0), math.rad(0)) * CFrame.new(0, -0.5*i, -1)
  1285. Neck.C0 = neckcf0 * CFrame.Angles(math.rad(-25+25*i),0,0)
  1286. end
  1287. Neck.C0 = neckcf0
  1288. attack = false
  1289. end
  1290.  
  1291. function Absorb(mouse)
  1292. local target = nil
  1293. local c = game.Workspace:GetChildren();
  1294. for i = 1, #c do
  1295. local hum = c[i]:findFirstChild("Humanoid")
  1296. if hum ~= nil and hum.Health ~= 0 then
  1297. local head = c[i]:findFirstChild("Head");
  1298. if head ~= nil then
  1299. local mag = (head.Position - mouse.Hit.p).magnitude;
  1300. if mag <= 10 and c[i].Name ~= Character.Name then
  1301. local foundd = false
  1302. for ii = 1 , #AoETrue do
  1303. if AoETrue[ii] == c[i].Name then
  1304. foundd = true
  1305. end
  1306. end
  1307. if foundd then
  1308. end
  1309. --
  1310. if not foundd and target == nil then
  1311. if game.Players:findFirstChild(c[i].Name) ~= nil then
  1312. local plyr = game.Players[c[i].Name]
  1313. if plyr.TeamColor ~= Player.TeamColor and plyr.Neutral == false then
  1314. target = c[i]
  1315. elseif plyr.Neutral == true then
  1316. target = c[i]
  1317. end
  1318. elseif game.Players:findFirstChild(c[i].Name) == nil then
  1319. target = c[i]
  1320. end
  1321. end
  1322. end
  1323. end
  1324. end
  1325. end
  1326. if target == nil then return end
  1327. if (Torso.Position-target.Torso.Position).magnitude > 35 or target.Humanoid.Health <= 25 then return end
  1328. attack = true
  1329. for i = 0.1 ,1 , 0.1 do
  1330. wait()
  1331. RW.C0 = CFrame.new(1, 0.5, -0.5) * CFrame.Angles(math.rad(90+45*i),math.rad(0),math.rad(-65+45*i))
  1332. RW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  1333. LW.C0 = CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(0),math.rad(0),math.rad(-20-30*i))
  1334. LW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  1335. end
  1336.  
  1337. local msh1z = Instance.new("CylinderMesh")
  1338. local prt1z = Instance.new("Part")
  1339. prt1z.formFactor = 3
  1340. prt1z.Name = "AbsorbRay"
  1341. prt1z.Locked = true
  1342. prt1z.Size = Vector3.new(0.2,0.2,0.2)
  1343. prt1z.Parent = swordholder
  1344. msh1z.Parent = prt1z
  1345. prt1z.BrickColor = BrickColor.new("Bright violet")
  1346. prt1z.CanCollide = false
  1347. prt1z.Anchored = true
  1348. local msh2z = Instance.new("CylinderMesh")
  1349. local prt2z = Instance.new("Part")
  1350. prt2z.formFactor = 3
  1351. prt2z.Name = "AbsorbRay"
  1352. prt2z.Locked = true
  1353. prt2z.Size = Vector3.new(0.2,0.2,0.2)
  1354. prt2z.Parent = swordholder
  1355. msh2z.Parent = prt2z
  1356. prt2z.BrickColor = BrickColor.new("Bright violet")
  1357. prt2z.CanCollide = false
  1358. prt2z.Anchored = true
  1359. local msh3z = Instance.new("CylinderMesh")
  1360. local prt3z = Instance.new("Part")
  1361. prt3z.formFactor = 3
  1362. prt3z.Name = "AbsorbRay"
  1363. prt3z.Locked = true
  1364. prt3z.Size = Vector3.new(0.2,0.2,0.2)
  1365. prt3z.Parent = swordholder
  1366. msh3z.Parent = prt3z
  1367. prt3z.BrickColor = BrickColor.new("Bright violet")
  1368. prt3z.CanCollide = false
  1369. prt3z.Anchored = true
  1370. local msh4z = Instance.new("CylinderMesh")
  1371. local prt4z = Instance.new("Part")
  1372. prt4z.formFactor = 3
  1373. prt4z.Name = "AbsorbRay"
  1374. prt4z.Locked = true
  1375. prt4z.Size = Vector3.new(0.2,0.2,0.2)
  1376. prt4z.Parent = swordholder
  1377. msh4z.Parent = prt4z
  1378. prt4z.BrickColor = BrickColor.new("Bright violet")
  1379. prt4z.CanCollide = false
  1380. prt4z.Anchored = true
  1381. repeat
  1382. wait(0.35)
  1383. local start = prt1.CFrame * CFrame.new(0,-prt1.Size.y/2,0)
  1384. local oristrpos1 = Vector3.new(math.random(-2,2),math.random(-2,2),math.random(-2,2)) + (start.p+target.Torso.Position)/2
  1385. local oristrpos2 = Vector3.new(math.random(-2,2),math.random(-2,2),math.random(-2,2)) + (oristrpos1+target.Torso.Position)/2
  1386. local oristrpos3 = Vector3.new(math.random(-2,2),math.random(-2,2),math.random(-2,2)) + (oristrpos2+target.Torso.Position)/2
  1387. local oristrpos4 = target.Torso.Position
  1388. local mg1 = (start.p - oristrpos1).magnitude
  1389. local mg2 = (oristrpos1 - oristrpos2).magnitude
  1390. local mg3 = (oristrpos2- oristrpos3).magnitude
  1391. local mg4 = (oristrpos3 - oristrpos4).magnitude
  1392. prt1z.Size = Vector3.new(0.5,mg1,0.5)
  1393. prt1z.CFrame = CFrame.new((start.p+oristrpos1)/2,oristrpos1) * CFrame.Angles(math.rad(90),0,0)
  1394. prt2z.Size = Vector3.new(0.75,mg2,0.75)
  1395. prt2z.CFrame = CFrame.new((oristrpos1+oristrpos2)/2,oristrpos2) * CFrame.Angles(math.rad(90),0,0)
  1396. prt3z.Size = Vector3.new(1,mg3,1)
  1397. prt3z.CFrame = CFrame.new((oristrpos2+oristrpos3)/2,oristrpos3) * CFrame.Angles(math.rad(90),0,0)
  1398. prt4z.Size = Vector3.new(1.25,mg4,1.25)
  1399. prt4z.CFrame = CFrame.new((oristrpos3+oristrpos4)/2,oristrpos4) * CFrame.Angles(math.rad(90),0,0)
  1400. target.Humanoid:TakeDamage(HealPower)
  1401. Character.Humanoid:TakeDamage(-HealPower/2)
  1402. Mana = Mana - 6
  1403. if game.Players:findFirstChild(target.Name) ~= nil then
  1404. local plyr = game.Players[target.Name]
  1405. if plyr:findFirstChild("Class") ~= nil then
  1406. if plyr.Class.Value == "Magic" then
  1407. if math.random(1,2) == 1 then
  1408. AddMana(math.floor(5))
  1409. end
  1410. end
  1411. end
  1412. end
  1413. coroutine.resume(coroutine.create(function()
  1414. for i = 0.1 , 1 ,0.1 do
  1415. wait()
  1416. msh1z.Scale = Vector3.new(1-0.75*i,1,1-0.75*i)
  1417. msh2z.Scale = Vector3.new(1-0.75*i,1,1-0.75*i)
  1418. msh3z.Scale = Vector3.new(1-0.75*i,1,1-0.75*i)
  1419. msh4z.Scale = Vector3.new(1-0.75*i,1,1-0.75*i)
  1420. prt1z.Transparency = 1*i
  1421. prt2z.Transparency = 1*i
  1422. prt3z.Transparency = 1*i
  1423. prt4z.Transparency = 1*i
  1424. end
  1425. end))
  1426. until not buttonhold or target.Humanoid.Health <= 35 or Mana < 3 or target.Parent == nil or (Torso.Position-target.Torso.Position).magnitude > 75
  1427. for i = 0.1 , 1 ,0.1 do
  1428. wait()
  1429. msh1z.Scale = Vector3.new(0.5-0.5*i,1,0.5-0.5*i)
  1430. msh2z.Scale = Vector3.new(0.5-0.5*i,1,0.5-0.5*i)
  1431. msh3z.Scale = Vector3.new(0.5-0.5*i,1,0.5-0.5*i)
  1432. msh4z.Scale = Vector3.new(0.5-0.5*i,1,0.5-0.5*i)
  1433. prt1z.Transparency = 0.5+0.5*i
  1434. prt2z.Transparency = 0.5+0.5*i
  1435. prt3z.Transparency = 0.5+0.5*i
  1436. prt4z.Transparency = 0.5+0.5*i
  1437. end
  1438. prt1z.Parent = nil
  1439. prt2z.Parent = nil
  1440. prt3z.Parent = nil
  1441. prt4z.Parent = nil
  1442. for i = 0.1 ,1 , 0.1 do
  1443. wait()
  1444. RW.C0 = CFrame.new(1, 0.5, -0.5) * CFrame.Angles(math.rad(135-45*i),math.rad(0),math.rad(-20-45*i))
  1445. RW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  1446. LW.C0 = CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(0),math.rad(0),math.rad(-50+30*i))
  1447. LW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  1448. end
  1449. attack = false
  1450. end
  1451.  
  1452. function returnwelds()
  1453. RW.C0 = CFrame.new(1, 0.5, -0.5) * CFrame.Angles(math.rad(90),math.rad(0),math.rad(-65))
  1454. RW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  1455. LW.C0 = CFrame.new(-1.5, 0.5, 0) * CFrame.Angles(math.rad(0),math.rad(0),math.rad(-20))
  1456. LW.C1 = CFrame.new(0, 0.5, 0) * CFrame.Angles(0, 0, 0)
  1457. w1.C0 = CFrame.Angles(math.rad(300), math.rad(0), math.rad(0)) * CFrame.new(0, -0.5, -1)
  1458. RWL.C0 = CFrame.new(1, -1, 0) * CFrame.Angles(0, 0, 0)
  1459. RWL.C1 = CFrame.new(0.5, 1, 0)
  1460. LWL.C0 = CFrame.new(-1, -1, 0) * CFrame.Angles(0, 0, 0)
  1461. LWL.C1 = CFrame.new(-0.5, 1, 0)
  1462. Neck.C0 = neckcf0
  1463. end
  1464.  
  1465.  
  1466.  
  1467. function ob1d(mouse)
  1468. hold = true
  1469. if attack then return end
  1470. Slash1()
  1471. end
  1472.  
  1473. function ob1u(mouse)
  1474. end
  1475.  
  1476. buttonhold = false
  1477.  
  1478. function key(key,mouse)
  1479. if attack then return end
  1480. if key == "q" then
  1481. buttonhold = true
  1482. Heal(mouse)
  1483. end
  1484. if key == "e" then
  1485. IceNeedles(mouse)
  1486. end
  1487. if key == "f" then
  1488. buttonhold = true
  1489. ManaCharge()
  1490. end
  1491. if key == "r" then
  1492. buttonhold = true
  1493. Absorb(mouse)
  1494. end
  1495. end
  1496.  
  1497.  
  1498. function key2(key)
  1499. if key == "f" or key == "q" or key == "r" then
  1500. buttonhold = false
  1501. end
  1502. end
  1503.  
  1504. function s(mouse)
  1505. repeat wait() until not attack
  1506. repeat wait() until not ev.Value
  1507.  
  1508. mouse.Button1Down:connect(function() ob1d(mouse) end)
  1509. mouse.Button1Up:connect(function() ob1u(mouse) end)
  1510. mouse.KeyDown:connect(function(ke) key(ke,mouse) end)
  1511. mouse.KeyUp:connect(key2)
  1512. equipanim()
  1513. ev.Value = true
  1514. end
  1515.  
  1516. function ds(mouse)
  1517. repeat wait() until not attack
  1518. repeat wait() until ev.Value
  1519.  
  1520. hideanim()
  1521. wait(0.1)
  1522. ev.Value = false
  1523. end
  1524.  
  1525. Bin.Selected:connect(s)
  1526. Bin.Deselected:connect(ds)
  1527.  
  1528.  
  1529.  
  1530. if PlayerGui:findFirstChild("ManaMeter") ~= nil then
  1531. PlayerGui:findFirstChild("ManaMeter").Parent = nil
  1532. end
  1533.  
  1534.  
  1535. coroutine.resume(coroutine.create(function()
  1536. local SG = Instance.new("ScreenGui",PlayerGui)
  1537. SG.Name = "ManaMeter"
  1538. local frame = Instance.new("Frame",SG)
  1539. frame.Size = UDim2.new(0.2,0,0.1,0)
  1540. frame.Position = UDim2.new(0.5-0.1,0,0.05,0)
  1541. frame.BackgroundColor3 = BrickColor.new("Bright violet").Color
  1542. local Manatext = Instance.new("TextLabel",frame)
  1543. Manatext.Size = UDim2.new(1,0,0.35,0)
  1544. Manatext.BackgroundTransparency = 1
  1545. Manatext.Text = "Mana"
  1546. Manatext.FontSize = "Size18"
  1547. Manatext.TextColor3 = BrickColor.new("White").Color
  1548. local backing = Instance.new("ImageLabel",frame)
  1549. backing.Size = UDim2.new(0.8,0,0.45,0)
  1550. backing.Image = "http://www.roblox.com/asset/?id=48965808"
  1551. backing.Position = UDim2.new(0.1,0,0.45,0)
  1552. backing.BackgroundColor3 = BrickColor.new("Black").Color
  1553. local img = Instance.new("ImageLabel",backing)
  1554. img.Size = UDim2.new(1,0,1,0)
  1555. img.Image = "http://www.roblox.com/asset/?id=48965808"
  1556. img.Position = UDim2.new(0,0,0,0)
  1557. img.BackgroundColor3 = BrickColor.new("Bright violet").Color
  1558. local percent = Instance.new("TextLabel",backing)
  1559. percent.Size = UDim2.new(1,0,1,0)
  1560. percent.BackgroundTransparency = 1
  1561. percent.TextColor3 = BrickColor.new("White").Color
  1562. percent.Text = math.floor((Mana/MaxMana)*100).."%"
  1563. percent.FontSize = "Size18"
  1564. repeat
  1565. wait()
  1566. pcall(function()
  1567. img.Size = UDim2.new(1*(Mana/MaxMana),0,1,0)
  1568. percent.Text = math.floor((Mana/MaxMana)*100).."%"
  1569. if math.floor((Mana/MaxMana)*100) > 99 then
  1570.  
  1571. end
  1572. end)
  1573. until SG.Parent == nil
  1574. end))
Add Comment
Please, Sign In to add comment