Advertisement
4rblxscripts

Untitled

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