Advertisement
AlphaSploit

Sunset dance

Mar 3rd, 2018
90
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 27.32 KB | None | 0 0
  1. Attacking = false
  2. Health = 500
  3. NorWalkSpeed = 20
  4. RunWalkSpeed = 100
  5. ButtonHold = false
  6. Walking = false
  7. Jumping = false
  8. FastRunning = false
  9. MouseHold = false
  10. ComboN = 0
  11. SwordStandBy = true
  12. Dmg = {
  13. SlashDamage = math.random(10,20);
  14. MagicDmg = math.random(20,50);
  15. };
  16. Player = game.Players.LocalPlayer
  17. Char = Player.Character
  18. Hum = Char.Humanoid
  19. Head = Char.Head
  20. Torso = Char.Torso
  21. Ra = Char["Right Arm"]
  22. La = Char["Left Arm"]
  23. Rl = Char["Right Leg"]
  24. Ll = Char["Left Leg"]
  25. Torso["Right Shoulder"].Part1 = Ra
  26. Torso["Left Shoulder"].Part1 = La
  27. pcall(function()Player.Backpack["Sunset Dance"]:Destroy()end)
  28. Hb = Instance.new("HopperBin",Player.Backpack)Hb.Name = "Sunset Dance"
  29. pcall(function()Char.Mod:Destroy()end)
  30. pcall(function()Char.Sword:Destroy()end)
  31. pcall(function()Torso.Bg:Destroy()end)
  32. BgTor = Instance.new("BodyGyro",Torso)
  33. BgTor.Name = "Bg"
  34. script.Name = "Sword"
  35. local Main = Instance.new("Model",Char)
  36. Main.Name = "Mod"
  37. v3 = Vector3.new; mr = math.rad;
  38. cw = coroutine.wrap; mrd = math.random;
  39. cf = CFrame.new; ud2 = UDim2.new;
  40. ca = CFrame.Angles; v2 = Vector2.new
  41. bc = BrickColor.new; inst = Instance.new
  42. function part(par,size,color,tra,can)
  43. local P = Instance.new("Part",par)
  44. P.FormFactor = "Custom"
  45. P.Size = size
  46. P.Anchored = false
  47. P.BrickColor = BrickColor.new(color)
  48. P.Transparency = tra
  49. P.CanCollide = can
  50. P.TopSurface = 0
  51. P.BottomSurface = 0
  52. P:BreakJoints()
  53. return P
  54. end
  55. function w(par,p0,p1,typ,cfz)
  56. local W = Instance.new("Snap",par)
  57. W.Part0 = p0
  58. W.Part1 = p1
  59. if typ == true then
  60. W.C0 = cfz
  61. else
  62. W.C1 = cfz
  63. end
  64. return W
  65. end
  66. function mesh(par,id,tex,typ,scal)
  67. local M = Instance.new("SpecialMesh",par)
  68. if id then M.MeshId = "http://www.roblox.com/asset/?id="..tostring(id) end
  69. if tex then M.TextureId = "http://www.roblox.com/asset/?id="..tostring(tex) end
  70. M.MeshType = typ
  71. M.Scale = scal
  72. return M
  73. end
  74. function fj(lim,tor,cf1,sd)
  75. sd.Part1 = nil
  76. local w1 = w(Main,tor,lim,true,cf1)
  77. w1.C1 = cf(0,.5,0)
  78. return w1
  79. end
  80. function lerp(a,b,c)return a+(b-a)*c end
  81. function clerp(c1,c2,al) --Smooth Animation!
  82. local com1 = {c1.X,c1.Y,c1.Z,c1:toEulerAnglesXYZ()}local com2 = {c2.X,c2.Y,c2.Z,c2:toEulerAnglesXYZ()}
  83. for i,v in pairs(com1) do com1[i] = lerp(v,com2[i],al)end
  84. return CFrame.new(com1[1],com1[2],com1[3]) * CFrame.Angles(select(4,unpack(com1)))
  85. end
  86. function DamageFunc(hit,Damage,timz)
  87. local hum = hit.Parent:FindFirstChild("Humanoid")
  88. if hum and not hum:FindFirstChild("Dmgz:"..Player.Name) and hit.Parent ~= Char and hit.Parent ~= Workspace and Damage and timz then
  89. hum:TakeDamage(Damage)
  90. local a = Instance.new("StringValue",hum)a.Name = "Dmgz:"..Player.Name
  91. game.Debris:AddItem(a,timz)
  92. local b = Instance.new("ObjectValue",hum)b.Name = "creator" b.Value = Player
  93. game.Debris:AddItem(b,10)
  94. end
  95. end
  96. function makeBall(Color,Size,Number,Intervals)
  97. local Cp = part(Workspace,v3(Size.x,Size.y,Size.z),Color,1,false)
  98. local pl = inst("PointLight",Cp)
  99. pl.Color = BrickColor.new(Color).Color
  100. pl.Brightness = 10
  101. pl.Range = 10
  102. Cp.CFrame = cf(0,10,0)
  103. local Sizez = Size
  104. for i = 0,Number-1 do
  105. local p = part(Workspace,Size,Color,.5,false)
  106. p.Anchored = true
  107. p.CFrame = Cp.CFrame*ca(mr(mrd(-360,360)),mr(mrd(-360,360)),mr(mrd(-360,360)))
  108. --Sizez = Sizez+v3(Intervals,Intervals,Intervals)
  109. game:service'RunService'.Stepped:connect(function()p.CFrame = Cp.CFrame*ca(mr(mrd(-360,360)),mr(mrd(-360,360)),mr(mrd(-360,360))) end)
  110. cw(function()repeat wait() until Cp.Parent == nil or not Cp or not Cp:IsA("Part")
  111. p:Destroy() end)()
  112. end
  113. return Cp
  114. end
  115. --[[Stuff below:]]
  116. Hum.MaxHealth = Health
  117. wait(.2)
  118. Hum.Health = Health
  119. Hum.WalkSpeed = NorWalkSpeed
  120. Slash = Instance.new("Sound",Head)Slash.SoundId = "http://www.roblox.com/asset/?id=10209640" Slash.Volume = 10
  121. local RaW = false
  122. local LaW = false
  123. local NorCfR = cf(1.5,.5,0)
  124. local NorCfL = cf(-1.5,.5,0)
  125. cw(function()
  126. while true do wait()
  127. if not RaW or not LaW then repeat wait() until RaW~=false and LaW~=false end
  128. if Attacking == true then repeat wait() until Attacking == false end
  129. if SwordStandBy == false then repeat wait() until SwordStandBy == true end
  130. local a = math.random(-5,5) local a2 = math.random(-5,5)
  131. local b = math.random(15,25) local b2 = math.random(-25,-15)
  132. for i = 0,50 do wait(.1)
  133. if Attacking == true then break end
  134. if SwordStandBy == false then break end
  135. RaW.C0 = clerp(RaW.C0,NorCfR*ca(mr(a),0,mr(b)),.05)
  136. LaW.C0 = clerp(LaW.C0,NorCfL*ca(mr(a2),0,mr(b2)),.05)
  137. Handle1W.C0 = clerp(Handle1W.C0,cf(0,-1,0)*ca(mr(-90),0,0) ,.1)
  138. Handle2W.C0 = clerp(Handle2W.C0,cf(0,-1,0)*ca(mr(-90),0,0),.1)
  139. end
  140. end
  141. end)()
  142. ----------------Sword 1--------------------------
  143. local Color1 = "Bright orange" local Color2 = "Really black" local BladeC = "Medium stone grey"
  144. Sheath1 = part(Main,v3(.25,3,1),Color1,0,false)w(Sheath1,Torso,Sheath1,true,cf(1+(.25/2),-1.5,1)*ca(mr(-60),0,0))
  145. local p = part(Main,v3(.25,1,1),Color1,0,false)w(p,Sheath1,p,true,cf(0,-1.5+-.5,0)*ca(mr(180),0,0))mesh(p,nil,nil,"Wedge",v3(1,1,1))
  146. -------cf(-1+(.25/-2),-1.5,1)*ca(mr(-60),0,0)
  147. Handle1 = part(Main,v3(0,0,0),"",0,false)Handle1W = w(Handle1,Sheath1,Handle1,true,cf(0,1.5+1+(.25/2),0)*ca(mr(180),0,0)*cf(0,-.25,0))
  148. local a = Color1
  149. for i = -1,1,2/15 do
  150. local p = part(Main,v3(.4,.25,.4),a,0,false)w(p,Handle1,p,true,cf(0,i,0))inst("SpecialMesh",p).MeshType = "Sphere"
  151. if a == Color1 then a = Color2 else a = Color1 end
  152. end
  153. local p = part(Main,v3(.4,.25,1),Color1,0,false)w(p,Handle1,p,true,cf(0,1,0))
  154. local p2 = part(Main,v3(.4,.25,.5),Color1,0,false)w(p2,p,p2,true,cf(0,0,-.5+.05)*ca(mr(-45),0,0)*cf(0,0,-.5/2+.06))
  155. local p2 = part(Main,v3(.4,.25,.5),Color1,0,false)w(p2,p,p2,true,cf(0,0,.5-.05)*ca(mr(-45),0,0)*cf(0,0,.5/2-.06))
  156. local p = part(Main,v3(.1,3,.5),BladeC,0,false)w(p,Handle1,p,true,cf(0,1+1.5,-.15))
  157. local p = part(Main,v3(.1,3,.1),BladeC,0,false)w(p,Handle1,p,true,cf(0,1+1.5,.3))
  158. local p = part(Main,v3(.1,1,.8),BladeC,0,false)w(p,Handle1,p,true,cf(0,1+3+.5,0))mesh(p,nil,nil,"Wedge",v3(1,1,1))
  159. local pl = inst("PointLight",p)pl.Color = BrickColor.new(Color1).Color pl.Brightness = 100 pl.Range = 4
  160. HurtBrick1 = part(Main,v3(.2,4,.9),BladeC,1,false)w(HurtBrick1,Handle1,HurtBrick1,true,cf(0,1+2,0))
  161. ----------------Sword 2--------------------------
  162. Color1 = "Bright orange" local Color2 = "Really black" BladeC = "Medium stone grey"
  163. Sheath2 = part(Main,v3(.25,3,1),Color1,0,false)w(Sheath2,Torso,Sheath2,true,cf(-1+(.25/-2),-1.5,1)*ca(mr(-60),0,0))
  164. local p = part(Main,v3(.25,1,1),Color1,0,false)w(p,Sheath2,p,true,cf(0,-1.5+-.5,0)*ca(mr(180),0,0))mesh(p,nil,nil,"Wedge",v3(1,1,1))
  165. Handle2 = part(Main,v3(0,0,0),"",0,false)Handle2W = w(Handle2,Sheath2,Handle2,true,cf(0,1.5+1+(.25/2),0)*ca(mr(180),0,0)*cf(0,-.25,0))
  166. local a = Color1
  167. for i = -1,1,2/15 do
  168. local p = part(Main,v3(.4,.25,.4),a,0,false)w(p,Handle2,p,true,cf(0,i,0))inst("SpecialMesh",p).MeshType = "Sphere"
  169. if a == Color1 then a = Color2 else a = Color1 end
  170. end
  171. local p = part(Main,v3(.4,.25,1),Color1,0,false)w(p,Handle2,p,true,cf(0,1,0))
  172. local p2 = part(Main,v3(.4,.25,.5),Color1,0,false)w(p2,p,p2,true,cf(0,0,-.5+.05)*ca(mr(-45),0,0)*cf(0,0,-.5/2+.06))
  173. local p2 = part(Main,v3(.4,.25,.5),Color1,0,false)w(p2,p,p2,true,cf(0,0,.5-.05)*ca(mr(-45),0,0)*cf(0,0,.5/2-.06))
  174. local p = part(Main,v3(.1,3,.5),BladeC,0,false)w(p,Handle2,p,true,cf(0,1+1.5,-.15))
  175. local p = part(Main,v3(.1,3,.1),BladeC,0,false)w(p,Handle2,p,true,cf(0,1+1.5,.3))
  176. local p = part(Main,v3(.1,1,.8),BladeC,0,false)w(p,Handle2,p,true,cf(0,1+3+.5,0))mesh(p,nil,nil,"Wedge",v3(1,1,1))
  177. local pl = inst("PointLight",p)pl.Color = BrickColor.new(Color1).Color pl.Brightness = 100 pl.Range = 4
  178. HurtBrick2 = part(Main,v3(.2,4,.9),BladeC,1,false)w(HurtBrick2,Handle2,HurtBrick2,true,cf(0,1+2,0))
  179. Hb.Selected:connect(function(Mouse)
  180. Attacking = true
  181. RaW = fj(Ra,Torso,NorCfR*ca(0,0,mr(-10)),Torso["Right Shoulder"])
  182. LaW = fj(La,Torso,NorCfL*ca(0,0,mr(-10)),Torso["Left Shoulder"])
  183. for i = 0,6 do wait(.01)
  184. RaW.C0 = clerp(RaW.C0,NorCfR*ca(mr(20),mr(0),mr(-20)),.4)
  185. LaW.C0 = clerp(LaW.C0,NorCfL*ca(mr(20),mr(0),mr(20)),.4)
  186. end
  187. Handle1W.Part0 = Ra
  188. Handle1W.C0 = cf(0,-1,0)*ca(mr(80),0,0)
  189. wait(.01)
  190. Handle2W.Part0 = La
  191. Handle2W.C0 = cf(0,-1,0)*ca(mr(80),0,0)
  192. wait(.01)
  193. for i = 0,6 do wait(.01)
  194. RaW.C0 = clerp(RaW.C0,NorCfR*ca(mr(60),mr(0),mr(-20)),.4)
  195. LaW.C0 = clerp(LaW.C0,NorCfL*ca(mr(60),mr(0),mr(20)),.4)
  196. end
  197. for i = 0,6 do wait(.01)
  198. RaW.C0 = clerp(RaW.C0,NorCfR*ca(mr(0),mr(0),mr(20)),.4)
  199. LaW.C0 = clerp(LaW.C0,NorCfL*ca(mr(0),mr(0),mr(-20)),.4)
  200. Handle1W.C0 = clerp(Handle1W.C0,cf(0,-1,0)*ca(mr(-90),0,0) ,.4)
  201. Handle2W.C0 = clerp(Handle2W.C0,cf(0,-1,0)*ca(mr(-90),0,0) ,.4)
  202. end
  203.  
  204. Attacking = false
  205. Mouse.KeyDown:connect(function(Key)
  206. if Key == '\48' and Attacking == false then SwordStandBy = false
  207. ButtonHold = true
  208. Hum.WalkSpeed = RunWalkSpeed
  209. FastRunning = true
  210. for i = 0,3 do wait(.01)
  211. RaW.C0 = clerp(RaW.C0,NorCfR*ca(mr(-80),mr(0),mr(20)),.8)
  212. LaW.C0 = clerp(LaW.C0,NorCfL*ca(mr(-80),mr(0),mr(-20)),.8)
  213. Handle1W.C0 = clerp(Handle1W.C0,cf(0,-1,0)*ca(mr(-90-45),0,0) ,.4)
  214. Handle2W.C0 = clerp(Handle2W.C0,cf(0,-1,0)*ca(mr(-90-45),0,mr(0)) ,.4)
  215. end
  216. repeat wait()SwordStandBy = false until ButtonHold == false
  217. FastRunning = false
  218. Hum.WalkSpeed = NorWalkSpeed
  219. for i = 0,8 do wait(.01)
  220. if Attacking == true then break end
  221. RaW.C0 = clerp(RaW.C0,NorCfR*ca(mr(0),0,mr(20)),.4)
  222. LaW.C0 = clerp(LaW.C0,NorCfL*ca(mr(0),0,mr(-20)),.4)
  223. Handle1W.C0 = clerp(Handle1W.C0,cf(0,-1,0)*ca(mr(-90),0,0) ,.4)
  224. Handle2W.C0 = clerp(Handle2W.C0,cf(0,-1,0)*ca(mr(-90),0,0),.4)
  225. end
  226. SwordStandBy = true
  227. elseif Key == "e" then
  228. for i = 0,8 do wait(.01)
  229. if Attacking == true then break end
  230. RaW.C0 = clerp(RaW.C0,NorCfR*ca(mr(0),0,mr(90)),.4)
  231. LaW.C0 = clerp(LaW.C0,NorCfL*ca(mr(0),0,mr(-90)),.4)
  232. Handle1W.C0 = clerp(Handle1W.C0,cf(0,-1,0)*ca(mr(-90+-85),0,0) ,.4)
  233. Handle2W.C0 = clerp(Handle2W.C0,cf(0,-1,0)*ca(mr(-90+-85),0,0),.4)
  234. end
  235. local p = part(Main,v3(.1,3,.5),"Medium stone grey",0,false)w(p,Handle2,p,true,cf(0,1+1.5,-.15))
  236. local p = part(Main,v3(.1,3,.1),"Medium stone grey",0,false)w(p,Handle2,p,true,cf(0,1+1.5,.3))
  237.  
  238. elseif Key == "r" and Attacking == false then
  239. Attacking = true
  240. local B1 = nil
  241. local attack = false
  242. cw(function()
  243. wait(.1)
  244. B1 = makeBall("Bright orange",v3(2.5,2.5,2.5),3,.5)
  245.  
  246. while attack==false do B1.CFrame = Torso.CFrame*cf(0,0,-4) wait() end
  247. end)()
  248. for i = 0,3 do wait(.01)
  249. RaW.C0 = clerp(RaW.C0,NorCfR*ca(mr(90),mr(0),mr(0)),.8)
  250. LaW.C0 = clerp(LaW.C0,NorCfL*ca(mr(90),mr(0),mr(0)),.8)
  251. Handle1W.C0 = clerp(Handle1W.C0,cf(0,-1,0)*ca(mr(-90-20),mr(-45),mr(90)),.5)
  252. Handle2W.C0 = clerp(Handle2W.C0,cf(0,-1,0)*ca(mr(-90-20),mr(45),mr(-90)),.5)
  253. end
  254. repeat wait(.01) until B1 ~= nil
  255. Dmg1 = HurtBrick1.Touched:connect(function(hit)DamageFunc(hit,DMG_N*2,0)end)
  256. Dmg2 = HurtBrick1.Touched:connect(function(hit)DamageFunc(hit,DMG_N*2,0)end)
  257. Slash:Play()
  258. Slash:Play()
  259. local StartP = Torso.CFrame*cf(0,0,-4).p
  260. B1.CFrame = cf(Mouse.Hit.p,StartP)*cf(0,0,-(Mouse.Hit.p-StartP).magnitude)*ca(0,mr(180),0)
  261. local bv = Instance.new("BodyVelocity",B1)
  262. bv.maxForce = v3(1e5,1e5,1e5)
  263. local oldcf = B1.CFrame
  264. bv.velocity = oldcf.lookVector*100
  265. game.Debris:AddItem(B1,10)
  266. attack = true
  267. B1.Touched:connect(function(hit)
  268. if hit.Parent ~= Char and hit.Parent.Parent ~= Char and hit.Parent ~= Main and hit.Parent:FindFirstChild("Humanoid") then
  269. if B1 then B1:Destroy()end
  270. DamageFunc(hit,Dmg.MagicDmg,0)
  271. end
  272. end)
  273. for i = 0,3 do wait(.01)
  274. RaW.C0 = clerp(RaW.C0,NorCfR*ca(mr(90),mr(0),mr(90)),.8)
  275. LaW.C0 = clerp(LaW.C0,NorCfL*ca(mr(90),mr(0),mr(-90)),.8)
  276. Handle1W.C0 = clerp(Handle1W.C0,cf(0,-1,0)*ca(mr(-90-20),mr(-45),mr(90)),.5)
  277. Handle2W.C0 = clerp(Handle2W.C0,cf(0,-1,0)*ca(mr(-90-20),mr(45),mr(-90)),.5)
  278. end
  279. Dmg1:disconnect()Dmg2:disconnect()
  280. Attacking = false
  281. for i = 0,8 do wait(.01)
  282. if Attacking == true then break end
  283. RaW.C0 = clerp(RaW.C0,NorCfR*ca(mr(0),0,mr(20)),.4)
  284. LaW.C0 = clerp(LaW.C0,NorCfL*ca(mr(0),0,mr(-20)),.4)
  285. Handle1W.C0 = clerp(Handle1W.C0,cf(0,-1,0)*ca(mr(-90),0,0) ,.5)
  286. Handle2W.C0 = clerp(Handle2W.C0,cf(0,-1,0)*ca(mr(-90),0,0),.5)
  287. end
  288. end
  289. end)
  290. Mouse.KeyUp:connect(function(Key)
  291. if Key == '\48' then
  292. ButtonHold = false
  293. end
  294. end)
  295. Mouse.Button1Down:connect(function()
  296. MouseHold = true
  297. if Attacking == false then ButtonHold = false
  298. Attacking = true
  299. SwordStandBy = false
  300. local DMG_N = Dmg.SlashDamage
  301. local Dmg1 = false
  302. local Dmg2 = false
  303. ComboN = ComboN + 1
  304. if ComboN <= 1 then
  305.  
  306. if Hum.Jump == true then
  307. for i = 0,3 do wait(.01)
  308. RaW.C0 = clerp(RaW.C0,NorCfR*ca(mr(160),mr(0),mr(-45)),.8)
  309. LaW.C0 = clerp(LaW.C0,NorCfL*ca(mr(160),mr(0),mr(45)),.8)
  310. Handle1W.C0 = clerp(Handle1W.C0,cf(0,-1,0)*ca(mr(-90-20),0,mr(0)),.5)
  311. Handle2W.C0 = clerp(Handle2W.C0,cf(0,-1,0)*ca(mr(-90-20),0,mr(0)),.5)
  312. end
  313. wait(.3)
  314. Dmg1 = HurtBrick1.Touched:connect(function(hit)DamageFunc(hit,DMG_N*1.25,0)end)
  315. Dmg2 = HurtBrick1.Touched:connect(function(hit)DamageFunc(hit,DMG_N*1.25,0)end)
  316. Slash:Play()
  317. Slash:Play()
  318. for i = 0,3 do wait(.01)
  319. RaW.C0 = clerp(RaW.C0,NorCfR*ca(mr(-10),mr(0),mr(20)),.8)
  320. LaW.C0 = clerp(LaW.C0,NorCfL*ca(mr(-10),mr(0),mr(-20)),.8)
  321. Handle1W.C0 = clerp(Handle1W.C0,cf(0,-1,0)*ca(mr(-90-45),0,0),.5)
  322. Handle2W.C0 = clerp(Handle2W.C0,cf(0,-1,0)*ca(mr(-90-45),0,mr(0)),.5)
  323. end
  324. elseif FastRunning == true then
  325. for i = 0,3 do wait(.01)
  326. RaW.C0 = clerp(RaW.C0,NorCfR*ca(mr(90),mr(0),mr(0)),.8)
  327. LaW.C0 = clerp(LaW.C0,NorCfL*ca(mr(90),mr(0),mr(0)),.8)
  328. Handle1W.C0 = clerp(Handle1W.C0,cf(0,-1,0)*ca(mr(-90-20),mr(-45),mr(90)),.5)
  329. Handle2W.C0 = clerp(Handle2W.C0,cf(0,-1,0)*ca(mr(-90-20),mr(45),mr(-90)),.5)
  330. end
  331. Dmg1 = HurtBrick1.Touched:connect(function(hit)DamageFunc(hit,DMG_N*2,0)end)
  332. Dmg2 = HurtBrick1.Touched:connect(function(hit)DamageFunc(hit,DMG_N*2,0)end)
  333. Slash:Play()
  334. Slash:Play()
  335. local bv = Instance.new("BodyVelocity",Torso)
  336. bv.maxForce = v3(1e5,1e5,1e5)
  337. local oldcf = Torso.CFrame
  338. bv.velocity = oldcf.lookVector*40
  339. for i = 0,3 do wait(.01)
  340. RaW.C0 = clerp(RaW.C0,NorCfR*ca(mr(90),mr(0),mr(90)),.8)
  341. LaW.C0 = clerp(LaW.C0,NorCfL*ca(mr(90),mr(0),mr(-90)),.8)
  342. Handle1W.C0 = clerp(Handle1W.C0,cf(0,-1,0)*ca(mr(-90-20),mr(-45),mr(90)),.5)
  343. Handle2W.C0 = clerp(Handle2W.C0,cf(0,-1,0)*ca(mr(-90-20),mr(45),mr(-90)),.5)
  344. end
  345. if bv then bv:Destroy() end
  346. else
  347. for i = 0,5 do wait(.01)
  348. RaW.C0 = clerp(RaW.C0,NorCfR*ca(mr(100),mr(0),mr(-45)),.4)
  349. LaW.C0 = clerp(LaW.C0,NorCfL*ca(mr(-5),0,mr(-20)),.4)
  350. Handle1W.C0 = clerp(Handle1W.C0,cf(0,-1,0)*ca(mr(-90),mr(0),mr(20)),.5)
  351. end
  352. Dmg1 = HurtBrick1.Touched:connect(function(hit)DamageFunc(hit,DMG_N*1.5,.05)end)
  353. Slash:Play()
  354. for i = 0,3 do wait(.01)
  355. RaW.C0 = clerp(RaW.C0,NorCfR*ca(mr(-45),mr(0),mr(45)),.8)
  356. LaW.C0 = clerp(LaW.C0,NorCfL*ca(mr(10),0,mr(-20)),.8)
  357. Handle1W.C0 = clerp(Handle1W.C0,cf(0,-1,0)*ca(mr(-90),mr(0),mr(20)),.5)
  358. end
  359. end
  360. ComboN = 1
  361. cw(function()wait(.5)if ComboN >= 2 then else ComboN = 0 end end)()
  362. elseif ComboN == 2 then
  363. for i = 0,5 do wait(.01)
  364. RaW.C0 = clerp(RaW.C0,NorCfR*ca(mr(10),mr(0),mr(20)),.5)
  365. LaW.C0 = clerp(LaW.C0,NorCfL*ca(mr(90),mr(0),mr(45)),.5)
  366. Handle1W.C0 = clerp(Handle1W.C0,cf(0,-1,0)*ca(mr(-90),0,0),.5)
  367. Handle2W.C0 = clerp(Handle2W.C0,cf(0,-1,0)*ca(mr(-90),mr(45),mr(-90)) ,.5)
  368. end
  369. Dmg1 = HurtBrick1.Touched:connect(function(hit)DamageFunc(hit,DMG_N,.1)end)
  370. Slash:Play()
  371. for i = 0,3 do wait(.01)
  372. RaW.C0 = clerp(RaW.C0,NorCfR*ca(mr(-10),mr(0),mr(20)),.8)
  373. LaW.C0 = clerp(LaW.C0,NorCfL*ca(mr(90),0,mr(-90)),.8)
  374. Handle1W.C0 = clerp(Handle1W.C0,cf(0,-1,0)*ca(mr(-90),0,0) ,.5)
  375. Handle2W.C0 = clerp(Handle2W.C0,cf(0,-1,0)*ca(mr(-90),mr(20),mr(-90)),.5)
  376. end
  377. ComboN = 2
  378. cw(function()wait(.5)if ComboN >= 3 then else ComboN = 0 end end)()
  379. elseif ComboN == 3 then
  380. for i = 0,5 do wait(.01)
  381. RaW.C0 = clerp(RaW.C0,NorCfR*ca(mr(120),mr(0),mr(20)),.5)
  382. LaW.C0 = clerp(LaW.C0,NorCfL*ca(mr(-5),0,mr(-20)),.5)
  383. Handle1W.C0 = clerp(Handle1W.C0,cf(0,-1,0)*ca(mr(-90+20),0,0),.5)
  384. Handle2W.C0 = clerp(Handle2W.C0,cf(0,-1,0)*ca(mr(-90),0,0) ,.5)
  385. end
  386. Dmg1 = HurtBrick1.Touched:connect(function(hit)DamageFunc(hit,DMG_N,.1)end)
  387. Slash:Play()
  388. for i = 0,3 do wait(.01)
  389. RaW.C0 = clerp(RaW.C0,NorCfR*ca(mr(20),mr(0),mr(-45)),.8)
  390. LaW.C0 = clerp(LaW.C0,NorCfL*ca(mr(10),0,mr(-20)),.8)
  391. Handle1W.C0 = clerp(Handle1W.C0,cf(0,-1,0)*ca(mr(-90-20),0,0) ,.5)
  392. Handle2W.C0 = clerp(Handle2W.C0,cf(0,-1,0)*ca(mr(-90),0,0) ,.5)
  393. end
  394. ComboN = 3
  395. cw(function()wait(.5)if ComboN >= 4 then else ComboN = 0 end end)()
  396. elseif ComboN <=4 then
  397. --local bg = Instance.new("BodyGyro",Torso)
  398. local oldcf = Torso.CFrame
  399. --bg.cframe = oldcf*ca(mr(0),0,0)
  400. --bg.maxTorque = v3(1e100,1e100,1e100)
  401. local b = false
  402. cw(function()
  403. for i = 0,360,360/8 do wait(.01)
  404. Torso.CFrame = oldcf*ca(0,mr(i),0)
  405. if i >= 100 then b = true end
  406. end
  407. wait(.5)
  408. if bg then bg:Destroy() end
  409. end)()
  410. Dmg2 = HurtBrick1.Touched:connect(function(hit)DamageFunc(hit,DMG_N*2,.1)end)
  411. for i = 0,5 do wait(.01)
  412. RaW.C0 = clerp(RaW.C0,NorCfR*ca(mr(10),mr(0),mr(20)),.5)
  413. LaW.C0 = clerp(LaW.C0,NorCfL*ca(mr(90),mr(0),mr(45)),.5)
  414. Handle1W.C0 = clerp(Handle1W.C0,cf(0,-1,0)*ca(mr(-90),0,0) ,.5)
  415. Handle2W.C0 = clerp(Handle2W.C0,cf(0,-1,0)*ca(mr(-90),mr(45),mr(-90)) ,.5)
  416. end
  417. repeat wait() until b == true
  418. Slash:Play()
  419. for i = 0,3 do wait(.01)
  420. RaW.C0 = clerp(RaW.C0,NorCfR*ca(mr(-10),mr(0),mr(20)),.8)
  421. LaW.C0 = clerp(LaW.C0,NorCfL*ca(mr(90),0,mr(-90)),.8)
  422. Handle1W.C0 = clerp(Handle1W.C0,cf(0,-1,0)*ca(mr(-90),0,0) ,.5)
  423. Handle2W.C0 = clerp(Handle2W.C0,cf(0,-1,0)*ca(mr(-90),mr(20),mr(-90)),.5)
  424. end
  425. ComboN = 0
  426. else
  427. ComboN = 0
  428. end
  429. if Dmg1 then Dmg1:disconnect() end
  430. if Dmg2 then Dmg2:disconnect() end
  431. Attacking = false
  432. for i = 0,8 do wait(.01)
  433. if Attacking == true then break end
  434. RaW.C0 = clerp(RaW.C0,NorCfR*ca(mr(0),0,mr(20)),.4)
  435. LaW.C0 = clerp(LaW.C0,NorCfL*ca(mr(0),0,mr(-20)),.4)
  436. Handle1W.C0 = clerp(Handle1W.C0,cf(0,-1,0)*ca(mr(-90),0,0) ,.5)
  437. Handle2W.C0 = clerp(Handle2W.C0,cf(0,-1,0)*ca(mr(-90),0,0),.5)
  438. end
  439. if not Attacking == true then SwordStandBy = true end
  440. end
  441. end)
  442. Mouse.Button1Up:connect(function()
  443. MouseHold = false
  444. end)
  445. end)
  446. Hb.Deselected:connect(function(Mouse)
  447. Attacking = true
  448. for i = 0,6 do wait(.01)
  449. RaW.C0 = clerp(RaW.C0,NorCfR*ca(mr(60),mr(0),mr(-20)),.4)
  450. LaW.C0 = clerp(LaW.C0,NorCfL*ca(mr(60),mr(0),mr(20)),.4)
  451. Handle1W.C0 = clerp(Handle1W.C0,cf(0,-1,0)*ca(mr(80),0,0) ,.4)
  452. Handle2W.C0 = clerp(Handle2W.C0,cf(0,-1,0)*ca(mr(80),0,0) ,.4)
  453. end
  454. for i = 0,6 do wait(.01)
  455. RaW.C0 = clerp(RaW.C0,NorCfR*ca(mr(20),mr(0),mr(-20)),.4)
  456. LaW.C0 = clerp(LaW.C0,NorCfL*ca(mr(20),mr(0),mr(20)),.4)
  457. end
  458. Handle1W.Part0 = Sheath1
  459. Handle1W.C0 = cf(0,1.5+1+(.25/2),0)*ca(mr(180),0,0)*cf(0,-.25,0)
  460. wait(.01)
  461. Handle2W.Part0 = Sheath2
  462. Handle2W.C0 = cf(0,1.5+1+(.25/2),0)*ca(mr(180),0,0)*cf(0,-.25,0)
  463. wait(.01)
  464. if RaW then RaW:Destroy() RaW = nil end
  465. if LaW then LaW:Destroy() RaW = nil end
  466. Attacking = false
  467. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement