Advertisement
ScriptBuilderSHEHAB

redcliff

Jun 10th, 2016
325
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 17.78 KB | None | 0 0
  1. --[[
  2. Script shared by eletronix ]]
  3.  
  4. Me = game.Players.LocalPlayer
  5. Char = Me.Character
  6. Selected = false
  7. Attack = 1
  8. Attacking = false
  9. Hurt = false
  10. Deb = true
  11. Effect = false
  12. DMG = 35
  13. BlockAnim = false
  14. Rotation = 0
  15. RotationOn = false
  16.  
  17. CamStyles = {"Attach", "Custom", "Fixed", "Follow"}
  18. Where = 2
  19. Style = CamStyles[Where]
  20.  
  21. Asset = "http://www.roblox.com/asset/?id="
  22.  
  23. CA = CFrame.Angles
  24. CN = CFrame.new
  25. V3 = Vector3.new
  26. MR = math.rad
  27. MP = math.pi
  28. MRA = math.random
  29. MH = math.huge
  30.  
  31. Add = {
  32. Mesh = function(P, Id, Id2, scale)
  33. local m = Instance.new("SpecialMesh", P)
  34. m.Scale = scale
  35. m.MeshId = Id
  36. m.TextureId = Id2
  37. end
  38. }
  39.  
  40. Sounds = {
  41. Hit = {"http://www.roblox.com/asset/?id=10209590", 0.8, 1},
  42. Block = {"rbxasset://sounds\\metal.ogg", 1.3, 1},
  43. Slash = {"rbxasset://sounds\\swordslash.wav", 1.6, 1},
  44. }
  45.  
  46. Meshes = {
  47. Coif = {Asset..(52238093), Asset..(33364735)},
  48. Torso = {Asset..(33309581), Asset..(33308631)},
  49. Rarm = {Asset..(33309581), Asset..(33308774)},
  50. Larm = {Asset..(33309581), Asset..(33308496)},
  51. Rleg = {Asset..(33309581), Asset..(33308827)},
  52. Lleg = {Asset..(33309581), Asset..(33308564)},
  53. Sword = {Asset..(49754754), Asset..(49754655)},
  54. Shield = {Asset..(49759449), Asset..(49757732)},
  55. }
  56.  
  57. function waitChild(p, n)
  58. local child = p:findFirstChild(n)
  59. if child then return child end
  60. while true do
  61. child = p.ChildAdded:wait()
  62. if child.Name == n then return child end
  63. end
  64. end
  65.  
  66. function Part(P, Anch, Coll, Tran, Ref, Col, Size)
  67. local p = Instance.new("Part")
  68. p.TopSurface = 0
  69. p.BottomSurface = 0
  70. p.Transparency = Tran
  71. p.Reflectance = Ref
  72. p.CanCollide = Coll
  73. p.Anchored = Anch
  74. p.BrickColor = BrickColor.new(Col)
  75. p.formFactor = "Custom"
  76. p.Size = Size
  77. p.Parent = P
  78. p.Locked = true
  79. p:BreakJoints()
  80. return p
  81. end
  82.  
  83. function Weld(P0, P1, C0, C1)
  84. local w = Instance.new("Weld")
  85. w.Part0 = P0
  86. w.Part1 = P1
  87. w.C0 = C0
  88. w.C1 = C1
  89. w.Parent = P0
  90. return w
  91. end
  92.  
  93. for i,v in pairs(Char:children()) do
  94. if v.Name == "Icy" then v:remove() end
  95. end
  96.  
  97. Mod = Instance.new("Model")
  98. Mod.Name = "Icy"
  99.  
  100. Rarm = waitChild(Char, "Right Arm")
  101. Larm = waitChild(Char, "Left Arm")
  102. Rleg = waitChild(Char, "Right Leg")
  103. Lleg = waitChild(Char, "Left Leg")
  104. Torso = waitChild(Char, "Torso")
  105. Hum = waitChild(Char, "Humanoid")
  106. Neck = waitChild(Torso, "Neck")
  107.  
  108. RH = waitChild(Torso, "Right Hip")
  109. LH = waitChild(Torso, "Left Hip")
  110.  
  111. function Play(Sound)
  112. local s = Instance.new("Sound")
  113. s.SoundId = Sound[1]
  114. s.Pitch = Sound[2]
  115. s.Volume = Sound[3]
  116. s.PlayOnRemove = true
  117. s.Parent = Torso
  118. game.Debris:AddItem(s, 0.0001)
  119. end
  120.  
  121. for _,v in pairs(Char:children()) do
  122. if v:IsA("Shirt") or v:IsA("Pants") or v:IsA("Hat") or v:IsA("CharacterMesh") or v:IsA("BodyColors") then
  123. v:remove()
  124. elseif v:IsA("BoolValue") and v.Name == "Block" then
  125. v:remove()
  126. end
  127. end
  128.  
  129. for _,v in pairs(Torso:children()) do
  130. if v:IsA("Decal") or v:IsA("Texture") then v:remove() end
  131. end
  132.  
  133. CamBlock = Part(Mod, true, false, 1, 0, "White", V3(0.4, 0.4, 0.4))
  134. Cam = workspace.CurrentCamera
  135.  
  136. local Blocking = Instance.new("BoolValue")
  137. Blocking.Value = false
  138. Blocking.Name = "Block"
  139. Blocking.Parent = Char
  140.  
  141. Torso.Transparency = 1
  142.  
  143. Faketorso = Part(Mod, false, false, 0, 0, Torso.BrickColor.Name, V3(1.98, 1.98, 0.98))
  144. FW = Weld(Torso, Faketorso, CN(), CN())
  145.  
  146. Hat = Instance.new("Hat", Char)
  147. Hat.Name = "Epoc."
  148.  
  149. HatHandle = Part(Hat, false, false, 0, 0, "White", V3(1.5, 1.8, 1.4))
  150. HatHandle.Name = "Handle"
  151. Hat.AttachmentPos = V3(0, 0.3, 0.1)
  152. Add.Mesh(HatHandle, Meshes.Coif[2], Meshes.Coif[1], V3(1.1,1.1,1.1))
  153.  
  154. for _,v in pairs({{Rarm, Meshes.Rarm}, {Larm, Meshes.Larm}, {Rleg, Meshes.Rleg}, {Lleg, Meshes.Lleg}, {Faketorso, Meshes.Torso}}) do
  155. for _,v in pairs(v[1]:children()) do
  156. if v:IsA("SpecialMesh") then
  157. v:remove()
  158. end
  159. end
  160. local mes = Add.Mesh(v[1], v[2][2], v[2][1], V3(1,1,1))
  161. end
  162.  
  163. Sword = Part(Mod, false, false, 0, 0, "White", V3(0.8, 0.4, 4.5))
  164. Add.Mesh(Sword, Meshes.Sword[2], Meshes.Sword[1], V3(2.1, 2.5, 2.15))
  165.  
  166. Shield = Part(Mod, false, false, 0, 0, "White", V3(2.3, 0.6, 3))
  167. Add.Mesh(Shield, Meshes.Shield[2], Meshes.Shield[1], V3(1.5, 1.6, 1.3))
  168.  
  169. RABrick = Part(Mod, false, false, 1, 0, "White", V3(0.1, 0.1, 0.1))
  170. LABrick = Part(Mod, false, false, 1, 0, "White", V3(0.1, 0.1, 0.1))
  171. RLBrick = Part(Mod, false, false, 1, 0, "White", V3(0.1, 0.1, 0.1))
  172. LLBrick = Part(Mod, false, false, 1, 0, "White", V3(0.1, 0.1, 0.1))
  173.  
  174. RABW = Weld(Torso, RABrick, CN(), CN(-1.5, -0.5, 0))
  175. LABW = Weld(Torso, LABrick, CN(), CN(1.5, -0.5, 0))
  176. RLBW = Weld(Torso, RLBrick, CN(), CN(-0.5, 1.2, 0))
  177. LLBW = Weld(Torso, LLBrick, CN(), CN(0.5, 1.2, 0))
  178.  
  179. function Atch(p)
  180. RABW.Part0 = p
  181. LABW.Part0 = p
  182. RLBW.Part0 = p
  183. LLBW.Part0 = p
  184. RH.Part0 = p
  185. LH.Part0 = p
  186. end
  187.  
  188. RAW = Weld(RABrick, nil, CN(), CN(0, 0.5, 0))
  189. LAW = Weld(LABrick, nil, CN(), CN(0, 0.5, 0))
  190. RLW = Weld(RLBrick, nil, CN(), CN(0, 0.8, 0))
  191. LLW = Weld(LLBrick, nil, CN(), CN(0, 0.8, 0))
  192.  
  193. HB = Part(Mod, false, false, 1, 0, "White", V3(0.1, 0.1, 0.1))
  194. HBW = Weld(Rarm, HB, CN(0, -1, 0), CN())
  195. HW = Weld(HB, nil, CN(), CN(0, 0, -2) * CA(MP, 0, MR(90)))
  196.  
  197. SW = Weld(Larm, Shield, CA(MR(-90), 0, MR(90)), CN(0, 0.4, 0.2) * CA(MR(160), 0, 0))
  198. TW = Weld(Torso, Sword, CA(MR(90), MR(-40), 0), CN(0, -0.7, 0))
  199.  
  200. function Normal()
  201. SW.C1 = CN(0, 0.4, 0.2) * CA(MR(160), 0, 0)
  202. HW.C0 = CN()
  203. RAW.C0 = CN(-0.3, 0.2, -0.4) * CA(MR(70), MR(40), MR(-30))
  204. LAW.C0 = CN(0.3, 0, -0.5) * CA(MR(45), MR(-35), MR(20))
  205. HW.C1 = CN(0, 0, -2) * CA(MP, 0, MR(-90))
  206. FW.C0 = CN()
  207. end
  208.  
  209. Mod.Parent = Char
  210.  
  211. if script.Parent.className ~= "HopperBin" then
  212. h = Instance.new("HopperBin",Me.Backpack)
  213. h.Name = "Redcliff"
  214. script.Parent = h
  215. end
  216.  
  217. Bin = script.Parent
  218.  
  219. function getStat(c)
  220. local blo = false
  221. local h
  222. for _,v in pairs(c:children()) do
  223. if v:IsA("Humanoid") then
  224. if v.Health > 0 then
  225. h = v
  226. end
  227. elseif v:IsA("BoolValue") then
  228. if v.Name == "Block" then
  229. blo = v.Value
  230. end
  231. end
  232. end
  233. return h, blo
  234. end
  235.  
  236. function Damage(h, dmg)
  237. h.Health = h.Health - dmg
  238. end
  239.  
  240. function SwordDmg(hit)
  241. local h, b = getStat(hit.Parent)
  242. if h then
  243. if Hurt and Deb and b == false then
  244. Damage(h, MRA(5+(DMG/3), DMG+5))
  245. Play(Sounds.Hit)
  246. elseif Hurt and Deb and b then
  247. Play(Sounds.Block)
  248. end
  249. Deb = false
  250. end
  251. end
  252.  
  253. Sword.Touched:connect(SwordDmg)
  254.  
  255. function SE(part, cf)
  256. coroutine.resume(coroutine.create(function()
  257. Effect = true
  258. local lastP = (part.CFrame * cf).p
  259. while Effect do
  260. wait()
  261. local p = Part(Mod, true, false, 0, 0, "Neon orange", V3(0.2, 0.2, 0.2))
  262. local posnow = (part.CFrame * cf).p
  263. local magn = (lastP - posnow).magnitude
  264. local cc = CN(lastP, posnow) * CA(MR(-90), 0, 0) * CN(0, magn/2, 0)
  265. local m = Instance.new("SpecialMesh", p)
  266. m.MeshType = "Head"
  267. m.Scale = V3(0.9, magn*5+0.45, 0.9)
  268. p.CFrame = cc
  269. coroutine.resume(coroutine.create(function()
  270. for i = 0, 1, 0.15 do
  271. wait()
  272. m.Scale = V3(0.9-0.9*i, magn*5+0.45-0.45*i, 0.9-0.9*i)
  273. p.Transparency = -0.2+1.2*i
  274. end
  275. p:remove()
  276. end))
  277. lastP = (part.CFrame * cf).p
  278. end
  279. end))
  280. end
  281.  
  282. function EE()
  283. Effect = false
  284. end
  285.  
  286. function SetAtk(S, E)
  287. coroutine.resume(coroutine.create(function()
  288. Attack = E
  289. wait(0.25)
  290. Attack = S
  291. end))
  292. end
  293.  
  294. Combo = {
  295. function()
  296. Attack = 1
  297. Atch(Faketorso)
  298. Attacking = true
  299. for i = 0.15, 1, 0.15 do
  300. FW.C0 = CA(0, MR(-35*i), 0)
  301. RAW.C0 = CN(-0.3, 0.2, -0.4) * CA(MR(70+90*i), MR(40-20*i), MR(-30+30*i))
  302. HW.C0 = CA(MR(20*i), 0, MR(-10*i))
  303. LAW.C0 = CN(0.3, 0, -0.5) * CA(MR(45+10*i), MR(-35+20*i), MR(20))
  304. wait()
  305. end
  306. Play(Sounds.Slash)
  307. for i = 0.33, 1, 0.33 do
  308. FW.C0 = CA(0, MR(-35-10*i), 0)
  309. RAW.C0 = CN(-0.3, 0.2, -0.4) * CA(MR(160+10*i), MR(20-5*i), MR(10*i))
  310. HW.C0 = CA(MR(20+5*i), 0, MR(-10))
  311. LAW.C0 = CN(0.3, 0, -0.5) * CA(MR(55+5*i), MR(-15+5*i), MR(20))
  312. wait()
  313. end
  314. SE(Sword, CN(0, 0, 2.2))
  315. Hurt = true
  316. Deb = true
  317. for i = 0.16, 1, 0.16 do
  318. FW.C0 = CA(0, MR(-45+60*i), 0)
  319. RAW.C0 = CN(-0.3, 0.2, -0.4) * CA(MR(170-140*i), MR(15+10*i), MR(10-20*i))
  320. HW.C0 = CA(MR(25-75*i), 0, MR(-10))
  321. LAW.C0 = CN(0.3, 0, -0.5+0.8*i) * CA(MR(60-90*i), MR(-10+20*i), MR(20-30*i))
  322. wait()
  323. end
  324. Hurt = false
  325. for i = 0.25, 1, 0.25 do
  326. FW.C0 = CA(0, MR(15+10*i), 0)
  327. RAW.C0 = CN(-0.3, 0.2, -0.4) * CA(MR(30-10*i), MR(25+5*i), MR(-10-5*i))
  328. HW.C0 = CA(MR(-50-5*i), 0, MR(-10))
  329. LAW.C0 = CN(0.3, 0, 0.3+0.1*i) * CA(MR(-30-10*i), MR(10+5*i), MR(-10-5*i))
  330. wait()
  331. end
  332. EE()
  333. SetAtk(1, 2)
  334. Attacking = false
  335. wait(0.08)
  336. for i = 0.2, 1, 0.2 do
  337. if Attacking then return end
  338. FW.C0 = CA(0, MR(25-25*i), 0)
  339. RAW.C0 = CN(-0.3, 0.2, -0.4) * CA(MR(20+40*i), MR(30+8*i), MR(-15-10*i))
  340. HW.C0 = CA(MR(-55+45*i), 0, MR(-10+10*i))
  341. LAW.C0 = CN(0.3, 0, 0.4-0.8*i) * CA(MR(-40+75*i), MR(15-45*i), MR(-15+30*i))
  342. wait()
  343. end
  344. for i = 0.33, 1, 0.33 do
  345. if Attacking then return end
  346. FW.C0 = CA(0, 0, 0)
  347. RAW.C0 = CN(-0.3, 0.2, -0.4) * CA(MR(60+10*i), MR(38+2*i), MR(-25-5*i))
  348. HW.C0 = CA(MR(-10+10*i), 0, 0)
  349. LAW.C0 = CN(0.3, 0, -0.4-0.1*i) * CA(MR(35+10*i), MR(-30-5*i), MR(15+5*i))
  350. wait()
  351. end
  352. Attack = 1
  353. Attacking = false
  354. FW.C0 = CN()
  355. RAW.C0 = CN(-0.3, 0.2, -0.4) * CA(MR(70), MR(40), MR(-30))
  356. HW.C0 = CN()
  357. Atch(Torso)
  358. end,
  359. function()
  360. Attack = 2
  361. Attacking = true
  362. for i = 0.1, 1, 0.1 do
  363. FW.C0 = CA(0, MR(25+15*i), 0)
  364. RAW.C0 = CN(-0.3, 0.2, -0.4) * CA(MR(20+65*i), MR(30-30*i), MR(-15-35*i))
  365. LAW.C0 = CN(0.3+0.3*i, 0, 0.2) * CA(MR(-40-10*i), MR(15), MR(-15))
  366. HW.C0 = CA(MR(-55+45*i), MR(80*i), MR(-10+10*i))
  367. wait()
  368. end
  369. Play(Sounds.Slash)
  370. for i = 0.25, 1, 0.25 do
  371. FW.C0 = CA(0, MR(40+5*i), 0)
  372. RAW.C0 = CN(-0.3, 0.2, -0.4) * CA(MR(85+5*i), 0, MR(-50-5*i))
  373. LAW.C0 = CN(0.6, 0, 0.2) * CA(MR(-50-5*i), MR(15), MR(-15))
  374. HW.C0 = CA(MR(-10+10*i), MR(80+10*i), 0)
  375. wait()
  376. end
  377. SE(Sword, CN(0, 0, 2.2))
  378. Hurt = true
  379. Deb = true
  380. for i = 0.16, 1, 0.16 do
  381. FW.C0 = CA(0, MR(45-80*i), 0)
  382. RAW.C0 = CN(-0.3+0.3*i, 0.2, -0.4) * CA(MR(90), 0, MR(-55+95*i))
  383. LAW.C0 = CN(0.6-0.3*i, 0, 0.2-0.8*i) * CA(MR(-55+130*i), MR(15-15*i), MR(-15+50*i))
  384. HW.C0 = CA(0, MR(90), 0)
  385. HW.C1 = CN(0, 0, -2) * CA(MP, MR(-40*i), MR(-90))
  386. wait()
  387. end
  388. Hurt = false
  389. for i = 0.25, 1, 0.25 do
  390. FW.C0 = CA(0, MR(-35-10*i), 0)
  391. RAW.C0 = CN(0.1*i, 0.2, -0.4) * CA(MR(90), 0, MR(40+10*i))
  392. LAW.C0 = CN(0.3, 0, -0.6+0.1*i) * CA(MR(75+10*i), 0, MR(35+10*i))
  393. HW.C0 = CA(0, MR(90), 0)
  394. HW.C1 = CN(0, 0, -2) * CA(MP, MR(-40-5*i), MR(-90))
  395. wait()
  396. end
  397. EE()
  398. SetAtk(1, 3)
  399. Attacking = false
  400. wait(0.08)
  401. for i = 0.16, 1, 0.16 do
  402. if Attacking then return end
  403. FW.C0 = CA(0, MR(-45+35*i), 0)
  404. RAW.C0 = CN(0.1-0.4*i, 0.2, -0.4) * CA(MR(90-15*i), MR(35*i), MR(50-70*i))
  405. LAW.C0 = CN(0.3, 0, -0.6+0.1*i) * CA(MR(85-30*i), MR(-30*i), MR(45-20*i))
  406. HW.C0 = CA(0, MR(90-80*i), 0)
  407. HW.C1 = CN(0, 0, -2) * CA(MP, MR(-45+40*i), MR(-90))
  408. wait()
  409. end
  410. for i = 0.25, 1, 0.25 do
  411. if Attacking then return end
  412. FW.C0 = CA(0, MR(-10+10*i), 0)
  413. RAW.C0 = CN(-0.3, 0.2, -0.4) * CA(MR(75-5*i), MR(35+5*i), MR(-20-10*i))
  414. LAW.C0 = CN(0.3, 0, -0.6+0.1*i) * CA(MR(55-10*i), MR(-30-5*i), MR(25-5*i))
  415. HW.C0 = CA(0, MR(10-10*i), 0)
  416. HW.C1 = CN(0, 0, -2) * CA(MP, MR(-5+5*i), MR(-90))
  417. wait()
  418. end
  419. Normal()
  420. Atch(Torso)
  421. end,
  422. function()
  423. Attack = 3
  424. Attacking = true
  425. for i = 0.15, 1, 0.15 do
  426. FW.C0 = CA(0, MR(-45+35*i), 0)
  427. RAW.C0 = CN(0.1-0.2*i, 0.2-0.2*i, -0.4) * CA(MR(90+30*i), 0, MR(50-70*i)) * CN(0, -0.5*i, 0)
  428. LAW.C0 = CN(0.3-0.2*i, 0, -0.5) * CA(MR(85+35*i), 0, MR(45-25*i)) * CN(0, -0.5*i, 0)
  429. HW.C0 = CA(0, MR(90-70*i), MR(-45*i))
  430. HW.C1 = CN(0, 0, -2) * CA(MP, MR(-45+45*i), MR(-90))
  431. wait()
  432. end
  433. for i = 0.18, 1, 0.18 do
  434. FW.C0 = CA(0, MR(-10+10*i), 0)
  435. RAW.C0 = CN(-0.1, 0, -0.4) * CA(MR(120+80*i), 0, MR(-20-15*i)) * CN(0, -0.5-0.1*i, 0)
  436. LAW.C0 = CN(0.1, 0, -0.5) * CA(MR(120+80*i), 0, MR(20+15*i)) * CN(0, -0.5-0.1*i, 0)
  437. HW.C0 = CA(0, MR(20-20*i), MR(-45-10*i))
  438. HW.C1 = CN(0, 0, -2) * CA(MP, 0, MR(-90))
  439. wait()
  440. end
  441. Play(Sounds.Slash)
  442. for i = 0.25, 1, 0.25 do
  443. FW.C0 = CA(0, 0, 0)
  444. RAW.C0 = CN(-0.1, 0, -0.4) * CA(MR(200+10*i), 0, MR(-35-5*i)) * CN(0, -0.6, 0)
  445. LAW.C0 = CN(0.1, 0, -0.5) * CA(MR(200+10*i), 0, MR(35+5*i)) * CN(0, -0.6, 0)
  446. HW.C0 = CA(0, 0, MR(-55+5*i))
  447. wait()
  448. end
  449. SE(Sword, CN(0, 0, 2.2))
  450. Hurt = true
  451. Deb = true
  452. for i = 0.14, 1, 0.14 do
  453. RAW.C0 = CN(-0.1, 0, -0.4) * CA(MR(210-180*i), 0, MR(-40)) * CN(0, -0.6-0.25*i, 0)
  454. LAW.C0 = CN(0.1, 0, -0.5) * CA(MR(210-180*i), 0, MR(40)) * CN(0, -0.6-0.25*i, 0)
  455. HW.C0 = CA(MR(-55*i), MR(-30*i), MR(-50))
  456. wait()
  457. end
  458. Hurt = false
  459. EE()
  460. Play(Sounds.Block)
  461. for i = 0.33, 1, 0.33 do
  462. RAW.C0 = CN(-0.1, 0, -0.4) * CA(MR(30+5*i), 0, MR(-40)) * CN(0, -0.85+0.4*i, 0)
  463. LAW.C0 = CN(0.1, 0, -0.5) * CA(MR(30+5*i), 0, MR(40)) * CN(0, -0.85+0.4*i, 0)
  464. HW.C0 = CA(MR(-55+5*i), MR(-30), MR(-50))
  465. wait()
  466. end
  467. for i = 0.16, 1, 0.16 do
  468. RAW.C0 = CN(-0.1-0.2*i, 0.2*i, -0.4) * CA(MR(35+25*i), MR(30*i), MR(-40+7*i)) * CN(0, -0.45+0.3*i, 0)
  469. LAW.C0 = CN(0.1+0.2*i, 0, -0.5) * CA(MR(35+5*i), MR(-30*i), MR(40-15*i)) * CN(0, -0.45+0.3*i, 0)
  470. HW.C0 = CA(MR(-50+40*i), MR(-30+25*i), MR(-50+45*i))
  471. wait()
  472. end
  473. for i = 0.25, 1, 0.25 do
  474. RAW.C0 = CN(-0.3, 0.2, -0.4) * CA(MR(60+10*i), MR(30+10*i), MR(-33+3*i)) * CN(0, -0.15+0.15*i, 0)
  475. LAW.C0 = CN(0.3, 0, -0.5) * CA(MR(40+5*i), MR(-30-5*i), MR(25-5*i)) * CN(0, -0.15+0.15*i, 0)
  476. HW.C0 = CA(MR(-10+10*i), MR(-5+5*i), MR(-5+5*i))
  477. wait()
  478. end
  479. Attack = 1
  480. Atch(Torso)
  481. Attacking = false
  482. Normal()
  483. end
  484. }
  485.  
  486. function onButtonDown()
  487. if Attacking == false and BlockAnim == false and Blocking.Value == false then
  488. Combo[Attack]()
  489. end
  490. end
  491.  
  492. function Block()
  493. coroutine.resume(coroutine.create(function()
  494. Blocking.Value = true
  495. BlockAnim = trueCN
  496. for i = 0.15, 1, 0.15 do
  497. LAW.C0 = CN(0.3+0.4*i, 0, -0.5-0.4*i) * CA(MR(45+35*i), MR(-35+30*i), MR(20+50*i))
  498. RAW.C0 = CN(-0.3-0.1*i, 0.2, -0.4) * CA(MR(70+15*i), MR(40-30*i), MR(-30-30*i))
  499. SW.C1 = CN(0, 0.4, 0.2) * CA(MR(160+15*i), MR(-75*i), 0)
  500. wait()
  501. end
  502. Play(Sounds.Block)
  503. for i = 0.33, 1, 0.33 do
  504. LAW.C0 = CN(0.7+0.1*i, 0, -0.9-0.1*i) * CA(MR(80+5*i), MR(-5+5*i), MR(70+10*i))
  505. RAW.C0 = CN(-0.4, 0.2, -0.4) * CA(MR(85+5*i), MR(10-10*i), MR(-60-5*i))
  506. SW.C1 = CN(0, 0.4, 0.2) * CA(MR(175+5*i), MR(-75-15*i), 0)
  507. wait()
  508. end
  509. LAW.C0 = CN(0.8, 0, -1) * CA(MR(85), 0, MR(80))
  510. repeat wait() until Blocking.Value == false
  511. for i = 0.14, 1, 0.14 do
  512. LAW.C0 = CN(0.8-0.5*i, 0, -1+0.5*i) * CA(MR(85-40*i), MR(-35*i), MR(80-60*i))
  513. RAW.C0 = CN(-0.4+0.1*i, 0.2, -0.4) * CA(MR(90-20*i), MR(40*i), MR(-65+35*i))
  514. SW.C1 = CN(0, 0.4, 0.2) * CA(MR(180-20*i), MR(-90+90*i), 0)
  515. wait()
  516. end
  517. BlockAnim = false
  518. Normal()
  519. end))
  520. end
  521.  
  522. function SelectAnim()
  523. RAW.Part1 = Rarm
  524. for i = 0.14, 1, 0.14 do
  525. RAW.C0 = CA(MR(205*i), MR(30*i), MR(-10*i))
  526. wait()
  527. end
  528. for i = 0.33, 1, 0.33 do
  529. RAW.C0 = CA(MR(205+15*i), MR(30), MR(-10))
  530. wait()
  531. end
  532. HW.C0 = CA(MR(40), MR(30), MR(120))* CN(0, 0, 0.15)
  533. HW.Part1 = Sword
  534. TW.Part1 = nil
  535. for i = 0.18, 1, 0.18 do
  536. RAW.C0 = CA(MR(220-80*i), MR(30-50*i), MR(-10+30*i))
  537. HW.C0 = CA(MR(40-40*i), MR(30-30*i), MR(120-120*i))* CN(0, 0, 0.15-0.15*i)
  538. wait()
  539. end
  540. for i = 0.33, 1, 0.33 do
  541. RAW.C0 = CA(MR(140-15*i), MR(-20-5*i), MR(20+5*i))
  542. HW.C0 = CA(MR(-10*i), 0, 0)
  543. wait()
  544. end
  545. LAW.Part1 = Larm
  546. for i = 0.18, 1, 0.18 do
  547. RAW.C0 = CN(-0.3*i, 0.2*i, -0.4*i) * CA(MR(125-45*i), MR(-25+60*i), MR(25-50*i))
  548. LAW.C0 = CN(0.3*i, 0, -0.5*i) * CA(MR(40*i), MR(-30*i), MR(15*i))
  549. HW.C0 = CA(MR(-10+10*i), 0, 0)
  550. wait()
  551. end
  552. HW.C0 = CN()
  553. for i = 0.33, 1, 0.33 do
  554. RAW.C0 = CN(-0.3, 0.2, -0.4) * CA(MR(80-10*i), MR(35+5*i), MR(-25-5*i))
  555. LAW.C0 = CN(0.3, 0, -0.5) * CA(MR(40+5*i), MR(-30-5*i), MR(15+5*i))
  556. wait()
  557. end
  558. Normal()
  559. end
  560.  
  561. function DeselectAnim()
  562. for i = 0.14, 1, 0.14 do
  563. RAW.C0 = CN(-0.3+0.3*i, 0.2-0.2*i, -0.4+0.4*i) * CA(MR(70+80*i), MR(40-60*i), MR(-30+20*i))
  564. LAW.C0 = CN(0.3-0.3*i, 0, -0.5+0.5*i) * CA(MR(45-35*i), MR(-35+25*i), MR(20-15*i))
  565. wait()
  566. end
  567. for i = 0.33, 1, 0.33 do
  568. RAW.C0 = CA(MR(150+10*i), MR(-20-5*i), MR(-10+5*i))
  569. LAW.C0 = CA(MR(10-10*i), MR(-10+10*i), MR(5-5*i))
  570. wait()
  571. end
  572. LAW.Part1 = nil
  573. for i = 0.18, 1, 0.18 do
  574. RAW.C0 = CA(MR(160+50*i), MR(-25+50*i), MR(-5-5*i))
  575. HW.C0 = CA(MR(30*i), MR(25*i), MR(110*i))* CN(0, 0, 0.15*i)
  576. wait()
  577. end
  578. for i = 0.33, 1, 0.33 do
  579. RAW.C0 = CA(MR(210+10*i), MR(25+5*i), MR(-10))
  580. HW.C0 = CA(MR(30+10*i), MR(25+5*i), MR(110+10*i))* CN(0, 0, 0.15)
  581. wait()
  582. end
  583. HW.Part1 = nil
  584. TW.Part1 = Sword
  585. for i = 0.2, 1, 0.2 do
  586. RAW.C0 = CA(MR(220-200*i), MR(30-20*i), MR(-10+10*i))
  587. wait()
  588. end
  589. for i = 0.33, 1, 0.33 do
  590. RAW.C0 = CA(MR(20-20*i), MR(10-10*i), 0)
  591. wait()
  592. end
  593. RAW.Part1 = nil
  594. end
  595.  
  596. function onSelected(mouse)
  597. SelectAnim()
  598. Selected = true
  599. mouse.KeyDown:connect(function(key)
  600. key = key:lower()
  601. if key == "f" and Blocking.Value == false and BlockAnim == false and Attacking == false then
  602. Block()
  603. local k
  604. repeat k = mouse.KeyUp:wait() until k == "f"
  605. Blocking.Value = false
  606. elseif key == "q" then
  607. Where = Where - 1
  608. elseif key == "e" then
  609. Where = Where + 1
  610. elseif key == "z" then
  611. local h = nil
  612. local t = mouse.Target
  613. if t then
  614. h = getStat(t.Parent)
  615. if h == nil and t.Parent.Parent ~= game and t.Parent.Parent ~= nil then
  616. h = getStat(t.Parent.Parent)
  617. end
  618. end
  619. if h == nil then
  620. CamBlock.CFrame = CFrame.new(mouse.Hit.p)
  621. Cam.CameraSubject = CamBlock
  622. Cam.CameraType = Enum.CameraType[CamStyles[Where] ]
  623. else
  624. Cam.CameraSubject = h
  625. end
  626. elseif key == "x" then
  627. Cam.CameraSubject = Hum
  628. elseif key == "r" then
  629. RotationOn = not RotationOn
  630. elseif key == "t" then
  631. local k
  632. coroutine.resume(coroutine.create(function()
  633. repeat
  634. wait()
  635. Rotation = Rotation - 0.05
  636. until k == "t"
  637. end))
  638. repeat k = mouse.KeyUp:wait() until k == "t"
  639. elseif key == "y" then
  640. local k
  641. coroutine.resume(coroutine.create(function()
  642. repeat
  643. wait()
  644. Rotation = Rotation + 0.05
  645. until k == "y"
  646. end))
  647. repeat k = mouse.KeyUp:wait() until k == "y"
  648. end
  649. if Where > #CamStyles then Where = 1 elseif Where < 1 then Where = #CamStyles end
  650. Cam.CameraType = Enum.CameraType[CamStyles[Where] ]
  651. end)
  652. mouse.Button1Down:connect(function()
  653. onButtonDown()
  654. end)
  655. end
  656.  
  657. function onDeselected(mouse)
  658. Selected = false
  659. DeselectAnim()
  660. end
  661.  
  662. Bin.Selected:connect(onSelected)
  663. Bin.Deselected:connect(onDeselected)
  664.  
  665. while true do
  666. wait()
  667. if RotationOn then
  668. Cam.CoordinateFrame = Cam.CoordinateFrame * CN(Rotation, 0, 0)
  669. end
  670. end
  671.  
  672.  
  673. --mediafire
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement