Advertisement
Freightus2

Winter Conjurer Leak Void Script Builder

May 6th, 2019
420
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 58.41 KB | None | 0 0
  1. 500 looks.
  2. In under 30 minutes, I get 500 looks. I don't know how this possible, thank you so much.
  3. Since you've all enjoyed my pastes so much, I'll give you another.
  4. Here, enjoy the Winter Conjurer script!
  5. -- FE template created by MintyLatios (V3rm) aka Drahazar (ROBLOX)
  6. local username = "Drahazar"
  7.  
  8. if(script:FindFirstChild'Owner')then
  9. repeat wait() until script.Owner.Value
  10. end
  11. function GetPlr(user)
  12. for _,v in next, game:service'Players':players() do
  13. if(v.Name==user)then
  14. return v
  15. end
  16. end
  17. return nil
  18. end
  19.  
  20. local Player = (script:FindFirstChild'Owner' and script:FindFirstChild'Owner'.Value or GetPlr(username))
  21. pcall(game.Destroy,script:FindFirstChild'Owner')
  22. local FakeMouse = script.FakeMouse:Clone();
  23. FakeMouse.Parent = Player.Character;
  24. script.FakeMouse:Destroy()
  25. do
  26. local GUID = {}
  27. do
  28. GUID.IDs = {};
  29. function GUID:new(len)
  30. local id;
  31. if(not len)then
  32. id = (tostring(function() end))
  33. id = id:gsub("function: ","")
  34. else
  35. local function genID(len)
  36. local newID = ""
  37. for i = 1,len do
  38. newID = newID..string.char(math.random(48,90))
  39. end
  40. return newID
  41. end
  42. repeat id = genID(len) until not GUID.IDs[id]
  43. local oid = id;
  44. id = {Trash=function() GUID.IDs[oid]=nil; end;Get=function() return oid; end}
  45. GUID.IDs[oid]=true;
  46. end
  47. return id
  48. end
  49. end
  50.  
  51. local AHB = Instance.new("BindableEvent")
  52.  
  53. local FPS = 30
  54.  
  55. local TimeFrame = 0
  56.  
  57. local LastFrame = tick()
  58. local Frame = 1/FPS
  59.  
  60. game:service'RunService'.Heartbeat:connect(function(s,p)
  61. TimeFrame = TimeFrame + s
  62. if(TimeFrame >= Frame)then
  63. for i = 1,math.floor(TimeFrame/Frame) do
  64. AHB:Fire()
  65. end
  66. LastFrame=tick()
  67. TimeFrame=TimeFrame-Frame*math.floor(TimeFrame/Frame)
  68. end
  69. end)
  70.  
  71.  
  72. function swait(dur)
  73. if(dur == 0 or typeof(dur) ~= 'number')then
  74. AHB.Event:wait()
  75. else
  76. for i = 1, dur*FPS do
  77. AHB.Event:wait()
  78. end
  79. end
  80. end
  81.  
  82. local oPlayer = Player
  83. local Player = oPlayer
  84.  
  85. local loudnesses={}
  86. script.Parent = Player.Character
  87. local CoAS = {Actions={}}
  88. local Event = Instance.new("RemoteEvent")
  89. Event.Name = "UserInputEvent"
  90. Event.Parent = Player.Character
  91. local Func = Instance.new("RemoteFunction")
  92. Func.Name = "GetClientProperty"
  93. Func.Parent = Player.Character
  94. local fakeEvent = function()
  95. local t = {_fakeEvent=true,Waited={},Connected={}}
  96. t.Connect = function(self,f)
  97. local ft={}
  98. ft={Disconnected=false;disconnect=function(s) if(self.Function==ft)then self.Function=nil end s.Disconnected=true end}
  99. ft.Disconnect=ft.disconnect
  100.  
  101. ft.Func=function(...)
  102. for id,_ in next, t.Waited do
  103. t.Waited[id] = true
  104. end
  105. return f(...)
  106. end;
  107.  
  108. table.insert(self.Connected,ft)
  109. return ft;
  110. end
  111. t.connect = t.Connect
  112. t.Wait = function()
  113. local guid = GUID:new(25)
  114. local waitingId = guid:Get()
  115. t.Waited[waitingId]=false
  116. repeat swait() until t.Waited[waitingId]==true
  117. t.Waited[waitingId]=nil;
  118. guid:Trash()
  119. end
  120. t.wait = t.Wait
  121. return t
  122. end
  123. local m = {Target=nil,Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent()}
  124. local UsIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()}
  125. local Run = {RenderStepped=fakeEvent()}
  126.  
  127. function CoAS:BindAction(name,fun,touch,...)
  128. CoAS.Actions[name] = {Name=name,Function=fun,Keys={...}}
  129. end
  130. function CoAS:UnbindAction(name)
  131. CoAS.Actions[name] = nil
  132. end
  133. local function te(self,ev,...)
  134. local t = self[ev]
  135. if t and t._fakeEvent and t.Connected then
  136. for i,v in next, t.Connected do
  137. if(v.Func and not v.Disconnected)then
  138. v.Func(...)
  139. else
  140. t.Connected[i]=nil
  141. end
  142. end
  143. end
  144. end
  145. m.TrigEvent = te
  146. UsIS.TrigEvent = te
  147. Run.TrigEvent = te
  148. Event.OnServerEvent:Connect(function(plr,io)
  149. if plr~=Player then return end
  150. --[[table.foreach(io,print)
  151. print'---']]
  152. if io.Mouse then
  153. m.Target = io.Target
  154. m.Hit = io.Hit
  155. elseif io.KeyEvent then
  156. m:TrigEvent('Key'..io.KeyEvent,io.Key)
  157. elseif io.UserInputType == Enum.UserInputType.MouseButton1 then
  158. if io.UserInputState == Enum.UserInputState.Begin then
  159. m:TrigEvent("Button1Down")
  160. else
  161. m:TrigEvent("Button1Up")
  162. end
  163. end
  164. if(not io.KeyEvent and not io.Mouse)then
  165.  
  166. for n,t in pairs(CoAS.Actions) do
  167. for _,k in pairs(t.Keys) do
  168. if k==io.KeyCode then
  169. t.Function(t.Name,io.UserInputState,io)
  170. end
  171. end
  172. end
  173. if io.UserInputState == Enum.UserInputState.Begin then
  174. UsIS:TrigEvent("InputBegan",io,false)
  175. else
  176. UsIS:TrigEvent("InputEnded",io,false)
  177. end
  178. end
  179. end)
  180.  
  181. Func.OnServerInvoke = function(plr,inst,play)
  182. if plr~=Player then return end
  183. if(inst and typeof(inst) == 'Instance' and inst:IsA'Sound')then
  184. loudnesses[inst]=play
  185. end
  186. end
  187.  
  188. function GetClientProperty(inst,prop)
  189. if(prop == 'PlaybackLoudness' and loudnesses[inst])then
  190. return loudnesses[inst]
  191. elseif(prop == 'PlaybackLoudness')then
  192. return Func:InvokeClient(Player,'RegSound',inst)
  193. end
  194. return Func:InvokeClient(Player,inst,prop)
  195. end
  196. local oldGame = game;
  197. function GetFakePlayer()
  198. local oldPlayer = Player;
  199. local fakePlayer = newproxy(true)
  200. getmetatable(fakePlayer).__index = function(s,i)
  201. if(i == 'GetMouse')then
  202. return function() return m; end
  203. end
  204. return Player[i]
  205. end
  206. getmetatable(fakePlayer).__newindex = function(s,i,v)
  207. Player[i]=v
  208. end
  209. getmetatable(fakePlayer).__call=function(self,...)
  210. if(self == fakePlayer)then self = Player end
  211. local wh = {...}
  212. local name = table.remove(wh,1)
  213. for i,v in next, wh do
  214. wh[i]=v
  215. end
  216. if(name == 'GetMouse')then
  217. return m;
  218. end
  219. return self(name,unpack(wh))
  220. end
  221. getmetatable(fakePlayer).__namecall=function(self,...)
  222. if(self == fakePlayer)then self = Player end
  223. local tuple={...}
  224. local name = table.remove(tuple,#tuple)
  225.  
  226. if(name == 'GetMouse')then
  227. return m;
  228. else
  229. return self[name](self,unpack(tuple))
  230. end
  231. end
  232.  
  233. return fakePlayer
  234. end
  235. local oll = LoadLibrary;
  236. function LoadLibrary(libtard)
  237. local libtarddestroyed=oll(libtard)
  238. if(libtard=='RbxUtility')then
  239. local library={Create=function(obj)
  240. local inst = Instance.new(obj)
  241. return function(props)
  242. for prop,valu in next, props do
  243. inst[prop]=valu
  244. end
  245. return inst
  246. end
  247. end}
  248. setmetatable(library,{__index=libtarddestroyed,__newindex=function(s,i,v) libtarddestroyed[i]=v end})
  249.  
  250. return library
  251. else
  252. return libtarddestroyed
  253. end
  254. end
  255. fakePlayer = GetFakePlayer()
  256. local function GetService(s,i)
  257. local service = s:GetService(i)
  258. if(i == 'Players')then
  259. local oldService = service;
  260. local fakeService = newproxy(true)
  261. getmetatable(fakeService).__index = function(s,i)
  262. if(s == fakeService)then s=oldService end
  263. if(i == 'LocalPlayer' or i == 'localPlayer')then
  264. return fakePlayer
  265. elseif(i == 'oPlayer')then
  266. return oPlayer
  267. else
  268. return s[i]
  269. end
  270. end
  271. getmetatable(fakeService).__newindex = function(s,i,v)
  272. if(s == fakeService)then s=oldService end
  273. s[i]=v
  274. end
  275. getmetatable(fakeService).__call=function(self,...)
  276. if(self == fakeService)then self = oldService end
  277. local wh = {...}
  278. local name = table.remove(wh,1)
  279. for i,v in next, wh do
  280. wh[i]=v
  281. end
  282. return self(name,unpack(wh))
  283. end
  284. getmetatable(fakeService).__namecall=function(self,...)
  285. if(self == fakeService)then self = oldService end
  286. local tuple={...}
  287. local name = table.remove(tuple,#tuple)
  288.  
  289. return self[name](self,unpack(tuple))
  290. end
  291. getmetatable(fakeService).__metatable = 'gay'
  292. return fakeService
  293. elseif(i == 'RunService')then
  294. local oldService = service;
  295. local fakeService = newproxy(true)
  296. getmetatable(fakeService).__index = function(s,i)
  297. if(s == fakeService)then s=oldService end
  298. return Run[i] or s[i]
  299. end
  300. getmetatable(fakeService).__newindex = function(s,i,v)
  301. if(s == fakeService)then s=oldService end
  302. s[i]=v
  303. end
  304. getmetatable(fakeService).__call=function(self,...)
  305. if(self == fakeService)then self = oldService end
  306. local wh = {...}
  307. local name = table.remove(wh,1)
  308. for i,v in next, wh do
  309. wh[i]=v
  310. end
  311. return self(name,unpack(wh))
  312. end
  313. getmetatable(fakeService).__namecall=function(self,...)
  314. if(self == fakeService)then self = oldService end
  315. local tuple={...}
  316. local name = table.remove(tuple,#tuple)
  317.  
  318. return self[name](self,unpack(tuple))
  319. end
  320. getmetatable(fakeService).__metatable = 'gay'
  321. return fakeService
  322. elseif(i == 'UserInputService')then
  323. return UsIS
  324. elseif(i == 'ContextActionService')then
  325. return CoAS;
  326. else
  327. return service
  328. end
  329. end
  330.  
  331. local new = Instance.new;
  332. Instance = {}
  333. Instance.new = function(inst,obje)
  334. local lp = GetService(oldGame,'Players').localPlayer
  335. local instance = new(inst)
  336. if(inst=='ObjectValue')then
  337. local fake = newproxy(true)
  338. getmetatable(fake).__index=function(self,index)
  339. if(self==fake)then self=instance end
  340. return self[index]
  341. end
  342. getmetatable(fake).__newindex=function(self,index,value)
  343. if(self==fake)then self=instance end
  344. if(index=='Value' and typeof(value)~='Instance' and value==fakePlayer)then
  345. self[index]=oPlayer
  346. else
  347. self[index]=value
  348. end
  349. end
  350. getmetatable(fake).__call=function(self,...)
  351. if(self == fake)then self = instance end
  352. local wh = {...}
  353. local name = table.remove(wh,1)
  354. for i,v in next, wh do
  355. if(v == fake)then v = instance end
  356. wh[i]=v
  357. end
  358. return self(name,unpack(wh))
  359. end
  360. getmetatable(fake). __namecall=function(self,...)
  361. if(self == fake)then self = instance end
  362. local tuple={...}
  363. local name = table.remove(tuple,#tuple)
  364. return self[name](self,unpack(tuple))
  365. end
  366. return fake
  367. else
  368. instance.Parent = obje
  369. return instance;
  370. end
  371.  
  372. end
  373. local serviceFunctions={
  374. service=true,
  375. GetService=true,
  376. }
  377. local fakeGame = newproxy(true)
  378. getmetatable(fakeGame).__index = function(s,i)
  379. if(s == fakeGame)then s=oldGame end
  380. local serv = GetService(oldGame,i)
  381. if serviceFunctions[i] then
  382. return GetService
  383. elseif(serv)then
  384. return serv
  385. else
  386. return s[i]
  387. end
  388. end
  389. getmetatable(fakeGame).__newindex = function(s,i,v)
  390. if(s == fakeGame)then s=oldGame end
  391. s[i]=v
  392. end
  393. getmetatable(fakeGame).__call=function(self,...)
  394. if(self == fakeGame)then self = oldGame end
  395. local wh = {...}
  396. local name = table.remove(wh,1)
  397. for i,v in next, wh do
  398. if(v == fakeGame)then v = oldGame end
  399. wh[i]=v
  400. end
  401. if serviceFunctions[name] then
  402. return GetService(self,unpack(wh))
  403. else
  404. return self(name,unpack(wh))
  405. end
  406. end
  407. getmetatable(fakeGame). __namecall=function(self,...)
  408. if(self == fakeGame)then self = oldGame end
  409. local tuple={...}
  410. local name = table.remove(tuple,#tuple)
  411.  
  412. local funcToCall=self[name]
  413.  
  414. if serviceFunctions[name] then
  415. return GetService(self,unpack(tuple))
  416. else
  417. return self[name](self,unpack(tuple))
  418. end
  419. end
  420. getmetatable(fakeGame).__metatable = 'gay'
  421.  
  422. coroutine.wrap(function()
  423. while true do
  424. Run:TrigEvent('RenderStepped')
  425. swait()
  426. end
  427. end)()
  428. game=fakeGame
  429. UserInputService,ContextActionService = UsIS,CoAS
  430. end
  431.  
  432. -- converter by Drahazar
  433. -- converted using Drahazar's Void SB Script Converter
  434.  
  435. --//====================================================\\--
  436. --|| CREATED BY SHACKLUSTER
  437. --\\====================================================//--
  438.  
  439. wait(0.2)
  440.  
  441. Player = game:GetService("Players").LocalPlayer
  442. PlayerGui = Player.PlayerGui
  443. Cam = workspace.CurrentCamera
  444. Backpack = Player.Backpack
  445. Character = Player.Character
  446. Humanoid = Character.Humanoid
  447. Mouse = Player:GetMouse()
  448. RootPart = Character["HumanoidRootPart"]
  449. Torso = Character["Torso"]
  450. Head = Character["Head"]
  451. RightArm = Character["Right Arm"]
  452. LeftArm = Character["Left Arm"]
  453. RightLeg = Character["Right Leg"]
  454. LeftLeg = Character["Left Leg"]
  455. RootJoint = RootPart["RootJoint"]
  456. Neck = Torso["Neck"]
  457. RightShoulder = Torso["Right Shoulder"]
  458. LeftShoulder = Torso["Left Shoulder"]
  459. RightHip = Torso["Right Hip"]
  460. LeftHip = Torso["Left Hip"]
  461. local sick = Instance.new("Sound",Torso)
  462.  
  463. IT = Instance.new
  464. CF = CFrame.new
  465. VT = Vector3.new
  466. RAD = math.rad
  467. C3 = Color3.new
  468. UD2 = UDim2.new
  469. BRICKC = BrickColor.new
  470. ANGLES = CFrame.Angles
  471. EULER = CFrame.fromEulerAnglesXYZ
  472. COS = math.cos
  473. ACOS = math.acos
  474. SIN = math.sin
  475. ASIN = math.asin
  476. ABS = math.abs
  477. MRANDOM = math.random
  478. FLOOR = math.floor
  479.  
  480. --//=================================\\
  481. --|| USEFUL VALUES
  482. --\\=================================//
  483.  
  484. Animation_Speed = 3
  485. Frame_Speed = 1 / 60 -- (1 / 30) OR (1 / 60)
  486. local Speed = 16
  487. local ROOTC0 = CF(0, 0, 0) * ANGLES(RAD(-90), RAD(0), RAD(180))
  488. local NECKC0 = CF(0, 1, 0) * ANGLES(RAD(-90), RAD(0), RAD(180))
  489. local RIGHTSHOULDERC0 = CF(-0.5, 0, 0) * ANGLES(RAD(0), RAD(90), RAD(0))
  490. local LEFTSHOULDERC0 = CF(0.5, 0, 0) * ANGLES(RAD(0), RAD(-90), RAD(0))
  491. local DAMAGEMULTIPLIER = 1
  492. local ANIM = "Idle"
  493. local ATTACK = false
  494. local HOLD = false
  495. local COMBO = 1
  496. local Rooted = false
  497. local SINE = 0
  498. local KEYHOLD = false
  499. local EXTRATRANS = 0
  500. local CHANGE = 2 / Animation_Speed
  501. local WALKINGANIM = false
  502. local VALUE1 = false
  503. local VALUE2 = false
  504. local ROBLOXIDLEANIMATION = IT("Animation")
  505. ROBLOXIDLEANIMATION.Name = "Roblox Idle Animation"
  506. ROBLOXIDLEANIMATION.AnimationId = "http://www.roblox.com/asset/?id=180435571"
  507. --ROBLOXIDLEANIMATION.Parent = Humanoid
  508. local WEAPONGUI = IT("ScreenGui", PlayerGui)
  509. WEAPONGUI.Name = "Weapon GUI"
  510. local Effects = IT("Folder", Character)
  511. Effects.Name = "Effects"
  512. local ANIMATOR = Humanoid.Animator
  513. local ANIMATE = Character.Animate
  514. ANIMATE:remove()
  515. local UNANCHOR = true
  516. for _,v in next, Humanoid:GetPlayingAnimationTracks() do
  517. v:Stop();
  518. end
  519. wait(1)
  520. local HITPLAYERSOUNDS = {--[["199149137", "199149186", "199149221", "199149235", "199149269", "199149297"--]]"263032172", "263032182", "263032200", "263032221", "263032252", "263033191"}
  521. local SONGS = {{742930580,2},{206651523,1},{248797953,1.5},{1031096428,1}}
  522. local BLASTS = {468991944,468991990}
  523. local ICESPAWNS = {338594737,338594687,338594666,338594648,338594606,338594574,338594556,338594524,338594467}
  524. local CHOICE = MRANDOM(1,#SONGS)
  525.  
  526. --//=================================\\
  527. --\\=================================//
  528.  
  529.  
  530. --//=================================\\
  531. --|| SAZERENOS' ARTIFICIAL HEARTBEAT
  532. --\\=================================//
  533.  
  534. ArtificialHB = Instance.new("BindableEvent", script)
  535. ArtificialHB.Name = "ArtificialHB"
  536.  
  537. script:WaitForChild("ArtificialHB")
  538.  
  539. frame = Frame_Speed
  540. tf = 0
  541. allowframeloss = false
  542. tossremainder = false
  543. lastframe = tick()
  544. script.ArtificialHB:Fire()
  545.  
  546. game:GetService("RunService").Heartbeat:connect(function(s, p)
  547. tf = tf + s
  548. if tf >= frame then
  549. if allowframeloss then
  550. script.ArtificialHB:Fire()
  551. lastframe = tick()
  552. else
  553. for i = 1, math.floor(tf / frame) do
  554. script.ArtificialHB:Fire()
  555. end
  556. lastframe = tick()
  557. end
  558. if tossremainder then
  559. tf = 0
  560. else
  561. tf = tf - frame * math.floor(tf / frame)
  562. end
  563. end
  564. end)
  565.  
  566. --//=================================\\
  567. --\\=================================//
  568.  
  569. --//=================================\\
  570. --|| SOME FUNCTIONS
  571. --\\=================================//
  572.  
  573. function Raycast(POSITION, DIRECTION, RANGE, IGNOREDECENDANTS)
  574. return workspace:FindPartOnRay(Ray.new(POSITION, DIRECTION.unit * RANGE), IGNOREDECENDANTS)
  575. end
  576.  
  577. function PositiveAngle(NUMBER)
  578. if NUMBER >= 0 then
  579. NUMBER = 0
  580. end
  581. return NUMBER
  582. end
  583.  
  584. function NegativeAngle(NUMBER)
  585. if NUMBER <= 0 then
  586. NUMBER = 0
  587. end
  588. return NUMBER
  589. end
  590.  
  591. function Swait(NUMBER)
  592. if NUMBER == 0 or NUMBER == nil then
  593. ArtificialHB.Event:wait()
  594. else
  595. for i = 1, NUMBER do
  596. ArtificialHB.Event:wait()
  597. end
  598. end
  599. end
  600.  
  601. function CreateMesh(MESH, PARENT, MESHTYPE, MESHID, TEXTUREID, SCALE, OFFSET)
  602. local NEWMESH = IT(MESH)
  603. if MESH == "SpecialMesh" then
  604. NEWMESH.MeshType = MESHTYPE
  605. if MESHID ~= "nil" and MESHID ~= "" then
  606. NEWMESH.MeshId = "http://www.roblox.com/asset/?id="..MESHID
  607. end
  608. if TEXTUREID ~= "nil" and TEXTUREID ~= "" then
  609. NEWMESH.TextureId = "http://www.roblox.com/asset/?id="..TEXTUREID
  610. end
  611. end
  612. NEWMESH.Offset = OFFSET or VT(0, 0, 0)
  613. NEWMESH.Scale = SCALE
  614. NEWMESH.Parent = PARENT
  615. return NEWMESH
  616. end
  617.  
  618. function CreatePart(FORMFACTOR, PARENT, MATERIAL, REFLECTANCE, TRANSPARENCY, BRICKCOLOR, NAME, SIZE, ANCHOR)
  619. local NEWPART = IT("Part")
  620. NEWPART.formFactor = FORMFACTOR
  621. NEWPART.Reflectance = REFLECTANCE
  622. NEWPART.Transparency = TRANSPARENCY
  623. NEWPART.CanCollide = false
  624. NEWPART.Locked = true
  625. NEWPART.Anchored = true
  626. if ANCHOR == false then
  627. NEWPART.Anchored = false
  628. end
  629. NEWPART.BrickColor = BRICKC(tostring(BRICKCOLOR))
  630. NEWPART.Name = NAME
  631. NEWPART.Size = SIZE
  632. NEWPART.Position = Torso.Position
  633. NEWPART.Material = MATERIAL
  634. NEWPART:BreakJoints()
  635. NEWPART.Parent = PARENT
  636. return NEWPART
  637. end
  638.  
  639. local function weldBetween(a, b)
  640. local weldd = Instance.new("ManualWeld")
  641. weldd.Part0 = a
  642. weldd.Part1 = b
  643. weldd.C0 = CFrame.new()
  644. weldd.C1 = b.CFrame:inverse() * a.CFrame
  645. weldd.Parent = a
  646. return weldd
  647. end
  648.  
  649.  
  650. function QuaternionFromCFrame(cf)
  651. local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components()
  652. local trace = m00 + m11 + m22
  653. if trace > 0 then
  654. local s = math.sqrt(1 + trace)
  655. local recip = 0.5 / s
  656. return (m21 - m12) * recip, (m02 - m20) * recip, (m10 - m01) * recip, s * 0.5
  657. else
  658. local i = 0
  659. if m11 > m00 then
  660. i = 1
  661. end
  662. if m22 > (i == 0 and m00 or m11) then
  663. i = 2
  664. end
  665. if i == 0 then
  666. local s = math.sqrt(m00 - m11 - m22 + 1)
  667. local recip = 0.5 / s
  668. return 0.5 * s, (m10 + m01) * recip, (m20 + m02) * recip, (m21 - m12) * recip
  669. elseif i == 1 then
  670. local s = math.sqrt(m11 - m22 - m00 + 1)
  671. local recip = 0.5 / s
  672. return (m01 + m10) * recip, 0.5 * s, (m21 + m12) * recip, (m02 - m20) * recip
  673. elseif i == 2 then
  674. local s = math.sqrt(m22 - m00 - m11 + 1)
  675. local recip = 0.5 / s return (m02 + m20) * recip, (m12 + m21) * recip, 0.5 * s, (m10 - m01) * recip
  676. end
  677. end
  678. end
  679.  
  680. function QuaternionToCFrame(px, py, pz, x, y, z, w)
  681. local xs, ys, zs = x + x, y + y, z + z
  682. local wx, wy, wz = w * xs, w * ys, w * zs
  683. local xx = x * xs
  684. local xy = x * ys
  685. local xz = x * zs
  686. local yy = y * ys
  687. local yz = y * zs
  688. local zz = z * zs
  689. return CFrame.new(px, py, pz, 1 - (yy + zz), xy - wz, xz + wy, xy + wz, 1 - (xx + zz), yz - wx, xz - wy, yz + wx, 1 - (xx + yy))
  690. end
  691.  
  692. function QuaternionSlerp(a, b, t)
  693. local cosTheta = a[1] * b[1] + a[2] * b[2] + a[3] * b[3] + a[4] * b[4]
  694. local startInterp, finishInterp;
  695. if cosTheta >= 0.0001 then
  696. if (1 - cosTheta) > 0.0001 then
  697. local theta = ACOS(cosTheta)
  698. local invSinTheta = 1 / SIN(theta)
  699. startInterp = SIN((1 - t) * theta) * invSinTheta
  700. finishInterp = SIN(t * theta) * invSinTheta
  701. else
  702. startInterp = 1 - t
  703. finishInterp = t
  704. end
  705. else
  706. if (1 + cosTheta) > 0.0001 then
  707. local theta = ACOS(-cosTheta)
  708. local invSinTheta = 1 / SIN(theta)
  709. startInterp = SIN((t - 1) * theta) * invSinTheta
  710. finishInterp = SIN(t * theta) * invSinTheta
  711. else
  712. startInterp = t - 1
  713. finishInterp = t
  714. end
  715. end
  716. return a[1] * startInterp + b[1] * finishInterp, a[2] * startInterp + b[2] * finishInterp, a[3] * startInterp + b[3] * finishInterp, a[4] * startInterp + b[4] * finishInterp
  717. end
  718.  
  719. function Clerp(a, b, t)
  720. local qa = {QuaternionFromCFrame(a)}
  721. local qb = {QuaternionFromCFrame(b)}
  722. local ax, ay, az = a.x, a.y, a.z
  723. local bx, by, bz = b.x, b.y, b.z
  724. local _t = 1 - t
  725. return QuaternionToCFrame(_t * ax + t * bx, _t * ay + t * by, _t * az + t * bz, QuaternionSlerp(qa, qb, t))
  726. end
  727.  
  728. function CreateFrame(PARENT, TRANSPARENCY, BORDERSIZEPIXEL, POSITION, SIZE, COLOR, BORDERCOLOR, NAME)
  729. local frame = IT("Frame")
  730. frame.BackgroundTransparency = TRANSPARENCY
  731. frame.BorderSizePixel = BORDERSIZEPIXEL
  732. frame.Position = POSITION
  733. frame.Size = SIZE
  734. frame.BackgroundColor3 = COLOR
  735. frame.BorderColor3 = BORDERCOLOR
  736. frame.Name = NAME
  737. frame.Parent = PARENT
  738. return frame
  739. end
  740.  
  741. function CreateLabel(PARENT, TEXT, TEXTCOLOR, TEXTFONTSIZE, TEXTFONT, TRANSPARENCY, BORDERSIZEPIXEL, STROKETRANSPARENCY, NAME)
  742. local label = IT("TextLabel")
  743. label.BackgroundTransparency = 1
  744. label.Size = UD2(1, 0, 1, 0)
  745. label.Position = UD2(0, 0, 0, 0)
  746. label.TextColor3 = TEXTCOLOR
  747. label.TextStrokeTransparency = STROKETRANSPARENCY
  748. label.TextTransparency = TRANSPARENCY
  749. label.FontSize = TEXTFONTSIZE
  750. label.Font = TEXTFONT
  751. label.BorderSizePixel = BORDERSIZEPIXEL
  752. label.TextScaled = false
  753. label.Text = TEXT
  754. label.Name = NAME
  755. label.Parent = PARENT
  756. return label
  757. end
  758.  
  759. function NoOutlines(PART)
  760. PART.TopSurface, PART.BottomSurface, PART.LeftSurface, PART.RightSurface, PART.FrontSurface, PART.BackSurface = 10, 10, 10, 10, 10, 10
  761. end
  762.  
  763. function CreateWeldOrSnapOrMotor(TYPE, PARENT, PART0, PART1, C0, C1)
  764. local NEWWELD = IT(TYPE)
  765. NEWWELD.Part0 = PART0
  766. NEWWELD.Part1 = PART1
  767. NEWWELD.C0 = C0
  768. NEWWELD.C1 = C1
  769. NEWWELD.Parent = PARENT
  770. return NEWWELD
  771. end
  772.  
  773. local S = IT("Sound")
  774. function CreateSound(ID, PARENT, VOLUME, PITCH, DOESLOOP)
  775. local NEWSOUND = nil
  776. coroutine.resume(coroutine.create(function()
  777. NEWSOUND = S:Clone()
  778. NEWSOUND.Parent = PARENT
  779. NEWSOUND.Volume = VOLUME
  780. NEWSOUND.Pitch = PITCH
  781. NEWSOUND.SoundId = "http://www.roblox.com/asset/?id="..ID
  782. NEWSOUND:play()
  783. if DOESLOOP == true then
  784. NEWSOUND.Looped = true
  785. else
  786. repeat wait(1) until NEWSOUND.Playing == false
  787. NEWSOUND:remove()
  788. end
  789. end))
  790. return NEWSOUND
  791. end
  792.  
  793. function CFrameFromTopBack(at, top, back)
  794. local right = top:Cross(back)
  795. return CF(at.x, at.y, at.z, right.x, top.x, back.x, right.y, top.y, back.y, right.z, top.z, back.z)
  796. end
  797.  
  798. --WACKYEFFECT({EffectType = "", Size = VT(1,1,1), Size2 = VT(0,0,0), Transparency = 0, Transparency2 = 1, CFrame = CF(), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(1,1,1), SoundID = nil, SoundPitch = nil, SoundVolume = nil})
  799. function WACKYEFFECT(Table)
  800. local TYPE = (Table.EffectType or "Sphere")
  801. local SIZE = (Table.Size or VT(1,1,1))
  802. local ENDSIZE = (Table.Size2 or VT(0,0,0))
  803. local TRANSPARENCY = (Table.Transparency or 0)
  804. local ENDTRANSPARENCY = (Table.Transparency2 or 1)
  805. local CFRAME = (Table.CFrame or Torso.CFrame)
  806. local MOVEDIRECTION = (Table.MoveToPos or nil)
  807. local ROTATION1 = (Table.RotationX or 0)
  808. local ROTATION2 = (Table.RotationY or 0)
  809. local ROTATION3 = (Table.RotationZ or 0)
  810. local MATERIAL = (Table.Material or "Neon")
  811. local COLOR = (Table.Color or C3(1,1,1))
  812. local TIME = (Table.Time or 45)
  813. local SOUNDID = (Table.SoundID or nil)
  814. local SOUNDPITCH = (Table.SoundPitch or nil)
  815. local SOUNDVOLUME = (Table.SoundVolume or nil)
  816. coroutine.resume(coroutine.create(function()
  817. local PLAYSSOUND = false
  818. local SOUND = nil
  819. local EFFECT = CreatePart(3, Effects, MATERIAL, 0, TRANSPARENCY, BRICKC("Pearl"), "Effect", VT(1,1,1), true)
  820. if SOUNDID ~= nil and SOUNDPITCH ~= nil and SOUNDVOLUME ~= nil then
  821. PLAYSSOUND = true
  822. SOUND = CreateSound(SOUNDID, EFFECT, SOUNDVOLUME, SOUNDPITCH, false)
  823. end
  824. EFFECT.Color = COLOR
  825. local MSH = nil
  826. if TYPE == "Sphere" then
  827. MSH = CreateMesh("SpecialMesh", EFFECT, "Sphere", "", "", SIZE, VT(0,0,0))
  828. elseif TYPE == "Block" then
  829. MSH = IT("BlockMesh",EFFECT)
  830. MSH.Scale = VT(SIZE.X,SIZE.X,SIZE.X)
  831. elseif TYPE == "Wave" then
  832. MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "20329976", "", SIZE, VT(0,0,-SIZE.X/8))
  833. elseif TYPE == "Ring" then
  834. MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "559831844", "", VT(SIZE.X,SIZE.X,0.1), VT(0,0,0))
  835. elseif TYPE == "Slash" then
  836. MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "662586858", "", VT(SIZE.X/10,0,SIZE.X/10), VT(0,0,0))
  837. elseif TYPE == "Round Slash" then
  838. MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "662585058", "", VT(SIZE.X/10,0,SIZE.X/10), VT(0,0,0))
  839. elseif TYPE == "Swirl" then
  840. MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "1051557", "", SIZE, VT(0,0,0))
  841. elseif TYPE == "Skull" then
  842. MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "4770583", "", SIZE, VT(0,0,0))
  843. elseif TYPE == "Crystal" then
  844. MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "9756362", "", SIZE, VT(0,0,0))
  845. end
  846. if MSH ~= nil then
  847. local MOVESPEED = nil
  848. if MOVEDIRECTION ~= nil then
  849. MOVESPEED = (CFRAME.p - MOVEDIRECTION).Magnitude/TIME
  850. end
  851. local GROWTH = SIZE - ENDSIZE
  852. local TRANS = TRANSPARENCY - ENDTRANSPARENCY
  853. if TYPE == "Block" then
  854. EFFECT.CFrame = CFRAME*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)))
  855. else
  856. EFFECT.CFrame = CFRAME
  857. end
  858. for LOOP = 1, TIME+1 do
  859. Swait()
  860. MSH.Scale = MSH.Scale - GROWTH/TIME
  861. if TYPE == "Wave" then
  862. MSH.Offset = VT(0,0,-MSH.Scale.X/8)
  863. end
  864. EFFECT.Transparency = EFFECT.Transparency - TRANS/TIME
  865. if TYPE == "Block" then
  866. EFFECT.CFrame = CFRAME*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)))
  867. else
  868. EFFECT.CFrame = EFFECT.CFrame*ANGLES(RAD(ROTATION1),RAD(ROTATION2),RAD(ROTATION3))
  869. end
  870. if MOVEDIRECTION ~= nil then
  871. local ORI = EFFECT.Orientation
  872. EFFECT.CFrame = CF(EFFECT.Position,MOVEDIRECTION)*CF(0,0,-MOVESPEED)
  873. EFFECT.Orientation = ORI
  874. end
  875. end
  876. if PLAYSSOUND == false then
  877. EFFECT:remove()
  878. else
  879. repeat Swait() until SOUND.Playing == false
  880. EFFECT:remove()
  881. end
  882. else
  883. if PLAYSSOUND == false then
  884. EFFECT:remove()
  885. else
  886. repeat Swait() until SOUND.Playing == false
  887. EFFECT:remove()
  888. end
  889. end
  890. end))
  891. end
  892.  
  893. function MakeForm(PART,TYPE)
  894. if TYPE == "Cyl" then
  895. local MSH = IT("CylinderMesh",PART)
  896. elseif TYPE == "Ball" then
  897. local MSH = IT("SpecialMesh",PART)
  898. MSH.MeshType = "Sphere"
  899. elseif TYPE == "Wedge" then
  900. local MSH = IT("SpecialMesh",PART)
  901. MSH.MeshType = "Wedge"
  902. end
  903. end
  904.  
  905. Debris = game:GetService("Debris")
  906.  
  907. function CastProperRay(StartPos, EndPos, Distance, Ignore)
  908. local DIRECTION = CF(StartPos,EndPos).lookVector
  909. return Raycast(StartPos, DIRECTION, Distance, Ignore)
  910. end
  911.  
  912. function WaveParticles(Position,Size,Color)
  913. local BASE = CreatePart(3, Effects, "Neon", 0, 1, BRICKC("Pearl"), "Shockwave", VT(0,0,0), true)
  914. BASE.CFrame = CF(Position)
  915. local A = IT("Attachment",BASE)
  916. local WAVE = script.Wave:Clone()
  917. WAVE.Parent = A
  918. WAVE.Size = NumberSequence.new(0,Size)
  919. WAVE.Color = ColorSequence.new(Color)
  920. Debris:AddItem(BASE,0.5)
  921. WAVE:Emit(1)
  922. end
  923.  
  924. --//=================================\\
  925. --|| WEAPON CREATION
  926. --\\=================================//
  927.  
  928. for _, c in pairs(Character:GetChildren()) do
  929. if script:FindFirstChild(c.Name) then
  930. local Part = script[c.Name]
  931. Part.Parent = Character
  932. Part:SetPrimaryPartCFrame(c.CFrame)
  933. weldBetween(c,Part.Base)
  934. for _, e in pairs(Part:GetChildren()) do
  935. if e:IsA("BasePart") and e.Name ~= "Base" then
  936. e.CustomPhysicalProperties = PhysicalProperties.new(0, 0, 0, 0, 0)
  937. e.Anchored = false
  938. weldBetween(e,c)
  939. e.CanCollide = false
  940. end
  941. end
  942. Part.Base:remove()
  943. end
  944. end
  945.  
  946. local WINGPART = script.Wing
  947. WINGPART.Parent = nil
  948. local SWORD = script.Katana
  949. SWORD.Parent = nil
  950. local SPEAR = script.Spear
  951. SPEAR.Parent = nil
  952.  
  953. local BODY = {}
  954. for _, c in pairs(Character:GetDescendants()) do
  955. if c:IsA("BasePart") and c.Name ~= "Handle" then
  956. if c ~= RootPart and c ~= Torso and c ~= Head and c ~= RightArm and c ~= LeftArm and c ~= RightLeg and c ~= LeftLeg then
  957. c.CustomPhysicalProperties = PhysicalProperties.new(0, 0, 0, 0, 0)
  958. end
  959. table.insert(BODY,{c,c.Parent,c.Material,c.Color,c.Transparency})
  960. elseif c:IsA("JointInstance") then
  961. table.insert(BODY,{c,c.Parent,nil,nil,nil})
  962. end
  963. end
  964. for e = 1, #BODY do
  965. if BODY[e] ~= nil then
  966. local STUFF = BODY[e]
  967. local PART = STUFF[1]
  968. local PARENT = STUFF[2]
  969. local MATERIAL = STUFF[3]
  970. local COLOR = STUFF[4]
  971. local TRANSPARENCY = STUFF[5]
  972. if PART.ClassName == "Part" and PART ~= RootPart then
  973. PART.Material = MATERIAL
  974. PART.Color = COLOR
  975. PART.Transparency = TRANSPARENCY+EXTRATRANS
  976. end
  977. PART.AncestryChanged:Connect(function()
  978. PART.Parent = PARENT
  979. end)
  980. end
  981. end
  982. function refit()
  983. Character.Parent = workspace
  984. for e = 1, #BODY do
  985. if BODY[e] ~= nil then
  986. local STUFF = BODY[e]
  987. local PART = STUFF[1]
  988. local PARENT = STUFF[2]
  989. local MATERIAL = STUFF[3]
  990. local COLOR = STUFF[4]
  991. local TRANSPARENCY = STUFF[5]
  992. if PART:IsA("BasePart") and PART ~= RootPart then
  993. PART.Material = MATERIAL
  994. PART.Color = COLOR
  995. PART.Transparency = TRANSPARENCY+EXTRATRANS
  996. end
  997. if PART.Parent ~= PARENT then
  998. Humanoid:remove()
  999. PART.Parent = PARENT
  1000. Humanoid = IT("Humanoid",Character)
  1001. end
  1002. end
  1003. end
  1004. end
  1005.  
  1006. Humanoid.Died:connect(function()
  1007. refit()
  1008. end)
  1009.  
  1010. local SKILLTEXTCOLOR = C3(180/255, 210/255, 228/255)
  1011. local SKILLFONT = "Antique"
  1012. local SKILLTEXTSIZE = 5
  1013.  
  1014. local MOUTH = IT("Attachment",Head)
  1015. MOUTH.Position = VT(0,-0.2,-0.5)
  1016. local BREATH = script.Breath
  1017. BREATH.Parent = MOUTH
  1018.  
  1019. local MOBILITY = {"Spacebar","Z","B"}
  1020. local ATTACKS = {"Mouse","Q","E","V"}
  1021. local MOBILITYFRAME = CreateFrame(WEAPONGUI, 1, 2, UD2(0.71, 0, 0.90, 0), UD2(0.26, 0, 0.07, 0), C3(0,0,0), C3(0, 0, 0), "Skill Frame")
  1022. local TEXT = CreateLabel(MOBILITYFRAME, "[MOBILITY]", SKILLTEXTCOLOR, SKILLTEXTSIZE+1, SKILLFONT, 0, 2, 0.5, "Skill text")
  1023. local ATTACKSFRAME = CreateFrame(WEAPONGUI, 1, 2, UD2(0.8, 0, 0.90, 0), UD2(0.26, 0, 0.07, 0), C3(0,0,0), C3(0, 0, 0), "Skill Frame")
  1024. local TEXT = CreateLabel(ATTACKSFRAME, "[ATTACKS]", SKILLTEXTCOLOR, SKILLTEXTSIZE+1, SKILLFONT, 0, 2, 0.5, "Skill text")
  1025.  
  1026. for i = 1, #MOBILITY do
  1027. local SKILLFRAME = CreateFrame(WEAPONGUI, 1, 2, UD2(0.71, 0, 0.90-(0.04*i), 0), UD2(0.26, 0, 0.07, 0), C3(0,0,0), C3(0, 0, 0), "Skill Frame")
  1028. local SKILLTEXT = CreateLabel(SKILLFRAME, "["..MOBILITY[i].."]", SKILLTEXTCOLOR, SKILLTEXTSIZE, SKILLFONT, 0, 2, 0.5, "Skill text")
  1029. end
  1030. for i = 1, #ATTACKS do
  1031. local SKILLFRAME = CreateFrame(WEAPONGUI, 1, 2, UD2(0.8, 0, 0.90-(0.04*i), 0), UD2(0.26, 0, 0.07, 0), C3(0,0,0), C3(0, 0, 0), "Skill Frame")
  1032. local SKILLTEXT = CreateLabel(SKILLFRAME, "["..ATTACKS[i].."]", SKILLTEXTCOLOR, SKILLTEXTSIZE, SKILLFONT, 0, 2, 0.5, "Skill text")
  1033. end
  1034.  
  1035. --//=================================\\
  1036. --|| DAMAGING
  1037. --\\=================================//
  1038.  
  1039. function ApplyDamage(Humanoid,Damage)
  1040. Damage = Damage * DAMAGEMULTIPLIER
  1041. if Humanoid.Health < 2000 then
  1042. if Humanoid.Health - Damage > 0 then
  1043. Humanoid.Health = Humanoid.Health - Damage
  1044. else
  1045. Humanoid.Parent:BreakJoints()
  1046. end
  1047. else
  1048. Humanoid.Parent:BreakJoints()
  1049. end
  1050. end
  1051.  
  1052. function FREEZY(CHARACTER)
  1053. if CHARACTER:FindFirstChild("FreezeTimer") then
  1054. CHARACTER:FindFirstChild("FreezeTimer").Value = CHARACTER:FindFirstChild("FreezeTimer").Value + 3
  1055. else
  1056. coroutine.resume(coroutine.create(function()
  1057. local ICES = {}
  1058. for index, CHILD in pairs(CHARACTER:GetChildren()) do
  1059. if CHILD:IsA("BasePart") and CHILD.Name ~= "Head" and CHILD.Name ~= "HumanoidRootPart" then
  1060. local ICE = CreatePart(3, CHILD, "Ice", 0, 0.5, BRICKC("Fossil"), "Ice", CHILD.Size, false)
  1061. table.insert(ICES,ICE)
  1062. CreateWeldOrSnapOrMotor("Weld", CHILD, CHILD, ICE, CF(0,0,0) * ANGLES(RAD(MRANDOM(-25,25)), RAD(MRANDOM(0,360)), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(MRANDOM(-25,25))), CF(0, 0, 0))
  1063. coroutine.resume(coroutine.create(function()
  1064. wait()
  1065. CHILD.Anchored = true
  1066. end))
  1067. elseif CHILD.Name == "Head" then
  1068. local ICE = CreatePart(3, CHILD, "Ice", 0, 0.5, BRICKC("Fossil"), "Ice", VT(CHILD.Size.Y,CHILD.Size.Y,CHILD.Size.Y), false)
  1069. table.insert(ICES,ICE)
  1070. CreateWeldOrSnapOrMotor("Weld", CHILD, CHILD, ICE, CF(MRANDOM(-5,5)/15,MRANDOM(-5,5)/15,MRANDOM(-5,5)/15) * ANGLES(RAD(MRANDOM(-25,25)), RAD(MRANDOM(0,360)), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(MRANDOM(-25,25))), CF(0, 0, 0))
  1071. coroutine.resume(coroutine.create(function()
  1072. wait()
  1073. CHILD.Anchored = true
  1074. end))
  1075. end
  1076. end
  1077. local TIMER = IT("NumberValue",CHARACTER)
  1078. TIMER.Value = MRANDOM(4,6)
  1079. TIMER.Name = "FreezeTimer"
  1080. repeat
  1081. wait(1)
  1082. TIMER.Value = TIMER.Value - 1
  1083. until TIMER.Value <= 0
  1084. TIMER:remove()
  1085. for i = 1, 45 do
  1086. Swait()
  1087. for E = 1, #ICES do
  1088. ICES[E].Transparency = 0.5+(i/45)/2
  1089. end
  1090. end
  1091. for E = 1, #ICES do
  1092. ICES[E]:remove()
  1093. end
  1094. for index, CHILD in pairs(CHARACTER:GetChildren()) do
  1095. if CHILD:IsA("BasePart") then
  1096. CHILD.Anchored = false
  1097. end
  1098. end
  1099. end))
  1100. end
  1101. end
  1102.  
  1103. function ApplyAoE(POSITION,RANGE,MINDMG,MAXDMG,FLING,INSTAKILL,FREEZE)
  1104. local CHILDREN = workspace:GetDescendants()
  1105. for index, CHILD in pairs(CHILDREN) do
  1106. if CHILD.ClassName == "Model" and CHILD ~= Character then
  1107. local HUM = CHILD:FindFirstChildOfClass("Humanoid")
  1108. if HUM then
  1109. local TORSO = CHILD:FindFirstChild("Torso") or CHILD:FindFirstChild("UpperTorso")
  1110. if TORSO then
  1111. if (TORSO.Position - POSITION).Magnitude <= RANGE then
  1112. if INSTAKILL == true then
  1113. CHILD:BreakJoints()
  1114. else
  1115. local DMG = MRANDOM(MINDMG,MAXDMG)
  1116. ApplyDamage(HUM,DMG,TORSO)
  1117. end
  1118. if FREEZE == true and HUM.Health > 0 then
  1119. FREEZY(CHILD)
  1120. end
  1121. if FLING > 0 then
  1122. for _, c in pairs(CHILD:GetChildren()) do
  1123. if c:IsA("BasePart") then
  1124. local bv = Instance.new("BodyVelocity")
  1125. bv.maxForce = Vector3.new(1e9, 1e9, 1e9)
  1126. bv.velocity = CF(POSITION,TORSO.Position).lookVector*FLING
  1127. bv.Parent = c
  1128. Debris:AddItem(bv,0.05)
  1129. end
  1130. end
  1131. end
  1132. end
  1133. end
  1134. end
  1135. end
  1136. end
  1137. end
  1138.  
  1139. function APPLYMELEE(PART,MINDMG,MAXDMG)
  1140. local HITS = {}
  1141. local TOUCH = PART.Touched:Connect(function(hit)
  1142. if hit.Parent:FindFirstChildOfClass("Humanoid") then
  1143. local HUM = hit.Parent:FindFirstChildOfClass("Humanoid")
  1144. local TORSO = hit.Parent:FindFirstChild("Torso") or hit.Parent:FindFirstChild("UpperTorso")
  1145. if TORSO and HUM.Health > 0 then
  1146. local PASS = true
  1147. for i = 1, #HITS do
  1148. if HITS[i] == hit.Parent then
  1149. PASS = false
  1150. end
  1151. end
  1152. table.insert(HITS,hit.Parent)
  1153. if PASS == true then
  1154. ApplyDamage(HUM,MRANDOM(MINDMG,MAXDMG),TORSO)
  1155. CreateSound(HITPLAYERSOUNDS[MRANDOM(1,#HITPLAYERSOUNDS)],TORSO,2,MRANDOM(8,12)/10,false)
  1156. end
  1157. end
  1158. end
  1159. end)
  1160. return TOUCH
  1161. end
  1162.  
  1163. --//=================================\\
  1164. --|| ATTACK FUNCTIONS AND STUFF
  1165. --\\=================================//
  1166.  
  1167. function Combo()
  1168. ATTACK = true
  1169. Rooted = false
  1170. if COMBO == 1 then
  1171. local KATANA = SWORD:Clone()
  1172. KATANA.Parent = Effects
  1173. CreateSound(ICESPAWNS[MRANDOM(1,#ICESPAWNS)],KATANA,3,2,false)
  1174. CreateWeldOrSnapOrMotor("Weld", RightArm, RightArm, KATANA, CF(0,-1,-KATANA.Size.Z/2) * ANGLES(RAD(0), RAD(180), RAD(90)), CF(0, 0, 0))
  1175. for i=0, 0.5, 0.1 / Animation_Speed do
  1176. Swait()
  1177. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(-35)), 1 / Animation_Speed)
  1178. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(35)), 1 / Animation_Speed)
  1179. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(90)) * ANGLES(RAD(0), RAD(180), RAD(0)) * RIGHTSHOULDERC0, 1 / Animation_Speed)
  1180. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(-12)) * LEFTSHOULDERC0, 1 / Animation_Speed)
  1181. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, 0) * ANGLES(RAD(0), RAD(80), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 1 / Animation_Speed)
  1182. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 1 / Animation_Speed)
  1183. end
  1184. local SWORDY = APPLYMELEE(KATANA,15,20)
  1185. for i=0, 0.5, 0.1 / Animation_Speed do
  1186. Swait()
  1187. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(55)), 1 / Animation_Speed)
  1188. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(-55)), 1 / Animation_Speed)
  1189. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1, 0.5, -0.5) * ANGLES(RAD(0), RAD(0), RAD(-45)) * ANGLES(RAD(0), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 1 / Animation_Speed)
  1190. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(-5), RAD(0), RAD(-42)) * LEFTSHOULDERC0, 1 / Animation_Speed)
  1191. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, 0) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 1 / Animation_Speed)
  1192. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0) * ANGLES(RAD(0), RAD(-60), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 1 / Animation_Speed)
  1193. end
  1194. KATANA:remove()
  1195. SWORDY:Disconnect()
  1196. COMBO = 2
  1197. elseif COMBO == 2 then
  1198. local SPEAR2 = SPEAR:Clone()
  1199. SPEAR2.Parent = Effects
  1200. CreateSound(ICESPAWNS[MRANDOM(1,#ICESPAWNS)],SPEAR2,3,2,false)
  1201. local WELD = CreateWeldOrSnapOrMotor("Weld", RightArm, RightArm, SPEAR2, CF(0,-1,-1.2), CF(0, 0, 0))
  1202. for i=0, 0.1, 0.1 / Animation_Speed do
  1203. Swait()
  1204. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0.1, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(-35)), 1 / Animation_Speed)
  1205. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(35)), 1 / Animation_Speed)
  1206. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(90)) * RIGHTSHOULDERC0, 2 / Animation_Speed)
  1207. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(-12)) * LEFTSHOULDERC0, 1 / Animation_Speed)
  1208. RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.6 - 0.05 * COS(SINE / 12), -0.3) * ANGLES(RAD(0), RAD(80), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 1 / Animation_Speed)
  1209. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), 0) * ANGLES(RAD(0), RAD(-55), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 1 / Animation_Speed)
  1210. end
  1211. for i=0, 0.2, 0.1 / Animation_Speed do
  1212. Swait()
  1213. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0.1, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(-35)), 1 / Animation_Speed)
  1214. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(35)), 1 / Animation_Speed)
  1215. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(90)) * RIGHTSHOULDERC0, 2 / Animation_Speed)
  1216. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(-12)) * LEFTSHOULDERC0, 1 / Animation_Speed)
  1217. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), 0) * ANGLES(RAD(0), RAD(80), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 1 / Animation_Speed)
  1218. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), 0) * ANGLES(RAD(0), RAD(-55), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 1 / Animation_Speed)
  1219. end
  1220. local SWORDY = APPLYMELEE(SPEAR2,15,30)
  1221. for i=0, 0.6, 0.1 / Animation_Speed do
  1222. Swait()
  1223. WELD.C0 = Clerp(WELD.C0, CF(0,-4,-1.3) * ANGLES(RAD(-65), RAD(0), RAD(0)), 0.5)
  1224. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, -0.1, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(75)), 2 / Animation_Speed)
  1225. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(-55)), 2 / Animation_Speed)
  1226. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(90)) * RIGHTSHOULDERC0, 2 / Animation_Speed)
  1227. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(-12)) * LEFTSHOULDERC0, 2 / Animation_Speed)
  1228. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), 0) * ANGLES(RAD(0), RAD(80), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 2 / Animation_Speed)
  1229. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), 0) * ANGLES(RAD(0), RAD(-55), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 2 / Animation_Speed)
  1230. end
  1231. COMBO = 3
  1232. SPEAR2:remove()
  1233. SWORDY:Disconnect()
  1234. elseif COMBO == 3 then
  1235. COMBO = 1
  1236. Rooted = true
  1237. for i=0, 0.8, 0.1 / Animation_Speed do
  1238. Swait()
  1239. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(-15), RAD(0), RAD(0)),0.5 / Animation_Speed)
  1240. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 0.5 / Animation_Speed)
  1241. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.45, 0.75, 0) * ANGLES(RAD(160), RAD(-5), RAD(-12)) * RIGHTSHOULDERC0, 0.5 / Animation_Speed)
  1242. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.45, 0.75, 0) * ANGLES(RAD(160), RAD(5), RAD(12)) * LEFTSHOULDERC0, 0.5 / Animation_Speed)
  1243. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(-15), RAD(85), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.5 / Animation_Speed)
  1244. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(-15), RAD(-85), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.5 / Animation_Speed)
  1245. end
  1246. for i=0, 0.3, 0.1 / Animation_Speed do
  1247. Swait()
  1248. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0.2, -1 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(65), RAD(0), RAD(0)), 1 / Animation_Speed)
  1249. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed)
  1250. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.25, 0.5, -0.75) * ANGLES(RAD(75), RAD(0), RAD(-12)) * RIGHTSHOULDERC0, 1 / Animation_Speed)
  1251. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.25, 0.5, -0.75) * ANGLES(RAD(75), RAD(0), RAD(12)) * LEFTSHOULDERC0, 1 / Animation_Speed)
  1252. RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.4 - 0.05 * COS(SINE / 12), -0.5) * ANGLES(RAD(65), RAD(90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 1 / Animation_Speed)
  1253. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.4 - 0.05 * COS(SINE / 12), -0.5) * ANGLES(RAD(65), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 1 / Animation_Speed)
  1254. end
  1255. coroutine.resume(coroutine.create(function()
  1256. local HITFLOOR,HITPOS = Raycast(RootPart.Position, (CF(RootPart.Position, RootPart.Position + VT(0, -1, 0))).lookVector, 4, Character)
  1257. if HITFLOOR then
  1258. ApplyAoE(HITPOS,25,35,40,-2,false,true)
  1259. local ICES = {}
  1260. local ICE = CreatePart(3, Effects, "Ice", 0, 0, BRICKC("Light blue"), "Effect", VT(25,0.06,25), true)
  1261. MakeForm(ICE,"Cyl")
  1262. ICE.CFrame = CF(HITPOS)
  1263. table.insert(ICES,ICE)
  1264. CreateSound(BLASTS[MRANDOM(1,#BLASTS)], ICE, 5, MRANDOM(9,11)/10, false)
  1265. local ICE = CreatePart(3, Effects, "Ice", 0, 0.5, BRICKC("Light blue"), "Effect", VT(33,0,33), true)
  1266. MakeForm(ICE,"Cyl")
  1267. ICE.CFrame = CF(HITPOS)
  1268. table.insert(ICES,ICE)
  1269. for i = 1, 360 do
  1270. if MRANDOM(1,35) == 1 then
  1271. local ICESPIKE = IT("CornerWedgePart",Effects)
  1272. table.insert(ICES,ICESPIKE)
  1273. ICESPIKE.Anchored = true
  1274. ICESPIKE.Size = VT(6,MRANDOM(15,25),6)
  1275. ICESPIKE.Material = "Ice"
  1276. ICESPIKE.BrickColor = BRICKC("Light blue")
  1277. ICESPIKE.CanCollide =false
  1278. ICESPIKE.CFrame = CF(HITPOS) * ANGLES(RAD(0), RAD(i), RAD(0)) * CF(0,0,8) * ANGLES(RAD(35), RAD(MRANDOM(0,360)), RAD(0))
  1279. end
  1280. end
  1281. for i = 1, 360 do
  1282. if MRANDOM(1,50) == 1 then
  1283. local ICESPIKE = IT("CornerWedgePart",Effects)
  1284. table.insert(ICES,ICESPIKE)
  1285. ICESPIKE.Anchored = true
  1286. ICESPIKE.Size = VT(6,MRANDOM(20,35),6)
  1287. ICESPIKE.Material = "Ice"
  1288. ICESPIKE.BrickColor = BRICKC("Light blue")
  1289. ICESPIKE.CanCollide =false
  1290. ICESPIKE.CFrame = CF(HITPOS) * ANGLES(RAD(0), RAD(i), RAD(0)) * CF(0,0,15) * ANGLES(RAD(35), RAD(MRANDOM(0,360)), RAD(0))
  1291. end
  1292. end
  1293. wait(5)
  1294. for i = 1, 45 do
  1295. Swait()
  1296. for E = 1, #ICES do
  1297. ICES[E].Transparency = ICES[E].Transparency + 1/45
  1298. end
  1299. end
  1300. for E = 1, #ICES do
  1301. ICES[E]:remove()
  1302. end
  1303. end
  1304. end))
  1305. for i=0, 0.4, 0.1 / Animation_Speed do
  1306. Swait()
  1307. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0.2, -1 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(65), RAD(0), RAD(0)), 1 / Animation_Speed)
  1308. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed)
  1309. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.25, 0.5, -0.75) * ANGLES(RAD(75), RAD(0), RAD(-12)) * RIGHTSHOULDERC0, 1 / Animation_Speed)
  1310. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.25, 0.5, -0.75) * ANGLES(RAD(75), RAD(0), RAD(12)) * LEFTSHOULDERC0, 1 / Animation_Speed)
  1311. RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.4 - 0.05 * COS(SINE / 12), -0.5) * ANGLES(RAD(65), RAD(90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 1 / Animation_Speed)
  1312. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.4 - 0.05 * COS(SINE / 12), -0.5) * ANGLES(RAD(65), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 1 / Animation_Speed)
  1313. end
  1314. end
  1315. coroutine.resume(coroutine.create(function()
  1316. for i = 1, 50 do
  1317. Swait()
  1318. if ATTACK == true then
  1319. break
  1320. end
  1321. end
  1322. if ATTACK == false then
  1323. COMBO = 1
  1324. end
  1325. end))
  1326. ATTACK = false
  1327. Rooted = false
  1328. end
  1329. function AttackTemplate()
  1330. ATTACK = true
  1331. Rooted = false
  1332. for i=0, 1, 0.1 / Animation_Speed do
  1333. Swait()
  1334. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed)
  1335. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed)
  1336. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(12)) * RIGHTSHOULDERC0, 1 / Animation_Speed)
  1337. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(-12)) * LEFTSHOULDERC0, 1 / Animation_Speed)
  1338. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 1 / Animation_Speed)
  1339. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 1 / Animation_Speed)
  1340. end
  1341. ATTACK = false
  1342. Rooted = false
  1343. end
  1344. function AttackTemplate()
  1345. ATTACK = true
  1346. Rooted = false
  1347. for i=0, 1, 0.1 / Animation_Speed do
  1348. Swait()
  1349. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed)
  1350. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed)
  1351. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(12)) * RIGHTSHOULDERC0, 1 / Animation_Speed)
  1352. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(-12)) * LEFTSHOULDERC0, 1 / Animation_Speed)
  1353. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 1 / Animation_Speed)
  1354. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 1 / Animation_Speed)
  1355. end
  1356. ATTACK = false
  1357. Rooted = false
  1358. end
  1359. function AttackTemplate()
  1360. ATTACK = true
  1361. Rooted = false
  1362. for i=0, 1, 0.1 / Animation_Speed do
  1363. Swait()
  1364. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed)
  1365. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed)
  1366. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(12)) * RIGHTSHOULDERC0, 1 / Animation_Speed)
  1367. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(-12)) * LEFTSHOULDERC0, 1 / Animation_Speed)
  1368. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 1 / Animation_Speed)
  1369. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 1 / Animation_Speed)
  1370. end
  1371. ATTACK = false
  1372. Rooted = false
  1373. end
  1374.  
  1375. --//=================================\\
  1376. --|| ASSIGN THINGS TO KEYS
  1377. --\\=================================//
  1378.  
  1379. function MouseDown(Mouse)
  1380. HOLD = true
  1381. if ATTACK == false then
  1382. Combo()
  1383. end
  1384. end
  1385.  
  1386. function MouseUp(Mouse)
  1387. HOLD = false
  1388. end
  1389.  
  1390. local DOUBLE = false
  1391.  
  1392. function KeyDown(Key)
  1393. KEYHOLD = true
  1394. if Key == "z" and ATTACK == false then
  1395. ApplyAoE(Torso.Position,6,5,7,15,true)
  1396. end
  1397.  
  1398. if Key == "b" and ATTACK == false then
  1399. end
  1400.  
  1401. if Key == "c" and ATTACK == false then
  1402. end
  1403.  
  1404. if Key == "v" and ATTACK == false then
  1405. end
  1406.  
  1407. if Key == "x" and ATTACK == false then
  1408. end
  1409.  
  1410. if Key == "1" then
  1411. sick:Play()
  1412. CHOICE = CHOICE + 1
  1413. if CHOICE > #SONGS then
  1414. CHOICE = 1
  1415. end
  1416. end
  1417.  
  1418. if string.byte(Key) == 32 and ATTACK == false and Humanoid.Jump == true then
  1419. local HITFLOOR = Raycast(RootPart.Position, (CF(RootPart.Position, RootPart.Position + VT(0, -1, 0))).lookVector, 6, Character)
  1420. if HITFLOOR == nil and DOUBLE == false then
  1421. DOUBLE = true
  1422. RootPart.Velocity = VT(RootPart.Velocity.X,160,RootPart.Velocity.Z)
  1423. coroutine.resume(coroutine.create(function()
  1424. local RWING = WINGPART:Clone()
  1425. local LWING = WINGPART:Clone()
  1426. RWING.Parent = Effects
  1427. LWING.Parent = Effects
  1428. local RWELD = CreateWeldOrSnapOrMotor("Weld", Torso, Torso, RWING, CF(-1, 1, 0.75)*ANGLES(RAD(0),RAD(0),RAD(0))*ANGLES(RAD(0),RAD(25),RAD(0)), CF(1.5, -0.5, 0))
  1429. local LWELD = CreateWeldOrSnapOrMotor("Weld", Torso, Torso, LWING, CF(1, 1, 0.75)*ANGLES(RAD(0),RAD(180),RAD(0))*ANGLES(RAD(0),RAD(-25),RAD(0)), CF(1.5, -0.5, 0))
  1430. Speed = 50
  1431. CreateSound(ICESPAWNS[MRANDOM(1,#ICESPAWNS)],RWING,3,1,false)
  1432. CreateSound(ICESPAWNS[MRANDOM(1,#ICESPAWNS)],LWING,3,1,false)
  1433. WaveParticles(Torso.Position,8,C3(1,1,1))
  1434. for i = 1, 45 do
  1435. Swait()
  1436. RWELD.C1 = Clerp(RWELD.C1, CF(1.5, -0.5, 0)*ANGLES(RAD(0),RAD(0),RAD(-35)),0.3)
  1437. LWELD.C1 = Clerp(LWELD.C1, CF(1.5, -0.5, 0)*ANGLES(RAD(0),RAD(0),RAD(-35)),0.3)
  1438. RWING.Transparency = RWING.Transparency + 1/45
  1439. LWING.Transparency = RWING.Transparency
  1440. end
  1441. Debris:AddItem(RWING,4)
  1442. Debris:AddItem(LWING,4)
  1443. Speed = 16
  1444. DOUBLE = false
  1445. end))
  1446. end
  1447. end
  1448. end
  1449.  
  1450. function KeyUp(Key)
  1451. KEYHOLD = false
  1452. end
  1453.  
  1454. Mouse.Button1Down:connect(function(NEWKEY)
  1455. MouseDown(NEWKEY)
  1456. end)
  1457. Mouse.Button1Up:connect(function(NEWKEY)
  1458. MouseUp(NEWKEY)
  1459. end)
  1460. Mouse.KeyDown:connect(function(NEWKEY)
  1461. KeyDown(NEWKEY)
  1462. end)
  1463. Mouse.KeyUp:connect(function(NEWKEY)
  1464. KeyUp(NEWKEY)
  1465. end)
  1466.  
  1467. --//=================================\\
  1468. --\\=================================//
  1469.  
  1470. function unanchor()
  1471. for _, c in pairs(Character:GetChildren()) do
  1472. if c:IsA("BasePart") and c ~= RootPart then
  1473. c.Anchored = false
  1474. end
  1475. end
  1476. if UNANCHOR == true then
  1477. RootPart.Anchored = false
  1478. else
  1479. RootPart.Anchored = true
  1480. end
  1481. end
  1482.  
  1483. --//=================================\\
  1484. --|| WRAP THE WHOLE SCRIPT UP
  1485. --\\=================================//
  1486.  
  1487. Humanoid.Changed:connect(function(Jump)
  1488. if Jump == "Jump" and (Disable_Jump == true) then
  1489. Humanoid.Jump = false
  1490. end
  1491. end)
  1492.  
  1493. while true do
  1494. Swait()
  1495. script.Parent = WEAPONGUI
  1496. ANIMATE.Parent = nil
  1497. for _,v in next, Humanoid:GetPlayingAnimationTracks() do
  1498. v:Stop();
  1499. end
  1500. SINE = SINE + CHANGE
  1501. local TORSOVELOCITY = (RootPart.Velocity * VT(1, 0, 1)).magnitude
  1502. local TORSOVERTICALVELOCITY = RootPart.Velocity.y
  1503. local HITFLOOR = Raycast(RootPart.Position, (CF(RootPart.Position, RootPart.Position + VT(0, -1, 0))).lookVector, 4, Character)
  1504. local WALKSPEEDVALUE = 4
  1505. if ANIM == "Walk" and TORSOVELOCITY > 1 then
  1506. RootJoint.C1 = Clerp(RootJoint.C1, ROOTC0 * CF(0, 0, -0.07 * COS(SINE / (WALKSPEEDVALUE / 2))) * ANGLES(RAD(0), RAD(0) - RootPart.RotVelocity.Y / 75, RAD(0)), 2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
  1507. Neck.C1 = Clerp(Neck.C1, CF(0, -0.5, 0) * ANGLES(RAD(-90), RAD(0), RAD(180)) * ANGLES(RAD(2.5 * SIN(SINE / (WALKSPEEDVALUE / 2))), RAD(0), RAD(0) - Head.RotVelocity.Y / 30), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
  1508. RightHip.C1 = Clerp(RightHip.C1, CF(0.5, 0.875 - 0.115 * SIN(SINE / WALKSPEEDVALUE) - 0.15 * COS(SINE / WALKSPEEDVALUE*2), -0.125 * COS(SINE / WALKSPEEDVALUE) +0.2-0.2 * SIN(SINE / WALKSPEEDVALUE)) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0) - RightLeg.RotVelocity.Y / 75, RAD(0), RAD(50 * COS(SINE / WALKSPEEDVALUE))), 0.6 / Animation_Speed)
  1509. LeftHip.C1 = Clerp(LeftHip.C1, CF(-0.5, 0.875 + 0.115 * SIN(SINE / WALKSPEEDVALUE) - 0.15 * COS(SINE / WALKSPEEDVALUE*2), 0.125 * COS(SINE / WALKSPEEDVALUE) +0.2+0.2 * SIN(SINE / WALKSPEEDVALUE)) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0) + LeftLeg.RotVelocity.Y / 75, RAD(0), RAD(50 * COS(SINE / WALKSPEEDVALUE))), 0.6 / Animation_Speed)
  1510. elseif (ANIM ~= "Walk") or (TORSOVELOCITY < 1) then
  1511. RootJoint.C1 = Clerp(RootJoint.C1, ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed)
  1512. Neck.C1 = Clerp(Neck.C1, CF(0, -0.5, 0) * ANGLES(RAD(-90), RAD(0), RAD(180)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed)
  1513. RightHip.C1 = Clerp(RightHip.C1, CF(0.5, 1, 0) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed)
  1514. LeftHip.C1 = Clerp(LeftHip.C1, CF(-0.5, 1, 0) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed)
  1515. end
  1516. if TORSOVERTICALVELOCITY > 1 and HITFLOOR == nil then
  1517. if ATTACK == false then
  1518. ANIM = "Jump"
  1519. RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0, 0, 0 ) * ANGLES(RAD(-5), RAD(0), RAD(0)), 1 / Animation_Speed)
  1520. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0 , 0 + ((1) - 1)) * ANGLES(RAD(-25), RAD(0), RAD(0)), 1 / Animation_Speed)
  1521. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(-25), RAD(0), RAD(25 + 10 * COS(SINE / 12))) * RIGHTSHOULDERC0, 1 / Animation_Speed)
  1522. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(-25), RAD(0), RAD(-25 - 10 * COS(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed)
  1523. RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.4, -0.6) * ANGLES(RAD(1), RAD(90), RAD(0)) * ANGLES(RAD(-1 * SIN(SINE / 6)), RAD(0), RAD(0)), 1 / Animation_Speed)
  1524. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0) * ANGLES(RAD(0), RAD(-85), RAD(0)) * ANGLES(RAD(-1 * SIN(SINE / 6)), RAD(0), RAD(0)), 1 / Animation_Speed)
  1525. end
  1526. elseif TORSOVERTICALVELOCITY < -1 and HITFLOOR == nil then
  1527. if ATTACK == false then
  1528. ANIM = "Fall"
  1529. RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0, 0, 0 ) * ANGLES(RAD(15), RAD(0), RAD(0)), 1 / Animation_Speed)
  1530. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0 , 0 + ((1) - 1)) * ANGLES(RAD(15), RAD(0), RAD(0)), 1 / Animation_Speed)
  1531. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(35 - 4 * COS(SINE / 6)), RAD(0), RAD(45 + 10 * COS(SINE / 12))) * RIGHTSHOULDERC0, 1 / Animation_Speed)
  1532. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(35 - 4 * COS(SINE / 6)), RAD(0), RAD(-45 - 10 * COS(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed)
  1533. RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.3, -0.7) * ANGLES(RAD(-25 + 5 * SIN(SINE / 12)), RAD(90), RAD(0)) * ANGLES(RAD(-1 * SIN(SINE / 6)), RAD(0), RAD(0)), 1 / Animation_Speed)
  1534. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.8, -0.3) * ANGLES(RAD(-10), RAD(-80), RAD(0)) * ANGLES(RAD(-1 * SIN(SINE / 6)), RAD(0), RAD(0)), 1 / Animation_Speed)
  1535. end
  1536. elseif TORSOVELOCITY < 1 and HITFLOOR ~= nil then
  1537. if ATTACK == false then
  1538. ANIM = "Idle"
  1539. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0.3 + 0.05 * COS(SINE / 6)) * ANGLES(RAD(-5), RAD(0), RAD(0)), 1 / Animation_Speed)
  1540. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(15*COS(SINE / 12))), 1 / Animation_Speed)
  1541. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5 + 0.25 * COS(SINE / 12), 0) * ANGLES(RAD(0), RAD(-25), RAD(8+8*COS(SINE / 12))) * RIGHTSHOULDERC0, 1 / Animation_Speed)
  1542. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5 + 0.25 * COS(SINE / 12), 0) * ANGLES(RAD(0), RAD(25), RAD(-8-8*COS(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed)
  1543. RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.8 - 0.05 * SIN(SINE / 6), -0.2) * ANGLES(RAD(-10), RAD(80), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed)
  1544. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * SIN(SINE / 6), 0) * ANGLES(RAD(-4), RAD(-80), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 1 / Animation_Speed)
  1545. end
  1546. elseif TORSOVELOCITY > 1 and HITFLOOR ~= nil then
  1547. if ATTACK == false then
  1548. ANIM = "Walk"
  1549. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, -0.05) * ANGLES(RAD(5 + 2 * SIN(SINE / (WALKSPEEDVALUE / 2))), RAD(0), RAD(0)), 1 / Animation_Speed)
  1550. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(5 - 1 * SIN(SINE / (WALKSPEEDVALUE / 2))), RAD(0), RAD(0)), 1 / Animation_Speed)
  1551. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, -0.25 * COS(SINE / WALKSPEEDVALUE)) * ANGLES(RAD(40 * COS(SINE / WALKSPEEDVALUE)), RAD(0), RAD(5)) * RIGHTSHOULDERC0, 1 / Animation_Speed)
  1552. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0.25 * COS(SINE / WALKSPEEDVALUE)) * ANGLES(RAD(-40 * COS(SINE / WALKSPEEDVALUE)), RAD(0), RAD(-5)) * LEFTSHOULDERC0, 1 / Animation_Speed)
  1553. RightHip.C0 = Clerp(RightHip.C0, CF(1 , -1, 0) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(-15)), 2 / Animation_Speed)
  1554. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(15)), 2 / Animation_Speed)
  1555. end
  1556. end
  1557. if ATTACK == true then
  1558. ANIM = "Custom"
  1559. end
  1560. if 15*COS(SINE / 24) <= 1 and 15*COS(SINE / 24) >= 0 then
  1561. if ANIM == "Idle" or ANIM == "Jump" then
  1562. CreateSound(519971384,Head,5,MRANDOM(8,12)/10,false)
  1563. BREATH:Emit(20)
  1564. end
  1565. end
  1566. unanchor()
  1567. Humanoid.MaxHealth = "inf"
  1568. Humanoid.Health = "inf"
  1569. if Rooted == false then
  1570. Disable_Jump = false
  1571. Humanoid.WalkSpeed = Speed
  1572. elseif Rooted == true then
  1573. Disable_Jump = true
  1574. Humanoid.WalkSpeed = 0
  1575. end
  1576. for _, c in pairs(Character:GetChildren()) do
  1577. if c.ClassName == "CharacterMesh" or c.ClassName == "Accessory" or c.Name == "Body Colors" then
  1578. c:remove()
  1579. end
  1580. end
  1581. sick.SoundId = "rbxassetid://"..SONGS[CHOICE][1]
  1582. sick.Looped = true
  1583. sick.Pitch = 1
  1584. sick.Volume = SONGS[CHOICE][2]
  1585. sick.Parent = Torso
  1586. sick.Playing = true
  1587. refit()
  1588. end
  1589.  
  1590. --//=================================\\
  1591. --\\=================================//
  1592.  
  1593.  
  1594.  
  1595.  
  1596.  
  1597. --//====================================================\\--
  1598. --|| END OF SCRIPT
  1599. --\\====================================================//--
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement