Advertisement
naser2345

Winter Staff

Jul 11th, 2016
3,279
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 35.35 KB | None | 0 0
  1. --fixed by naser2018--
  2. --Player Settings
  3. local modelName="Winter Staff" --Name here
  4. repeat wait() until game.Players.LocalPlayer and game.Players.LocalPlayer.Character
  5. local player=game.Players.LocalPlayer
  6. local char=player.Character
  7. --CharacterParts
  8. local humanoid=char.Humanoid
  9. local head=char.Head
  10. local torso=char.Torso
  11. local LA=char:findFirstChild("Left Arm")
  12. local RA=char:findFirstChild("Right Arm")
  13. local LL=char:findFirstChild("Left Leg")
  14. local RL=char:findFirstChild("Right Leg")
  15. --Joints
  16. local LS=torso:findFirstChild("Left Shoulder")
  17. local RS=torso:findFirstChild("Right Shoulder")
  18. local LH=torso:findFirstChild("Left Hip")
  19. local RH=torso:findFirstChild("Right Hip")
  20. LS.Part0=torso RS.Part0=torso LH.Part0=torso RH.Part0=torso
  21. --Local Functions
  22. local s=function(f) Spawn(f) end
  23. local c=function(f) coroutine.resume(coroutine.create(f)) end
  24. pcall(function() player.Backpack[modelName]:remove() end)
  25. pcall(function() char["CharacterParts"]:remove() end)
  26. pcall(function() char[modelName]:remove() end)
  27. pcall(function() player.PlayerGui[modelName]:remove() end)
  28. pcall(function() for i, v in pairs(char:children()) do if v:isA("BasePart") then v.Transparency=0 end end end)
  29. --Settings
  30. local model=Instance.new("Model", char) model.Name="CharacterParts"
  31. local model2=Instance.new("Model", char) model2.Name=modelName
  32. local bin=Instance.new("HopperBin", player.Backpack) bin.Name=modelName
  33. local gui=Instance.new("ScreenGui") gui.Name=modelName
  34. local skincolor="Really black"
  35. local body={}
  36. local animate={}
  37. local obj={}
  38. local onTrail=false
  39. local onKey=false
  40. local onHit=false
  41. local onBlock=false
  42. local onHold=false
  43. local colorSet={
  44. Handle="Brown";
  45. Blade="Mid gray";
  46. Extra="Reddish brown";
  47. }
  48. local combo=0
  49. local dmg=math.random(10, 15)
  50. local mouse
  51. local add={
  52. Part=function(par, a, c, col, t, s, cf, ms)
  53. local p=Instance.new("Part", par) pcall(function() p.TopSurface="Smooth" p.BottomSurface="Smooth" p.formFactor="Custom" p.Anchored=a p.CanCollide=c p.BrickColor=BrickColor.new(col) p.Transparency=t p.Size=s p.CFrame=cf or CFrame.new() end)
  54. local m=Instance.new("BlockMesh", p) pcall(function() m.Scale=ms or Vector3.new(1, 1, 1) end)
  55. return p
  56. end;
  57. Wedge=function(par, a, c, col, t, s, cf, ms)
  58. local p=Instance.new("WedgePart", par) pcall(function() p.TopSurface="Smooth" p.BottomSurface="Smooth" p.formFactor="Custom" p.Anchored=a p.CanCollide=c p.BrickColor=BrickColor.new(col) p.Transparency=t p.Size=s p.CFrame=cf or CFrame.new() end)
  59. local m=Instance.new("SpecialMesh", p) pcall(function() m.Scale=ms or Vector3.new(1, 1, 1) m.MeshType="Wedge" end)
  60. return p
  61. end;
  62. Gui=function(ins, par, bc, bg, tc, fs, text, t, s, pos)
  63. local g=Instance.new(ins, par) pcall(function() g.BorderColor=BrickColor.new(bc) g.BackgroundColor=BrickColor.new(bg) g.TextColor=BrickColor.new(tc) g.FontSize=fs g.Font="ArialBold" g.Text=text g.BackgroundTransparency=t g.Size=s g.Position=pos end)
  64. return g
  65. end;
  66. Weld=function(par, p1, cf)
  67. local w=Instance.new("Weld", par) pcall(function() w.Part0=w.Parent or par w.Part1=p1 w.C1=cf or CFrame.new() end)
  68. return w
  69. end;
  70. Mesh=function(ins, par, s, of, t, id, tid)
  71. local m=Instance.new(ins, par) pcall(function() m.Scale=s or Vector3.new(1, 1, 1) m.Offset=of or Vector3.new() m.MeshId=id or "" m.TextureId=tid or "" m.MeshType=t end)
  72. return m
  73. end;
  74. Sound=function(parent, id, pitch, volume)
  75. local s=Instance.new("Sound", parent) pcall(function() s.SoundId=id s.Volume=volume s.Pitch=pitch end)
  76. return s
  77. end;
  78. }
  79. --Sounds
  80. local Sounds={
  81. Slash="rbxasset://sounds//swordslash.wav";
  82. Hit="http://www.roblox.com/asset/?id=11113679 ";
  83. Equip="rbxasset://sounds/unsheath.wav";
  84. Charge="http://www.roblox.com/asset/?id=2101137";
  85. ElectricShortage="http://roblox.com/asset/?id=10209481";
  86. ElectricSound="http://www.roblox.com/asset/?id=10756118";
  87. Electric="http://www.roblox.com/asset/?id=2800815";
  88. Abscond="http://www.roblox.com/asset/?id=2767090";
  89. Cannon="http://www.roblox.com/asset/?id=2920959";
  90. Bash="http://www.roblox.com/asset/?id=25270310";
  91. Suirize="http://roblox.com/asset/?id=10209605";
  92. Heli="http://www.roblox.com/asset/?id=27112125";
  93. }
  94. --Decals
  95. local Decals={
  96. Slash="http://www.roblox.com/asset/?id=25539335";
  97. }
  98. --MeshIds
  99. local Meshes={
  100. Charge="http://www.roblox.com/asset/?id=20329976";
  101. Noob="http://www.roblox.com/asset/?id=29515710";
  102. Ring="http://www.roblox.com/asset/?id=3270017";
  103. Crown="http://www.roblox.com/asset/?id=1323306";
  104. Spring="http://www.roblox.com/Asset/?id=9753878";
  105. Sword="rbxasset://fonts/sword.mesh";
  106. Shield="http://www.roblox.com/asset/?id=50798797";
  107. }
  108. ------------------------CreateParts------------------------
  109. body.Torso=add.Part(model2, false, false, skincolor, 1, Vector3.new(2, 2, 1), nil)
  110. body.TorsoW=add.Weld(body.Torso, torso, nil)
  111. function createParts()
  112. for i, v in pairs(char:children()) do if v:isA("CharacterMesh") then v:remove() end end
  113. torso.Transparency=1 body.Torso.Transparency=0
  114. --Parts--
  115. gui.Parent=player.PlayerGui
  116. body.Head=add.Part(model, false, false, skincolor, 1, Vector3.new(1, 1, 1), nil)
  117. body.LA, body.RA=add.Part(model, false, false, skincolor, 1, Vector3.new(1, 1, 1), nil), add.Part(model, false, false, skincolor, 1, Vector3.new(1, 1, 1), nil)
  118. body.LL, body.RL=add.Part(model, false, false, skincolor, 1, Vector3.new(1, 1, 1), nil), add.Part(model, false, false, skincolor, 1, Vector3.new(1, 1, 1), nil)
  119.  
  120. --Welds--
  121. body.HeadW=add.Weld(body.Head, body.Torso, CFrame.new(0, 1.5, 0))
  122. body.LAW, body.RAW=add.Weld(body.LA, body.Torso, CFrame.new(-1.5, .5, 0)), add.Weld(body.RA, body.Torso, CFrame.new(1.5, .5, 0))
  123. body.LLW, body.RLW=add.Weld(body.LL, body.Torso, CFrame.new(-.5, -1.5, 0)), add.Weld(body.RL, body.Torso, CFrame.new(.5, -1.5, 0))
  124.  
  125. --Welds2--
  126. add.Weld(body.Head, head, nil)
  127. add.Weld(LA, body.LA, CFrame.new(0, -.5, 0))
  128. add.Weld(RA, body.RA, CFrame.new(0, -.5, 0))
  129. LH.Part0=body.Torso
  130. RH.Part0=body.Torso
  131.  
  132.  
  133.  
  134.  
  135. --Animation--
  136. animate={
  137. ["Head"]=function(cf)
  138. body.HeadW.C1=CFrame.new(0, 1.5, 0)*cf
  139. end;
  140. ["Torso"]=function(cf)
  141. body.TorsoW.C1=(cf or CFrame.new()*CFrame.Angles(0, 0, 0))
  142. end;
  143. ["LA"]=function(cf)
  144. body.LAW.C1=CFrame.new(-1.5, .5, 0)*(cf or CFrame.new()*CFrame.Angles(0, 0, 0))
  145. end;
  146. ["RA"]=function(cf)
  147. body.RAW.C1=CFrame.new(1.5, .5, 0)*(cf or CFrame.new()*CFrame.Angles(0, 0, 0))
  148. end;
  149. ["LL"]=function(cf)
  150. LLW=add.Weld(LL, body.LL, CFrame.new(0, -1, 0))
  151. body.LLW.C1=CFrame.new(-.5, -1, 0)*(cf or CFrame.new()*CFrame.Angles(0, 0, 0))
  152. c(function()
  153. wait()
  154. LLW:remove()
  155. end)
  156. end;
  157. ["RL"]=function(cf)
  158. RLW=add.Weld(RL, body.RL, CFrame.new(0, -1, 0))
  159. body.RLW.C1=CFrame.new(.5, -1, 0)*(cf or CFrame.new()*CFrame.Angles(0, 0, 0))
  160. c(function()
  161. wait()
  162. RLW:remove()
  163. end)
  164. end;
  165. }
  166. --GuiLabels--
  167. obj.AL=add.Gui("TextLabel", gui, "Really black", "Really black", "White", "Size18", "Attack(Click)", 0, UDim2.new(0, 150, 0, 50), UDim2.new(0, 0, 0, 150))
  168. obj.AL2=add.Gui("TextLabel", obj.AL, "Really black", "Really black", "White", "Size18", "Block(F)", 0, UDim2.new(1, 0, 1, 0), UDim2.new(0, 0, 1, 0))
  169. obj.AL3=add.Gui("TextLabel", obj.AL2, "Really black", "Really black", "White", "Size18", "Smash(Q)", 0, UDim2.new(1, 0, 1, 0), UDim2.new(0, 0, 1, 0))
  170. obj.AL4=add.Gui("TextLabel", obj.AL3, "Really black", "Really black", "White", "Size18", "WinterSpike(E)", 0, UDim2.new(1, 0, 1, 0), UDim2.new(0, 0, 1, 0))
  171. obj.AL5=add.Gui("TextLabel", obj.AL4, "Really black", "Really black", "White", "Size18", "Blast(R)", 0, UDim2.new(1, 0, 1, 0), UDim2.new(0, 0, 1, 0))
  172. obj.AL6=add.Gui("TextLabel", obj.AL5, "Really black", "Really black", "White", "Size18", "WinterBoard(Z)", 0, UDim2.new(1, 0, 1, 0), UDim2.new(0, 0, 1, 0))
  173. --WeaponDesgin--
  174. for i, v in pairs(model2:children()) do
  175. if i~=1 then return end
  176. end
  177. obj.H=add.Part(model2, false, false, colorSet.Handle, 0, Vector3.new(.2, 5, .2))
  178. obj.HM=add.Mesh("CylinderMesh", obj.H)
  179. obj.HW=add.Weld(obj.H, torso, CFrame.new(0, 0, .5)*CFrame.Angles(0, 0, -math.rad(45)))
  180. obj.Extra=add.Part(model2, false, false, colorSet.Handle, 0, Vector3.new(.2, 1.5, .2))
  181. obj.ExtraM=add.Mesh("CylinderMesh", obj.Extra)
  182. obj.ExtraW=add.Weld(obj.Extra, obj.H, CFrame.new(0, 2.6, .5)*CFrame.Angles(math.rad(45), 0, 0))
  183. obj.Con=add.Part(model2, false, false, colorSet.Handle, 0, Vector3.new(.25, .25, .25))
  184. obj.ConM=add.Mesh("SpecialMesh", obj.Con, nil, nil, "Sphere")
  185. obj.ConW=add.Weld(obj.Con, obj.Extra, CFrame.new(0, .75, 0))
  186. obj.Extra=add.Part(model2, false, false, colorSet.Handle, 0, Vector3.new(.2, 1.5, .2))
  187. obj.ExtraM=add.Mesh("CylinderMesh", obj.Extra)
  188. obj.ExtraW=add.Weld(obj.Extra, obj.H, CFrame.new(0, 3.8, 1))
  189. obj.Con=add.Part(model2, false, false, colorSet.Handle, 0, Vector3.new(.25, .25, .25))
  190. obj.ConM=add.Mesh("SpecialMesh", obj.Con, nil, nil, "Sphere")
  191. obj.ConW=add.Weld(obj.Con, obj.Extra, CFrame.new(0, .75, 0))
  192. obj.Extra=add.Part(model2, false, false, colorSet.Handle, 0, Vector3.new(.2, 1.5, .2))
  193. obj.ExtraM=add.Mesh("CylinderMesh", obj.Extra)
  194. obj.ExtraW=add.Weld(obj.Extra, obj.H, CFrame.new(0, 5, .5)*CFrame.Angles(-math.rad(45), 0, 0))
  195. obj.Con=add.Part(model2, false, false, colorSet.Handle, 0, Vector3.new(.25, .25, .25))
  196. obj.ConM=add.Mesh("SpecialMesh", obj.Con, nil, nil, "Sphere")
  197. obj.ConW=add.Weld(obj.Con, obj.Extra, CFrame.new(0, .75, 0))
  198. obj.Extra=add.Part(model2, false, false, colorSet.Handle, 0, Vector3.new(.2, 1.5, .2))
  199. obj.ExtraM=add.Mesh("CylinderMesh", obj.Extra)
  200. obj.ExtraW=add.Weld(obj.Extra, obj.H, CFrame.new(0, 5, -.5)*CFrame.Angles(math.rad(45), 0, 0))
  201. obj.H2=add.Part(model2, false, false, colorSet.Extra, 0, Vector3.new(.2, 5, .2))
  202. obj.H2M=add.Mesh("SpecialMesh", obj.H2, Vector3.new(.5, 5, .5), nil, "File", Meshes.Spring)
  203. obj.H2W=add.Weld(obj.H2, obj.H)
  204. end
  205. ------------------------Functions------------------------
  206. function removeParts()
  207. pcall(function()
  208. if torso then
  209. LS.Part0=torso
  210. RS.Part0=torso LH.Part0=torso
  211. RH.Part0=torso
  212. torso.Transparency=0
  213. body.Torso.Transparency=1
  214. end
  215. player.PlayerGui[modelName]:remove()
  216. for i, v in pairs(model:children()) do
  217. v:remove()
  218. end
  219. end)
  220. end
  221. function play(soundid, pitch, vol)
  222. local sound=add.Sound(workspace, soundid, pitch or 1, volume or 1)
  223. sound:play()
  224. s(function() wait(5) sound:remove() end)
  225. end
  226. function fade(part, incr)
  227. if part:isA("BasePart") then
  228. for i=part.Transparency, 1, incr do wait() part.Transparency=i end
  229. elseif part:isA("Model") then
  230. for i, v in pairs(part:children() or part) do
  231. if v:isA("BasePart") then
  232. for i=part.Transparency, 1, incr do wait() v.Transparency=i end
  233. end
  234. end
  235. end
  236. end
  237. function appear(part, incr)
  238. if part:isA("BasePart") then
  239. for i=part.Transparency, 0, -incr do wait() part.Transparency=i end
  240. elseif part:isA("Model") then
  241. for i, v in pairs(part:children() or part) do
  242. if v:isA("BasePart") then
  243. for i=part.Transparency, 0, -incr do wait() v.Transparency=i end
  244. end
  245. end
  246. end
  247. end
  248. function computePos(pos, pos2)
  249. local pos3=Vector3.new(pos2.x, pos.y, pos2.z)
  250. return CFrame.new(pos, pos3)
  251. end
  252. function rayCast(pos, dir, max, ingore)
  253. return workspace:findPartOnRay(Ray.new(pos, dir.unit*(max or 9999)), ignore)
  254. end
  255. function nearPos(pos, dis)
  256. local temp
  257. local distance=dis
  258. for i, v in pairs(workspace:children()) do
  259. if v:isA("Model") then
  260. temp=v:findFirstChild("Torso")
  261. local humanoid=v:findFirstChild("Humanoid")
  262. if temp and humanoid and v~=char and (temp.CFrame.p-pos).magnitude<distance then
  263. distance=(temp.CFrame.p-pos).magnitude
  264. return temp.Parent
  265. end
  266. end
  267. end
  268. end
  269. function lightningGen(startPos, endPos, col)
  270. local magnitude=(startPos-endPos).magnitude
  271. local distance=(startPos+endPos)/2
  272. local pattern=add.Part(workspace, true, false, "White", 1, Vector3.new(.2, .2, magnitude), CFrame.new(distance, startPos))
  273. local startPosProx=startPos
  274. for i=1, 9 do
  275. local startPosProx2=startPosProx local random=Vector3.new(math.random(-1, 1), math.random(-1, 1), math.random(-1, 1))
  276. local findSize=pattern.Size.z/10 local findOffSet=pattern.CFrame.lookVector*-1
  277. local compute=i*findSize*findOffSet local newStartPos=startPos
  278. local newEndPos=CFrame.new(random+compute+newStartPos).p
  279. local magnitude=(startPosProx2-newEndPos).magnitude
  280. local distance=(startPosProx2+newEndPos)/2
  281. local lightning=add.Part(workspace, true, false, col or "Bright yellow", 0, Vector3.new(.2, .2, magnitude), CFrame.new(distance, startPosProx2))
  282. s(function()
  283. fade(lightning, .1) lightning:remove()
  284. end)
  285. startPosProx=newEndPos
  286. end
  287. pattern:remove()
  288. end
  289. function trail(pos, cf, col, thick)
  290. onTrail=true
  291. s(function()
  292. local old=(pos.CFrame*(cf or CFrame.new())).p
  293. while onTrail do wait()
  294. local new=(pos.CFrame*(cf or CFrame.new())).p
  295. local mag=(old-new).magnitude
  296. local dis=(old+new)/2 local trail=add.Part(char, true, false, col or "White", 0, Vector3.new(1, mag, 1), CFrame.new(dis, new)*CFrame.Angles(math.pi/2, 0, 0))
  297. trail.Name="Effect" local tMesh=add.Mesh("CylinderMesh", trail, Vector3.new(thick or 1, 1, thick or 1), nil, nil)
  298. old=new
  299. s(function()
  300. for i=1, 0, -.1 do wait() tMesh.Scale=tMesh.Scale*Vector3.new(i, 1, i) end trail:remove()
  301. end)
  302. s(function()
  303. fade(trail, .1)
  304. end)
  305. end
  306. end)
  307. end
  308. function stickHit(from, to)
  309. local stickW=add.Weld(from, to, to.CFrame:inverse()*from.CFrame)
  310. stickW.C0=from.CFrame:inverse()*from.CFrame
  311. return stickW
  312. end
  313. function glowMesh(prt, size, speed)
  314. local glow=prt:clone() add.Weld(prt, glow)
  315. glow.Parent=workspace
  316. glow.Anchored=false
  317. glow.CanCollide=false
  318. for i, v in pairs(glow:children()) do
  319. if v:isA("SpecialMesh") or v:isA("BlockMesh") or v:isA("CylinderMesh") then
  320. s(function()
  321. for i=0, size, speed do wait() v.Scale=v.Scale+Vector3.new(i, i, i) end
  322. end)
  323. s(function()
  324. fade(glow, .1) glow:remove()
  325. end)
  326. end
  327. end
  328. end
  329. function charge(prt, cf, col, start, endval, incr)
  330. local aura=add.Part(workspace, false, false, col or "Bright yellow", 0, Vector3.new(1, 1, 1), cf or torso.CFrame)
  331. local auraM=add.Mesh("SpecialMesh", aura, Vector3.new(start, .5, start), nil, "File") auraM.MeshId=Meshes.Charge
  332. add.Weld(aura, prt or torso, cf*CFrame.Angles(0, math.rad(math.random(-45, 45)), 0))
  333. s(function()
  334. for i=start, endval, incr do wait()
  335. auraM.Scale=Vector3.new(i, auraM.Scale.y, i)
  336. end
  337. aura:remove()
  338. end)
  339. s(function()
  340. fade(aura, .1)
  341. end)
  342. end
  343. function makeCircle(prt, prts, dis, incr)
  344. local radius=dis+(prts+incr)
  345. for i=1, prts do
  346. local prt2=prt:clone()
  347. prt2.Parent=model
  348. local x = math.sin((360/prts + 360/prts*i)/(180/math.pi))*radius
  349. local y = 0
  350. local z = math.cos((360/prts + 360/prts*i)/(180/math.pi))*radius
  351. prt2.CFrame=prt.CFrame:toWorldSpace(CFrame.new(x,y,z))
  352. prt:remove()
  353. return prt2
  354. end
  355. end
  356. function antiExplosion(model)
  357. local ffs={}
  358. for i, v in pairs(model:children()) do
  359. pcall(function()
  360. local ff2=Instance.new("ForceField", v.Handle)
  361. table.insert(ffs, ff2) end)
  362. if v:isA("BasePart") then
  363. local ff=Instance.new("ForceField", v)
  364. table.insert(ffs, ff)
  365. end
  366. end
  367. return ffs
  368. end
  369. function dmgHit(prt)
  370. prt.Touched:connect(function(h)
  371. if onKey==true and h.Parent:findFirstChild("Humanoid") and onHit==false and h.Parent~=char then
  372. onHit=true
  373. local fakeM=Instance.new("Model", workspace)
  374. fakeM.Name=-dmg
  375. local hHuman=h.Parent:findFirstChild("Humanoid")
  376. hHuman.Health=hHuman.Health-dmg
  377. local hTorso=h.Parent:findFirstChild("Torso")
  378. local fakeH=Instance.new("Humanoid", fakeM) fakeH.MaxHealth=0 fakeH.Health=0
  379. local label=add.Part(fakeM, true, false, "Bright red", 0, Vector3.new(.5, .5, .5), h.CFrame*CFrame.new(math.random(-4, 4), 4, math.random(-4, 4))) label.Name="Head"
  380. --Freeze
  381. play(Sounds.Abscond, 1, 1)
  382. local f=add.Part(workspace, true, false, "Cyan", .5, Vector3.new(6, 6, 6), hTorso.CFrame) hTorso.Anchored=true
  383. s(function() for i=.5, 1, .01 do wait() f.Transparency=i end f:remove() hTorso.Anchored=false end)
  384. game.Debris:addItem(fakeM, 1)
  385. wait(.1)
  386. onHit=false
  387. end
  388. end)
  389. end
  390. function blockHit(prt)
  391. prt.Touched:connect(function(h)
  392. if onKey==true and not h.Parent:findFirstChild("Humanoid") and onHit==false and h.Parent~=char then
  393. onHit=true
  394. play(Sounds.Hit, 1, 1)
  395. print'Blocked'
  396. local bp=Instance.new("BodyPosition", h) bp.maxForce=Vector3.new(math.huge, math.huge, math.huge) bp.position=(CFrame.new(torso.CFrame.p, h.CFrame.p)*CFrame.new(0, 0, -math.random(100, 200))).p
  397. local bg=Instance.new("BodyGyro", h) bg.maxTorque=Vector3.new(math.huge, math.huge, math.huge) bg.cframe=CFrame.new(h.CFrame.p, torso.CFrame.p)
  398. game.Debris:addItem(bp, .2) game.Debris:addItem(bg, .2)
  399. wait(.1)
  400. onHit=false
  401. end
  402. end)
  403. end
  404. function idle()
  405. animate.LA(CFrame.Angles(-math.rad(15), 0, -math.rad(15)))
  406. animate.RA(CFrame.Angles(math.rad(15), 0, math.rad(15)))
  407. end
  408. function Smash()
  409. humanoid.WalkSpeed=0
  410. for i=0, 1, .1 do wait()
  411. animate.Torso(CFrame.new(0, 5*i, 0))
  412. animate.LA(CFrame.new(.5*i, 1*i, -.5*i)*CFrame.Angles(math.rad(135)*i, 0, math.rad(45)*i))
  413. animate.RA(CFrame.new(-.5*i, 1*i, -.5*i)*CFrame.Angles(math.rad(135)*i, 0, -math.rad(45)*i))
  414. obj.HW.C1=CFrame.new(0, -1, 0)*CFrame.Angles(-math.pi/2, -math.rad(45)*i, 0)
  415. end
  416. play(Sounds.Cannon, .3, 1)
  417. for i=0, 1, .2 do wait()
  418. animate.Torso(CFrame.new(0, 5-6*i, 0))
  419. animate.LA(CFrame.new(.5, 1-1.5*i, -.5)*CFrame.Angles(math.rad(135-45*i), 0, math.rad(45)))
  420. animate.RA(CFrame.new(-.5, 1-1.5*i, -.5)*CFrame.Angles(math.rad(135-45*i), 0, -math.rad(45)))
  421. animate.LL(CFrame.Angles(-math.rad(90)*i, 0, 0))
  422. animate.RL(CFrame.new(0, 1*i, -1*i))
  423. obj.HW.C1=CFrame.new(0, -1, 0)*CFrame.Angles(-math.pi/2, -math.rad(45), 0)
  424. end
  425. local b=add.Part(workspace, true, false, "Cyan", .5, Vector3.new(80, 80, 80), torso.CFrame*CFrame.new(0, -3, 0)*CFrame.Angles(-math.rad(90), 0, 0)+torso.CFrame.lookVector*1.5)
  426. local bM=add.Mesh("SpecialMesh", b, Vector3.new(1, 1, 1), nil, nil, Meshes.Ring)
  427. local b2=add.Part(workspace, true, false, "Cyan", .5, Vector3.new(80, 80, 80), torso.CFrame*CFrame.new(0, -3, 0)+torso.CFrame.lookVector*1.5)
  428. local b2M=add.Mesh("SpecialMesh", b2, Vector3.new(1, 2, 1), nil, nil, Meshes.Crown)
  429. dmgHit(b) dmgHit(b2)
  430. s(function()
  431. for i=1, 80, 2 do wait()
  432. bM.Scale=Vector3.new(i, i, i)
  433. b2M.Scale=Vector3.new(i, 2, i)
  434. end
  435. b:remove() b2:remove()
  436. end)
  437. for i=1, 0, -.1 do wait()
  438. animate.Torso(CFrame.new(0, -1*i, 0))
  439. animate.LA(CFrame.new(.5*i, -.5*i, -.5*i)*CFrame.Angles(math.rad(90*i), 0, math.rad(45)*i))
  440. animate.RA(CFrame.new(-.5*i, -.5*i, -.5*i)*CFrame.Angles(math.rad(90*i), 0, -math.rad(45)*i))
  441. animate.LL(CFrame.Angles(-math.rad(90)*i, 0, 0))
  442. animate.RL(CFrame.new(0, 1*i, -1*i))
  443. obj.HW.C1=CFrame.new(0, -1, 0)*CFrame.Angles(-math.pi/2, -math.rad(45)*i, 0)
  444. end
  445. humanoid.WalkSpeed=16
  446. idle()
  447. end
  448. function WinterSpike()
  449. humanoid.WalkSpeed=0
  450. local bg=Instance.new("BodyGyro", torso) bg.maxTorque=Vector3.new(math.huge, math.huge, math.huge) bg.D=100
  451. for i=0, 1, .05 do wait()
  452. play(Sounds.Suirize, 1, 1)
  453. bg.cframe=computePos(torso.CFrame.p, mouse.Hit.p)
  454. animate.RA(CFrame.Angles(math.rad(180)*i, 0, 0))
  455. local b=add.Part(workspace, true, false, "Cyan", .5, Vector3.new(10, 10, 10), torso.CFrame*CFrame.new(0, -3, 0)*CFrame.Angles(-math.rad(90), 0, 0)+torso.CFrame.lookVector*(120*i))
  456. local bM=add.Mesh("SpecialMesh", b, Vector3.new(10, 10, 10), nil, nil, Meshes.Ring)
  457. local b2=add.Part(workspace, true, false, "Cyan", .5, Vector3.new(10, 10, 10), torso.CFrame*CFrame.new(0, -3, 0)+torso.CFrame.lookVector*(120*i))
  458. local b2M=add.Mesh("SpecialMesh", b2, Vector3.new(1, 2, 1), nil, nil, Meshes.Crown)
  459. local b3=add.Part(workspace, true, false, "Cyan", .5, Vector3.new(1, .8, 4), torso.CFrame*CFrame.new(0, -3, 0)*CFrame.Angles(-math.rad(90), 0, 0)+torso.CFrame.lookVector*(120*i))
  460. local b3M=add.Mesh("SpecialMesh", b3, Vector3.new(1, 1, 1), nil, nil, Meshes.Sword)
  461. dmgHit(b) dmgHit(b2) dmgHit(b3)
  462. s(function()
  463. for i=1, 10, .5 do wait()
  464. b2M.Scale=Vector3.new(i, 2, i)
  465. b3.CFrame=b3.CFrame*CFrame.new(0, 0, i/20)
  466. end
  467. b:remove() b2:remove() b3:remove()
  468. end)
  469. end
  470. bg:remove()
  471. for i=1, 0, -.1 do wait()
  472. animate.RA(CFrame.Angles(math.rad(180)*i, 0, 0))
  473. end
  474. humanoid.WalkSpeed=16
  475. idle()
  476. end
  477. function Blast()
  478. humanoid.WalkSpeed=0
  479. local bg=Instance.new("BodyGyro", torso) bg.maxTorque=Vector3.new(math.huge, math.huge, math.huge) bg.D=100
  480. for i=0, 1, .1 do wait()
  481. animate.Torso(CFrame.Angles(0, math.rad(45)*i, 0))
  482. animate.Head(CFrame.Angles(0, -math.rad(45)*i, 0))
  483. animate.RA(CFrame.Angles(math.rad(45)*i, 0, math.rad(45)*i))
  484. obj.HW.C1=CFrame.new(0, -1, 0)*CFrame.Angles(-math.rad(90+45*i), 0, 0)
  485. end
  486. local pressure=0
  487. play(Sounds.Heli, .5, 1)
  488. if pressure>50 then onHold=false end
  489. while onHold do wait(.1)
  490. pressure=pressure+.1
  491. dmg=dmg+.5
  492. local ss=add.Part(workspace, true, false, "Cyan", 0, Vector3.new(pressure, pressure, pressure), torso.CFrame+torso.CFrame.lookVector*10)
  493. local ssM=add.Mesh("SpecialMesh", ss, nil, nil, "Sphere")
  494. local e=add.Part(workspace, false, false, "Cyan", 0, Vector3.new(2, 2, 2), ss.CFrame*CFrame.new(math.random(-pressure-10, pressure+10), math.random(-pressure-10, pressure+10), math.random(-pressure-10, pressure+10))*CFrame.Angles(math.rad(math.random(-45, 45)), math.rad(math.random(-45, 45)), math.rad(math.random(-45, 45))))
  495. local bp=Instance.new("BodyPosition", e) bp.maxForce=Vector3.new(math.huge, math.huge, math.huge) bp.position=ss.Position
  496. s(function()
  497. for i=0, 1, .1 do wait()
  498. ss.Transparency=i
  499. e.Transparency=i
  500. end
  501. ss:remove() e:remove()
  502. end)
  503. bg.cframe=computePos(torso.CFrame.p, mouse.Hit.p)
  504. end
  505. local ss=add.Part(workspace, false, false, "Cyan", .5, Vector3.new(pressure, pressure, pressure), torso.CFrame+torso.CFrame.lookVector*10)
  506. local ssM=add.Mesh("SpecialMesh", ss, nil, nil, "Sphere")
  507. trail(ss, nil, "Cyan", pressure)
  508. local bf=Instance.new("BodyForce", ss) bf.force=Vector3.new(0, ss:getMass()*196.25, 0)
  509. local bv=Instance.new("BodyVelocity", ss) bv.maxForce=bv.maxForce*math.huge bv.velocity=ss.CFrame.lookVector*100
  510. ss.Touched:connect(function(h)
  511. if h.Parent:findFirstChild("Humanoid") and onHit==false and h.Parent~=char then
  512. onHit=true
  513. local fakeM=Instance.new("Model", workspace)
  514. fakeM.Name=-dmg
  515. local hHuman=h.Parent:findFirstChild("Humanoid")
  516. hHuman.Health=hHuman.Health-dmg
  517. local hTorso=h.Parent:findFirstChild("Torso")
  518. local fakeH=Instance.new("Humanoid", fakeM) fakeH.MaxHealth=0 fakeH.Health=0
  519. local label=add.Part(fakeM, true, false, "Bright red", 0, Vector3.new(.5, .5, .5), h.CFrame*CFrame.new(math.random(-4, 4), 4, math.random(-4, 4))) label.Name="Head"
  520. --Freeze
  521. play(Sounds.Abscond, 1, 1)
  522. local f=add.Part(workspace, true, false, "Cyan", .5, Vector3.new(6, 6, 6), hTorso.CFrame) hTorso.Anchored=true
  523. s(function() for i=.5, 1, .01 do wait() f.Transparency=i end f:remove() hTorso.Anchored=false end)
  524. game.Debris:addItem(fakeM, 1)
  525. wait(.1)
  526. onHit=false
  527. end
  528. end)
  529. s(function() wait(5) onTrail=false ss:remove() dmg=math.random(10, 15) end)
  530. bg:remove()
  531. for i=1, 0, -.1 do wait()
  532. animate.Torso(CFrame.Angles(0, math.rad(45)*i, 0))
  533. animate.Head(CFrame.Angles(0, -math.rad(45)*i, 0))
  534. animate.RA(CFrame.Angles(math.rad(45)*i, 0, math.rad(45)*i))
  535. obj.HW.C1=CFrame.new(0, -1, 0)*CFrame.Angles(-math.rad(90+45*i), 0, 0)
  536. end
  537. humanoid.WalkSpeed=16
  538. idle()
  539. end
  540. function Block()
  541. for i=0, 1, .1 do wait()
  542. animate.Torso(CFrame.Angles(0, math.rad(45)*i, 0))
  543. animate.Head(CFrame.Angles(0, -math.rad(45)*i, 0))
  544. animate.RA(CFrame.Angles(math.rad(45)*i, 0, math.rad(45)*i))
  545. obj.HW.C1=CFrame.new(0, -1, 0)*CFrame.Angles(-math.rad(90+45*i), 0, 0)
  546. end
  547. local bg=Instance.new("BodyGyro", torso) bg.maxTorque=Vector3.new(math.huge, math.huge, math.huge) bg.D=100
  548. local cf=torso.CFrame*CFrame.Angles(-math.rad(90), 0, 0)+torso.CFrame.lookVector*8
  549. local shield=add.Part(workspace, false, true, "Cyan", .2, Vector3.new(4, 4, 4.5), cf)
  550. local shieldM=add.Mesh("SpecialMesh", shield, shield.Size, nil, nil, Meshes.Shield)
  551. local shieldW=add.Weld(shield, torso, CFrame.Angles(-math.rad(90), 0, 0)*CFrame.new(0, 8, 0))
  552. blockHit(shield)
  553. s(function()
  554. while onBlock do wait()
  555. bg.cframe=computePos(torso.CFrame.p, mouse.Hit.p)
  556. end
  557. end)
  558. while onBlock do wait(.5)
  559. glowMesh(shield, 1, .1)
  560. end
  561. wait(.5)
  562. shield:remove()
  563. bg:remove()
  564. for i=1, 0, -.1 do wait()
  565. animate.Torso(CFrame.Angles(0, math.rad(45)*i, 0))
  566. animate.Head(CFrame.Angles(0, -math.rad(45)*i, 0))
  567. animate.RA(CFrame.Angles(math.rad(45)*i, 0, math.rad(45)*i))
  568. obj.HW.C1=CFrame.new(0, -1, 0)*CFrame.Angles(-math.rad(90+45*i), 0, 0)
  569. end
  570. idle()
  571. end
  572. function WinterBoard()
  573. for i=0, 1, .1 do wait()
  574. animate.Torso(CFrame.Angles(0, math.rad(45)*i, 0))
  575. animate.Head(CFrame.Angles(0, -math.rad(45)*i, 0))
  576. animate.RA(CFrame.Angles(math.rad(45)*i, 0, math.rad(45)*i))
  577. obj.HW.C1=CFrame.new(0, -1, 0)*CFrame.Angles(-math.rad(90+45*i), 0, 0)
  578. end
  579. local flyboard=Instance.new("Model", char) flyboard.Name="WinterBoard"
  580. obj.Board=add.Part(flyboard, false, false, "Cyan", 0, Vector3.new(2, .5, 4))
  581. obj.BoardW=add.Weld(obj.Board, torso, CFrame.new(0, -3, 0))
  582. obj.W=add.Wedge(flyboard, false, false, "Cyan", 0, Vector3.new(.5, 4, 1))
  583. obj.WW=add.Weld(obj.W, obj.Board, CFrame.new(-1.5, 0, 0)*CFrame.Angles(0, math.pi/2, -math.pi/2))
  584. obj.W=add.Wedge(flyboard, false, false, "Cyan", 0, Vector3.new(.5, 4, 1))
  585. obj.WW=add.Weld(obj.W, obj.Board, CFrame.new(1.5, 0, 0)*CFrame.Angles(0, -math.pi/2, math.pi/2))
  586. obj.W=add.Wedge(flyboard, false, false, "Cyan", 0, Vector3.new(.5, 2, 1))
  587. obj.WW=add.Weld(obj.W, obj.Board, CFrame.new(-1, 0, 2.5)*CFrame.Angles(0, math.pi, -math.pi/2))
  588. obj.W=add.Wedge(flyboard, false, false, "Cyan", 0, Vector3.new(.5, 2, 1))
  589. obj.WW=add.Weld(obj.W, obj.Board, CFrame.new(1, 0, 2.5)*CFrame.Angles(0, math.pi, math.pi/2))
  590. obj.S=add.Part(flyboard, false, false, "Cyan", 0, Vector3.new(.5, .5, .5))
  591. obj.SM=add.Mesh("CylinderMesh", obj.S)
  592. obj.SW=add.Weld(obj.S, obj.Board, CFrame.new(1, 0, 2.5)*CFrame.Angles(math.pi/2, 0, 0))
  593. obj.S2=add.Part(flyboard, false, false, "Cyan", 0, Vector3.new(.5, .5, .5))
  594. obj.S2M=add.Mesh("CylinderMesh", obj.S2)
  595. obj.S2W=add.Weld(obj.S2, obj.Board, CFrame.new(-1, 0, 2.5)*CFrame.Angles(math.pi/2, 0, 0))
  596. obj.sS=add.Part(flyboard, false, false, "White", 0, Vector3.new(.45, .55, .45))
  597. obj.sSM=add.Mesh("CylinderMesh", obj.sS)
  598. obj.sSW=add.Weld(obj.sS, obj.Board, CFrame.new(1, 0, 2.5)*CFrame.Angles(math.pi/2, 0, 0))
  599. obj.sS2=add.Part(flyboard, false, false, "White", 0, Vector3.new(.45, .55, .45))
  600. obj.sS2M=add.Mesh("CylinderMesh", obj.sS2)
  601. obj.sS2W=add.Weld(obj.sS2, obj.Board, CFrame.new(-1, 0, 2.5)*CFrame.Angles(math.pi/2, 0, 0))
  602. trail(obj.S, nil, "Cyan", .5)
  603. trail(obj.S2, nil, "Cyan", .5)
  604. local bg=Instance.new("BodyGyro", torso) bg.maxTorque=Vector3.new(math.huge, math.huge, math.huge) bg.D=500
  605. local bv=Instance.new("BodyVelocity", torso) bv.maxForce=bv.maxForce*math.huge
  606. while onHold do wait()
  607. bv.velocity=torso.CFrame.lookVector*50
  608. bg.cframe=mouse.Hit*CFrame.Angles(0, 0, torso.RotVelocity.y*.5)
  609. end
  610. bg:remove() bv:remove()
  611. flyboard:remove()
  612. onTrail=false
  613. for i=1, 0, -.1 do wait()
  614. animate.Torso(CFrame.Angles(0, math.rad(45)*i, 0))
  615. animate.Head(CFrame.Angles(0, -math.rad(45)*i, 0))
  616. animate.RA(CFrame.Angles(math.rad(45)*i, 0, math.rad(45)*i))
  617. obj.HW.C1=CFrame.new(0, -1, 0)*CFrame.Angles(-math.rad(90+45*i), 0, 0)
  618. end
  619. idle()
  620. end
  621. function keyDown(key)
  622. local key=key:lower()
  623. if key=="q" and not onKey then
  624. onKey=true
  625. Smash()
  626. onKey=false
  627. end
  628. if key=="e" and not onKey then
  629. onKey=true
  630. WinterSpike()
  631. onKey=false
  632. end
  633. if key=="r" and not onKey then
  634. onKey=true onHold=true
  635. Blast()
  636. onKey=false
  637. end
  638. if key=="f" and not onKey then
  639. onKey=true onBlock=true
  640. Block()
  641. onKey=false
  642. end
  643. if key=="z" and not onKey then
  644. onKey=true onHold=true
  645. WinterBoard()
  646. onKey=false
  647. end
  648. end
  649. function keyUp(key)
  650. local key=key:lower()
  651. if key=="r" and onKey and onHold then onHold=false end
  652. if key=="f" and onKey and onBlock then onBlock=false end
  653. if key=="z" and onKey and onHold then onHold=false end
  654. end
  655. bin.Selected:connect(function(m)
  656. onKey=false
  657. mouse=m
  658. createParts()
  659. for i=0, 1, .1 do wait()
  660. animate.RA(CFrame.Angles(-math.rad(25)*i, 0, -math.rad(45)*i))
  661. end
  662. obj.HW.Part1=RA
  663. obj.HW.C1=CFrame.new(0, -1, 0)*CFrame.Angles(-math.pi/2, 0, 0)
  664. for i=1, 0, -.1 do wait()
  665. animate.RA(CFrame.Angles(-math.rad(25)*i, 0, -math.rad(45)*i))
  666. end
  667. mouse.KeyDown:connect(keyDown)
  668. mouse.KeyUp:connect(keyUp)
  669. idle()
  670. end)
  671. bin.Deselected:connect(function()
  672. for i=0, 1, .1 do wait()
  673. animate.RA(CFrame.Angles(-math.rad(25)*i, 0, -math.rad(45)*i))
  674. end
  675. obj.HW.Part1=torso
  676. obj.HW.C1=CFrame.new(0, 0, .5)*CFrame.Angles(0, 0, -math.rad(45))
  677. for i=1, 0, -.1 do wait()
  678. animate.RA(CFrame.Angles(-math.rad(25)*i, 0, -math.rad(45)*i))
  679. end
  680. removeParts()
  681. end)
  682. --mediafire?
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement