Advertisement
RblxVoidScriptBuild

sans

Apr 1st, 2019
198
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 57.43 KB | None | 0 0
  1. if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
  2. local Player,Mouse,mouse,UserInputService,ContextActionService = owner
  3. do
  4. print("FE Compatibility code by Mokiros")
  5. script.Parent = Player.Character
  6.  
  7. --RemoteEvent for communicating
  8. local Event = Instance.new("RemoteEvent")
  9. Event.Name = "UserInput_Event"
  10.  
  11. --Fake event to make stuff like Mouse.KeyDown work
  12. local function fakeEvent()
  13. local t = {_fakeEvent=true,Connect=function(self,f)self.Function=f end}
  14. t.connect = t.Connect
  15. return t
  16. end
  17.  
  18. --Creating fake input objects with fake variables
  19. local m = {Target=nil,Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent()}
  20. local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()}
  21. local CAS = {Actions={},BindAction=function(self,name,fun,touch,...)
  22. CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil
  23. end}
  24. --Merged 2 functions into one by checking amount of arguments
  25. CAS.UnbindAction = CAS.BindAction
  26.  
  27. --This function will trigger the events that have been :Connect()'ed
  28. local function te(self,ev,...)
  29. local t = m[ev]
  30. if t and t._fakeEvent and t.Function then
  31. t.Function(...)
  32. end
  33. end
  34. m.TrigEvent = te
  35. UIS.TrigEvent = te
  36.  
  37. Event.OnServerEvent:Connect(function(plr,io)
  38. if plr~=Player then return end
  39. if io.isMouse then
  40. m.Target = io.Target
  41. m.Hit = io.Hit
  42. else
  43. local b = io.UserInputState == Enum.UserInputState.Begin
  44. if io.UserInputType == Enum.UserInputType.MouseButton1 then
  45. return m:TrigEvent(b and "Button1Down" or "Button1Up")
  46. end
  47. for _,t in pairs(CAS.Actions) do
  48. for _,k in pairs(t.Keys) do
  49. if k==io.KeyCode then
  50. t.Function(t.Name,io.UserInputState,io)
  51. end
  52. end
  53. end
  54. m:TrigEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower())
  55. UIS:TrigEvent(b and "InputBegan" or "InputEnded",io,false)
  56. end
  57. end)
  58. Event.Parent = NLS([==[
  59. local Player = game:GetService("Players").LocalPlayer
  60. local Event = script:WaitForChild("UserInput_Event")
  61.  
  62. local UIS = game:GetService("UserInputService")
  63. local input = function(io,a)
  64. if a then return end
  65. --Since InputObject is a client-side instance, we create and pass table instead
  66. Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState})
  67. end
  68. UIS.InputBegan:Connect(input)
  69. UIS.InputEnded:Connect(input)
  70.  
  71. local Mouse = Player:GetMouse()
  72. local h,t
  73. --Give the server mouse data 30 times every second, but only if the values changed
  74. --If player is not moving their mouse, client won't fire events
  75. while wait(1/30) do
  76. if h~=Mouse.Hit or t~=Mouse.Target then
  77. h,t=Mouse.Hit,Mouse.Target
  78. Event:FireServer({isMouse=true,Target=t,Hit=h})
  79. end
  80. end]==],Player.Character)
  81. Mouse,mouse,UserInputService,ContextActionService = m,m,UIS,CAS
  82. end
  83.  
  84. -- Created by Nebula_Zorua --
  85. -- Sans Curse (A Curse of Light) --
  86. -- Custom Arcane Adventures Magic --
  87. -- Wielder: Everybody (Released) --
  88. -- Why the fuck did I make this --
  89. -- I don't even LIKE undertale --
  90. -- what the fuck --
  91.  
  92. -- Discord: Nebula the Zorua#6969
  93. -- Youtube: https://www.youtube.com/channel/UCo9oU9dCw8jnuVLuy4_SATA
  94.  
  95. -- You can change the Magic Circle n stuff down under Customization, at MagicVariant --
  96.  
  97.  
  98. --// Shortcut Variables \\--
  99. local S = setmetatable({},{__index = function(s,i) return game:service(i) end})
  100. local CF = {N=CFrame.new,A=CFrame.Angles,fEA=CFrame.fromEulerAnglesXYZ}
  101. local C3 = {N=Color3.new,RGB=Color3.fromRGB,HSV=Color3.fromHSV,tHSV=Color3.toHSV}
  102. local V3 = {N=Vector3.new,FNI=Vector3.FromNormalId,A=Vector3.FromAxis}
  103. local M = {C=math.cos,R=math.rad,S=math.sin,P=math.pi,RNG=math.random,MRS=math.randomseed,H=math.huge,RRNG = function(min,max,div) return math.rad(math.random(min,max)/(div or 1)) end}
  104. local R3 = {N=Region3.new}
  105. local De = S.Debris
  106. local WS = workspace
  107. local Lght = S.Lighting
  108. local RepS = S.ReplicatedStorage
  109. local IN = Instance.new
  110. local Plrs = S.Players
  111.  
  112. local Emit = IN("ParticleEmitter").Emit;
  113.  
  114. --// Initializing \\--
  115. local Plr = owner
  116. local Char = Player.Character
  117. local Hum = Char:FindFirstChildOfClass'Humanoid'
  118. local RArm = Char["Right Arm"]
  119. local LArm = Char["Left Arm"]
  120. local RLeg = Char["Right Leg"]
  121. local LLeg = Char["Left Leg"]
  122. local Root = Char:FindFirstChild'HumanoidRootPart'
  123. local Torso = Char.Torso
  124. local Head = Char.Head
  125. local NeutralAnims = true
  126. local Attack = false
  127. local Debounces = {Debounces={}}
  128. local Hit = {}
  129. local Sine = 0
  130. local Change = 1
  131.  
  132. local Effects = IN("Folder",Char)
  133. Effects.Name = "Effects"
  134.  
  135.  
  136. --// Debounce System \\--
  137.  
  138.  
  139. function Debounces:New(name,cooldown)
  140. local aaaaa = {Usable=true,Cooldown=cooldown or 2,CoolingDown=false,LastUse=0}
  141. setmetatable(aaaaa,{__index = Debounces})
  142. Debounces.Debounces[name] = aaaaa
  143. return aaaaa
  144. end
  145.  
  146. function Debounces:Use(overrideUsable)
  147. assert(self.Usable ~= nil and self.LastUse ~= nil and self.CoolingDown ~= nil,"Expected ':' not '.' calling member function Use")
  148. if(self.Usable or overrideUsable)then
  149. self.Usable = false
  150. self.CoolingDown = true
  151. local LastUse = time()
  152. self.LastUse = LastUse
  153. delay(self.Cooldown or 2,function()
  154. if(self.LastUse == LastUse)then
  155. self.CoolingDown = false
  156. self.Usable = true
  157. end
  158. end)
  159. end
  160. end
  161.  
  162. function Debounces:Get(name)
  163. assert(typeof(name) == 'string',("bad argument #1 to 'get' (string expected, got %s)"):format(typeof(name) == nil and "no value" or typeof(name)))
  164. for i,v in next, Debounces.Debounces do
  165. if(i == name)then
  166. return v;
  167. end
  168. end
  169. end
  170.  
  171. function Debounces:GetProgressPercentage()
  172. assert(self.Usable ~= nil and self.LastUse ~= nil and self.CoolingDown ~= nil,"Expected ':' not '.' calling member function Use")
  173. if(self.CoolingDown and not self.Usable)then
  174. return math.max(
  175. math.floor(
  176. (
  177. (time()-self.LastUse)/self.Cooldown or 2
  178. )*100
  179. )
  180. )
  181. else
  182. return 100
  183. end
  184. end
  185.  
  186. --// Instance Creation Functions \\--
  187.  
  188. function Sound(parent,id,pitch,volume,looped,effect,autoPlay)
  189. local Sound = IN("Sound")
  190. Sound.SoundId = "rbxassetid://".. tostring(id or 0)
  191. Sound.Pitch = pitch or 1
  192. Sound.Volume = volume or 1
  193. Sound.Looped = looped or false
  194. if(autoPlay)then
  195. coroutine.wrap(function()
  196. repeat wait() until Sound.IsLoaded
  197. Sound.Playing = autoPlay or false
  198. end)()
  199. end
  200. if(not looped and effect)then
  201. Sound.Stopped:connect(function()
  202. Sound.Volume = 0
  203. Sound:destroy()
  204. end)
  205. elseif(effect)then
  206. warn("Sound can't be looped and a sound effect!")
  207. end
  208. Sound.Parent =parent or Torso
  209. return Sound
  210. end
  211. function Part(parent,color,material,size,cframe,anchored,cancollide)
  212. local part = IN("Part")
  213. part.Parent = parent or Char
  214. part[typeof(color) == 'BrickColor' and 'BrickColor' or 'Color'] = color or C3.N(0,0,0)
  215. part.Material = material or Enum.Material.SmoothPlastic
  216. part.TopSurface,part.BottomSurface=10,10
  217. part.Size = size or V3.N(1,1,1)
  218. part.CFrame = cframe or CF.N(0,0,0)
  219. part.CanCollide = cancollide or false
  220. part.Anchored = anchored or false
  221. return part
  222. end
  223.  
  224. function Weld(part0,part1,c0,c1)
  225. local weld = IN("Weld")
  226. weld.Parent = part0
  227. weld.Part0 = part0
  228. weld.Part1 = part1
  229. weld.C0 = c0 or CF.N()
  230. weld.C1 = c1 or CF.N()
  231. return weld
  232. end
  233.  
  234. function Mesh(parent,meshtype,meshid,textid,scale,offset)
  235. local part = IN("SpecialMesh")
  236. part.MeshId = meshid or ""
  237. part.TextureId = textid or ""
  238. part.Scale = scale or V3.N(1,1,1)
  239. part.Offset = offset or V3.N(0,0,0)
  240. part.MeshType = meshtype or Enum.MeshType.Sphere
  241. part.Parent = parent
  242. return part
  243. end
  244.  
  245. NewInstance = function(instance,parent,properties)
  246. local inst = Instance.new(instance)
  247. inst.Parent = parent
  248. if(properties)then
  249. for i,v in next, properties do
  250. pcall(function() inst[i] = v end)
  251. end
  252. end
  253. return inst;
  254. end
  255.  
  256. function Clone(instance,parent,properties)
  257. local inst = instance:Clone()
  258. inst.Parent = parent
  259. if(properties)then
  260. for i,v in next, properties do
  261. pcall(function() inst[i] = v end)
  262. end
  263. end
  264. return inst;
  265. end
  266.  
  267. function SoundPart(id,pitch,volume,looped,effect,autoPlay,cf)
  268. local soundPart = NewInstance("Part",Effects,{Transparency=1,CFrame=cf or Torso.CFrame,Anchored=true,CanCollide=false,Size=V3.N()})
  269. local Sound = IN("Sound")
  270. Sound.SoundId = "rbxassetid://".. tostring(id or 0)
  271. Sound.Pitch = pitch or 1
  272. Sound.Volume = volume or 1
  273. Sound.Looped = looped or false
  274. if(autoPlay)then
  275. coroutine.wrap(function()
  276. repeat wait() until Sound.IsLoaded
  277. Sound.Playing = autoPlay or false
  278. end)()
  279. end
  280. if(not looped and effect)then
  281. Sound.Stopped:connect(function()
  282. Sound.Volume = 0
  283. soundPart:destroy()
  284. end)
  285. elseif(effect)then
  286. warn("Sound can't be looped and a sound effect!")
  287. end
  288. Sound.Parent = soundPart
  289. return Sound
  290. end
  291.  
  292.  
  293. --// Extended ROBLOX tables \\--
  294. local Instance = setmetatable({ClearChildrenOfClass = function(where,class,recursive) local children = (recursive and where:GetDescendants() or where:GetChildren()) for _,v in next, children do if(v:IsA(class))then v:destroy();end;end;end},{__index = Instance})
  295. --// Require stuff \\--
  296. function CamShake(who,times,intense,origin)
  297. coroutine.wrap(function()
  298. if(script:FindFirstChild'CamShake')then
  299. local cam = script.CamShake:Clone()
  300. cam:WaitForChild'intensity'.Value = intense
  301. cam:WaitForChild'times'.Value = times
  302.  
  303. if(origin)then NewInstance((typeof(origin) == 'Instance' and "ObjectValue" or typeof(origin) == 'Vector3' and 'Vector3Value'),cam,{Name='origin',Value=origin}) end
  304. cam.Parent = who
  305. wait()
  306. cam.Disabled = false
  307. elseif(who == Plr or who == Char)then
  308. local intensity = intense
  309. local cam = workspace.CurrentCamera
  310. for i = 1, times do
  311. local camDistFromOrigin
  312. if(typeof(origin) == 'Instance' and origin:IsA'BasePart')then
  313. camDistFromOrigin = math.floor( (cam.CFrame.p-origin.Position).magnitude )/25
  314. elseif(typeof(origin) == 'Vector3')then
  315. camDistFromOrigin = math.floor( (cam.CFrame.p-origin).magnitude )/25
  316. end
  317. if(camDistFromOrigin)then
  318. intensity = math.min(intense, math.floor(intense/camDistFromOrigin))
  319. end
  320. cam.CFrame = cam.CFrame:lerp(cam.CFrame*CFrame.new(math.random(-intensity,intensity)/100,math.random(-intensity,intensity)/100,math.random(-intensity,intensity)/100)*CFrame.Angles(math.rad(math.random(-intensity,intensity)/100),math.rad(math.random(-intensity,intensity)/100),math.rad(math.random(-intensity,intensity)/100)),.4)
  321. swait()
  322. end
  323. end
  324. end)()
  325. end
  326.  
  327. function CamShakeAll(times,intense,origin)
  328. for _,v in next, Plrs:players() do
  329. CamShake(v:FindFirstChildOfClass'PlayerGui' or v:FindFirstChildOfClass'Backpack' or v.Character,times,intense,origin)
  330. end
  331. end
  332.  
  333. function ServerScript(code)
  334. if(script:FindFirstChild'Loadstring')then
  335. local load = script.Loadstring:Clone()
  336. load:WaitForChild'Sauce'.Value = code
  337. load.Disabled = false
  338. load.Parent = workspace
  339. elseif(NS and typeof(NS) == 'function')then
  340. NS(code,workspace)
  341. else
  342. warn("no serverscripts lol")
  343. end
  344. end
  345.  
  346. function RunLocal(where,code)
  347. ServerScript([[
  348. wait()
  349. script.Parent=nil
  350. if(not _G.Http)then _G.Http = game:service'HttpService' end
  351.  
  352. local Http = _G.Http or game:service'HttpService'
  353.  
  354. local source = ]].."[["..code.."]]"..[[
  355. local link = "https://api.vorth.xyz/R_API/R.UPLOAD/NEW_LOCAL.php"
  356. local asd = Http:PostAsync(link,source)
  357. repeat wait() until asd and Http:JSONDecode(asd) and Http:JSONDecode(asd).Result and Http:JSONDecode(asd).Result.Require_ID
  358. local ID = Http:JSONDecode(asd).Result.Require_ID
  359. local vs = require(ID).VORTH_SCRIPT
  360. vs.Parent = game.]]..where:GetFullName()
  361. )
  362. end
  363.  
  364. --// Customization \\--
  365.  
  366. local Frame_Speed = 60;
  367. local WalkSpeed = 16
  368. local DamageColor = BrickColor.new'White'
  369.  
  370. local MagicCircles = {
  371. Default = {Color=C3.N(1,1,1),Texture1=0,Texture2=0},
  372. OrangeWarPheonix = {EffectColor=BrickColor.new'Deep orange'.Color,Color=C3.N(.9,.9,.9),Texture1=623153986,Texture2=623153990},
  373. BlueWarPheonix = {EffectColor=BrickColor.new'Teal'.Color,Color=C3.N(.9,.9,.9),Texture1=462499935,Texture2=462499970},
  374. Plasma = {Color=C3.N(0.70588235294118,0,0.8),Texture1=415906687,Texture2=415906702},
  375. Water = {Color=C3.RGB(33, 84, 185),Texture1=408441330,Texture2=408441353},
  376. Earth = {Color=C3.RGB(86, 36, 36),Texture1=394253616,Texture2=394253651},
  377. Wind = {Color=C3.N(.8,.8,.8),Texture1=376006317,Texture2=376006346},
  378. Poseidon = {Color=C3.RGB(71, 99, 130),Texture1=346727970,Texture2=346727994},
  379. AetherLightning = {Color=C3.RGB(23, 255, 197),Texture1=348320016,Texture2=348320030},
  380. Light = {Color=C3.N(1,1,0),Texture1=343192085,Texture2=343192112},
  381. Fire = {Color=C3.N(1,0,0),EffectColor=BrickColor.new'Bright red'.Color,Texture1=313945544,Texture2=313945673},
  382. Lightning = {Color=C3.N(0,1,1),Texture1=314842290,Texture2=314842440},
  383. GasterBlaster = {Color=C3.N(1,1,1),Texture1=331948662,Texture2=331948662}
  384. }
  385.  
  386. local MagicVariant = MagicCircles.GasterBlaster --[[ You can change this for a different element
  387. Example:
  388.  
  389. Changing MagicCircles.GasterBlaster to MagicCircles.Light
  390.  
  391. would make it a Light Element
  392. ]]
  393.  
  394. --// Stop animations \\--
  395. for _,v in next, Hum:GetPlayingAnimationTracks() do
  396. v:Stop();
  397. end
  398.  
  399. pcall(game.Destroy,Char:FindFirstChild'Animate')
  400. pcall(game.Destroy,Hum:FindFirstChild'Animator')
  401.  
  402. --// Joints \\--
  403.  
  404. local LS = NewInstance('Motor',Char,{Part0=Torso,Part1=LArm,C0 = CF.N(-1.5,0.5,0),C1 = CF.N(0,.5,0)})
  405. local RS = NewInstance('Motor',Char,{Part0=Torso,Part1=RArm,C0 = CF.N(1.5,0.5,0),C1 = CF.N(0,.5,0)})
  406. local NK = NewInstance('Motor',Char,{Part0=Torso,Part1=Head,C0 = CF.N(0,1.5,0)})
  407. local LH = NewInstance('Motor',Char,{Part0=Torso,Part1=LLeg,C0 = CF.N(-.5,-1,0),C1 = CF.N(0,1,0)})
  408. local RH = NewInstance('Motor',Char,{Part0=Torso,Part1=RLeg,C0 = CF.N(.5,-1,0),C1 = CF.N(0,1,0)})
  409. local RJ = NewInstance('Motor',Char,{Part0=Root,Part1=Torso})
  410.  
  411. local LSC0 = LS.C0
  412. local RSC0 = RS.C0
  413. local NKC0 = NK.C0
  414. local LHC0 = LH.C0
  415. local RHC0 = RH.C0
  416. local RJC0 = RJ.C0
  417.  
  418. --// Artificial HB \\--
  419.  
  420. local ArtificialHB = IN("BindableEvent", script)
  421. ArtificialHB.Name = "Heartbeat"
  422.  
  423. script:WaitForChild("Heartbeat")
  424.  
  425. local tf = 0
  426. local allowframeloss = false
  427. local tossremainder = false
  428. local lastframe = tick()
  429. local frame = 1/Frame_Speed
  430. ArtificialHB:Fire()
  431.  
  432. game:GetService("RunService").Heartbeat:connect(function(s, p)
  433. tf = tf + s
  434. if tf >= frame then
  435. if allowframeloss then
  436. script.Heartbeat:Fire()
  437. lastframe = tick()
  438. else
  439. for i = 1, math.floor(tf / frame) do
  440. ArtificialHB:Fire()
  441. end
  442. lastframe = tick()
  443. end
  444. if tossremainder then
  445. tf = 0
  446. else
  447. tf = tf - frame * math.floor(tf / frame)
  448. end
  449. end
  450. end)
  451.  
  452. function swait(num)
  453. if num == 0 or num == nil then
  454. ArtificialHB.Event:wait()
  455. else
  456. for i = 0, num do
  457. ArtificialHB.Event:wait()
  458. end
  459. end
  460. end
  461.  
  462.  
  463. --// Effect Function(s) \\--
  464.  
  465. function NumSeq(...)
  466. local tab = {...}
  467. local Sequence = {}
  468. for _,v in next, tab do
  469. table.insert(Sequence,NumberSequenceKeypoint.new(unpack(v)))
  470. end
  471. if(tab[#tab][1] ~= 1)then
  472. local final = tab[#tab]
  473. table.insert(Sequence,NumberSequenceKeypoint.new(1,final[2],final[3]))
  474. end
  475. return NumberSequence.new(Sequence)
  476. end
  477.  
  478. local DefaultRingParticle = IN("ParticleEmitter")
  479. DefaultRingParticle.Name = 'RingEmit'
  480. DefaultRingParticle.LightEmission = 1
  481. DefaultRingParticle.Size = NumSeq({0,0},{.7,6.28},{.8,5.03},{1,2.9})
  482. DefaultRingParticle.Texture = "rbxassetid://313951123"
  483. DefaultRingParticle.Transparency = NumberSequence.new(0,1)
  484. DefaultRingParticle.ZOffset = 1
  485. DefaultRingParticle.Drag = 0
  486. DefaultRingParticle.Acceleration = V3.N()
  487. DefaultRingParticle.LockedToPart = true
  488. DefaultRingParticle.Enabled = false
  489. DefaultRingParticle.Lifetime = NumberRange.new(.6,.6)
  490. DefaultRingParticle.Rate = 5
  491. DefaultRingParticle.Rotation = NumberRange.new(0,0)
  492. DefaultRingParticle.RotSpeed = NumberRange.new(0,0)
  493. DefaultRingParticle.Speed = NumberRange.new(0,0)
  494. DefaultRingParticle.SpreadAngle = Vector2.new(0,0)
  495.  
  496. function MagicCircle(Data)
  497. local Variant = Data.Variant or MagicCircles.Default;
  498.  
  499. local Size = Data.Size or 10;
  500. local Pos = Data.Pos*CF.A(M.R(-90),M.R(-90),0) or Torso.CFrame*CF.A(M.R(-90),M.R(-90),0);
  501. local GrowTime = Data.Time or 1;
  502.  
  503. local WeldData = Data.Weld or false;
  504.  
  505.  
  506. local Color = Variant.Color or C3.N(.9,.9,.0)
  507.  
  508. local CreationParticle = Data.CreationParticle or DefaultRingParticle;
  509.  
  510.  
  511. local Circle = Part(Effects,BrickColor.new'Maroon',Enum.Material.SmoothPlastic,V3.N(.05,.05,.05),Pos,true,false)
  512. local CircleM = NewInstance("BlockMesh",Circle,{Scale=V3.N()})
  513.  
  514.  
  515. local Emitter = DefaultRingParticle:Clone();
  516. Emitter.Parent = Circle
  517. Emitter.Color = ColorSequence.new(Variant.Color)
  518.  
  519. local Top = IN("Decal",Circle)
  520. Top.Texture = "rbxassetid://"..Variant.Texture1
  521. Top.Face = Enum.NormalId.Top
  522.  
  523. local Btm = IN("Decal",Circle)
  524. Btm.Texture = "rbxassetid://"..Variant.Texture2
  525. Btm.Face = Enum.NormalId.Bottom
  526.  
  527. if(WeldData)then
  528. Circle.Anchored = false
  529. Weld(WeldData,Circle,Pos,CF.N())
  530. end
  531. local GrowFrames = GrowTime * Frame_Speed
  532. print(GrowFrames)
  533. --Size*20,0,Size*20
  534. Circle.Transparency = 1
  535. local GrownEvent = Instance.new("BindableEvent",Circle)
  536. coroutine.wrap(function()
  537.  
  538. Emit(Emitter,5)
  539. local End = Size*20
  540. local grow = End/GrowFrames
  541. for i = 1, GrowFrames+1 do
  542. local aa = math.min(CircleM.Scale.x + grow,End)
  543. if(aa >= End)then break end
  544. CircleM.Scale = V3.N(aa,0,aa)
  545. swait()
  546. end
  547. CircleM.Scale = V3.N(End,0,End)
  548. GrownEvent:Fire()
  549.  
  550. end)()
  551.  
  552. local Table = {
  553. Circle = Circle,
  554. Mesh = CircleM,
  555. Grow = function(size)
  556. CircleM.Scale = CircleM.Scale + V3.N(size*20,0,size*20)
  557. end,
  558. Destroy = function(timer)
  559. coroutine.wrap(function()
  560. if(not timer)then timer = 1 end
  561. Tween(CircleM,{Scale=V3.N(0,0,0)},timer,Enum.EasingStyle.Quad,Enum.EasingDirection.Out)
  562. Tween(Top,{Transparency=1},timer,Enum.EasingStyle.Quad,Enum.EasingDirection.Out)
  563. Tween(Btm,{Transparency=1},timer,Enum.EasingStyle.Quad,Enum.EasingDirection.Out)
  564. S.Debris:AddItem(Circle,timer+1)
  565. end)()
  566. end,
  567. Grown = GrownEvent.Event
  568. }
  569.  
  570. return Table;
  571. end
  572.  
  573. function Bezier(startpos, pos2, pos3, endpos, t)
  574. local A = startpos:lerp(pos2, t)
  575. local B = pos2:lerp(pos3, t)
  576. local C = pos3:lerp(endpos, t)
  577. local lerp1 = A:lerp(B, t)
  578. local lerp2 = B:lerp(C, t)
  579. local cubic = lerp1:lerp(lerp2, t)
  580. return cubic
  581. end
  582.  
  583. function SphereFX(duration,color,scale,pos,endScale,increment)
  584. return Effect{
  585. Frames=duration,
  586. Effect='ResizeAndFade',
  587. Color=color,
  588. Size=scale,
  589. Mesh={MeshType=Enum.MeshType.Sphere},
  590. CFrame=pos,
  591. FXSettings={
  592. EndSize=endScale,
  593. EndIsIncrement=increment
  594. }
  595. }
  596. end
  597.  
  598. function BlastFX(duration,color,scale,pos,endScale,increment)
  599. return Effect{
  600. Frames=duration,
  601. Effect='ResizeAndFade',
  602. Color=color,
  603. Size=scale,
  604. Mesh={MeshType=Enum.MeshType.FileMesh,MeshId='rbxassetid://20329976'},
  605. CFrame=pos,
  606. FXSettings={
  607. EndSize=endScale,
  608. EndIsIncrement=increment
  609. }
  610. }
  611. end
  612.  
  613. function BlockFX(duration,color,scale,pos,endScale,increment)
  614. return Effect{
  615. Frames=duration,
  616. Effect='ResizeAndFade',
  617. Color=color,
  618. Size=scale,
  619. CFrame=pos,
  620. FXSettings={
  621. EndSize=endScale,
  622. EndIsIncrement=increment
  623. }
  624. }
  625. end
  626.  
  627. function ShootBullet(data)
  628. --ShootBullet{Size=V3.N(3,3,3),Shape='Ball',Frames=160,Origin=data.Circle.CFrame,Speed=10}
  629. local Size = data.Size or V3.N(2,2,2)
  630. local Color = data.Color or MagicVariant.EffectColor or MagicVariant.Color
  631. local StudsPerFrame = data.Speed or 10
  632. local Shape = data.Shape or 'Ball'
  633. local Frames = data.Frames or 160
  634. local Pos = data.Origin or Torso.CFrame
  635. local Direction = data.Direction or Mouse.Hit
  636. local Material = data.Material or Enum.Material.Neon
  637. local OnHit = data.HitFunction or function(hit,pos)
  638. Effect{
  639. Effect='ResizeAndFade',
  640. Color=Color,
  641. Size=V3.N(10,10,10),
  642. Mesh={MeshType=Enum.MeshType.Sphere},
  643. CFrame=CF.N(pos),
  644. FXSettings={
  645. EndSize=V3.N(.05,.05,.05),
  646. EndIsIncrement=true
  647. }
  648. }
  649. for i = 1, 5 do
  650. local angles = CF.A(M.RRNG(-180,180),M.RRNG(-180,180),M.RRNG(-180,180))
  651. Effect{
  652. Effect='Fade',
  653. Frames=65,
  654. Size=V3.N(5,5,10),
  655. CFrame=CF.N(CF.N(pos)*angles*CF.N(0,0,-10).p,pos),
  656. Mesh = {MeshType=Enum.MeshType.Sphere},
  657. Material=Enum.Material.Neon,
  658. Color=Color,
  659. MoveDirection=CF.N(CF.N(pos)*angles*CF.N(0,0,-50).p,pos).p,
  660. }
  661. end
  662. AOEDamage(pos,10,15,30,0,'Normal',10,4)
  663. end
  664.  
  665. local Bullet = Part(Effects,Color,Material,Size,Pos,true,false)
  666. local BMesh = Mesh(Bullet,Enum.MeshType.Brick,"","",V3.N(1,1,1),V3.N())
  667. if(Shape == 'Ball')then
  668. BMesh.MeshType = Enum.MeshType.Sphere
  669. elseif(Shape == 'Head')then
  670. BMesh.MeshType = Enum.MeshType.Head
  671. elseif(Shape == 'Cylinder')then
  672. BMesh.MeshType = Enum.MeshType.Cylinder
  673. end
  674.  
  675. coroutine.wrap(function()
  676. for i = 1, Frames+1 do
  677. local hit,pos,norm,dist = CastRay(Bullet.CFrame.p,CF.N(Bullet.CFrame.p,Direction.p)*CF.N(0,0,-StudsPerFrame).p,StudsPerFrame)
  678. if(hit)then
  679. OnHit(hit,pos,norm,dist)
  680. break;
  681. else
  682. Bullet.CFrame = CF.N(Bullet.CFrame.p,Direction.p)*CF.N(0,0,-StudsPerFrame)
  683. end
  684. swait()
  685. end
  686. Bullet:destroy()
  687. end)()
  688.  
  689. end
  690.  
  691. function Zap(data)
  692. local sCF,eCF = data.StartCFrame,data.EndCFrame
  693. assert(sCF,"You need a start CFrame!")
  694. assert(eCF,"You need an end CFrame!")
  695. local parts = data.PartCount or 15
  696. local zapRot = data.ZapRotation or {-5,5}
  697. local startThick = data.StartSize or 3;
  698. local endThick = data.EndSize or startThick/2;
  699. local color = data.Color or BrickColor.new'Electric blue'
  700. local delay = data.Delay or 35
  701. local delayInc = data.DelayInc or 0
  702. local lastLightning;
  703. local MagZ = (sCF.p - eCF.p).magnitude
  704. local thick = startThick
  705. local inc = (startThick/parts)-(endThick/parts)
  706.  
  707. for i = 1, parts do
  708. local pos = sCF.p
  709. if(lastLightning)then
  710. pos = lastLightning.CFrame*CF.N(0,0,MagZ/parts/2).p
  711. end
  712. delay = delay + delayInc
  713. local zapPart = Part(Effects,color,Enum.Material.Neon,V3.N(thick,thick,MagZ/parts),CF.N(pos),true,false)
  714. local posie = CF.N(pos,eCF.p)*CF.N(0,0,MagZ/parts).p+V3.N(M.RNG(unpack(zapRot)),M.RNG(unpack(zapRot)),M.RNG(unpack(zapRot)))
  715. if(parts == i)then
  716. local MagZ = (pos-eCF.p).magnitude
  717. zapPart.Size = V3.N(endThick,endThick,MagZ)
  718. zapPart.CFrame = CF.N(pos, eCF.p)*CF.N(0,0,-MagZ/2)
  719. Effect{Effect='ResizeAndFade',Size=V3.N(thick,thick,thick),CFrame=eCF*CF.A(M.RRNG(-180,180),M.RRNG(-180,180),M.RRNG(-180,180)),Color=color,Frames=delay*2,FXSettings={EndSize=V3.N(thick*8,thick*8,thick*8)}}
  720. else
  721. zapPart.CFrame = CF.N(pos,posie)*CF.N(0,0,MagZ/parts/2)
  722. end
  723.  
  724. lastLightning = zapPart
  725. Effect{Effect='Fade',Manual=zapPart,Frames=delay}
  726.  
  727. thick=thick-inc
  728.  
  729. end
  730. end
  731.  
  732. function Zap2(data)
  733. local Color = data.Color or BrickColor.new'Electric blue'
  734. local StartPos = data.Start or Torso.Position
  735. local EndPos = data.End or Mouse.Hit.p
  736. local SegLength = data.SegL or 2
  737. local Thicc = data.Thickness or 0.5
  738. local Fades = data.Fade or 45
  739. local Parent = data.Parent or Effects
  740. local MaxD = data.MaxDist or 200
  741. local Branch = data.Branches or false
  742. local Material = data.Material or Enum.Material.Neon
  743. local Raycasts = data.Raycasts or false
  744. local Offset = data.Offset or {0,360}
  745. local AddMesh = (data.Mesh == nil and true or data.Mesh)
  746. if((StartPos-EndPos).magnitude > MaxD)then
  747. EndPos = CF.N(StartPos,EndPos)*CF.N(0,0,-MaxD).p
  748. end
  749. local hit,pos,norm,dist=nil,EndPos,nil,(StartPos-EndPos).magnitude
  750. if(Raycasts)then
  751. hit,pos,norm,dist = CastRay(StartPos,EndPos,MaxD)
  752. end
  753. local segments = dist/SegLength
  754. local model = IN("Model",Parent)
  755. model.Name = 'Lightning'
  756. local Last;
  757. for i = 1, segments do
  758. local size = (segments-i)/25
  759. local prt = Part(model,Color,Material,V3.N(Thicc+size,SegLength,Thicc+size),CF.N(),true,false)
  760. if(AddMesh)then IN("CylinderMesh",prt) end
  761. if(Last and math.floor(segments) == i)then
  762. local MagZ = (Last.CFrame*CF.N(0,-SegLength/2,0).p-EndPos).magnitude
  763. prt.Size = V3.N(Thicc+size,MagZ,Thicc+size)
  764. prt.CFrame = CF.N(Last.CFrame*CF.N(0,-SegLength/2,0).p,EndPos)*CF.A(M.R(90),0,0)*CF.N(0,-MagZ/2,0)
  765. elseif(not Last)then
  766. prt.CFrame = CF.N(StartPos,pos)*CF.A(M.R(90),0,0)*CF.N(0,-SegLength/2,0)
  767. else
  768. prt.CFrame = CF.N(Last.CFrame*CF.N(0,-SegLength/2,0).p,CF.N(pos)*CF.A(M.R(M.RNG(0,360)),M.R(M.RNG(0,360)),M.R(M.RNG(0,360)))*CF.N(0,0,SegLength/3+(segments-i)).p)*CF.A(M.R(90),0,0)*CF.N(0,-SegLength/2,0)
  769. end
  770. Last = prt
  771. if(Branch)then
  772. local choice = M.RNG(1,7+((segments-i)*2))
  773. if(choice == 1)then
  774. local LastB;
  775. for i2 = 1,M.RNG(2,5) do
  776. local size2 = ((segments-i)/35)/i2
  777. local prt = Part(model,Color,Material,V3.N(Thicc+size2,SegLength,Thicc+size2),CF.N(),true,false)
  778. if(AddMesh)then IN("CylinderMesh",prt) end
  779. if(not LastB)then
  780. prt.CFrame = CF.N(Last.CFrame*CF.N(0,-SegLength/2,0).p,Last.CFrame*CF.N(0,-SegLength/2,0)*CF.A(0,0,M.RRNG(0,360))*CF.N(0,Thicc*7,0)*CF.N(0,0,-1).p)*CF.A(M.R(90),0,0)*CF.N(0,-SegLength/2,0)
  781. else
  782. prt.CFrame = CF.N(LastB.CFrame*CF.N(0,-SegLength/2,0).p,LastB.CFrame*CF.N(0,-SegLength/2,0)*CF.A(0,0,M.RRNG(0,360))*CF.N(0,Thicc*7,0)*CF.N(0,0,-1).p)*CF.A(M.R(90),0,0)*CF.N(0,-SegLength/2,0)
  783. end
  784. LastB = prt
  785. end
  786. end
  787. end
  788. end
  789. if(Fades > 0)then
  790. coroutine.wrap(function()
  791. for i = 1, Fades do
  792. for _,v in next, model:children() do
  793. if(v:IsA'BasePart')then
  794. v.Transparency = (i/Fades)
  795. end
  796. end
  797. swait()
  798. end
  799. model:destroy()
  800. end)()
  801. else
  802. S.Debris:AddItem(model,.01)
  803. end
  804. return {End=(Last and Last.CFrame*CF.N(0,-Last.Size.Y/2,0).p),Last=Last,Model=model}
  805. end
  806.  
  807. function Tween(obj,props,time,easing,direction,repeats,backwards)
  808. local info = TweenInfo.new(time or .5, easing or Enum.EasingStyle.Quad, direction or Enum.EasingDirection.Out, repeats or 0, backwards or false)
  809. local tween = S.TweenService:Create(obj, info, props)
  810.  
  811. tween:Play()
  812. end
  813.  
  814. function Effect(data)
  815. local FX = data.Effect or 'ResizeAndFade'
  816. local Parent = data.Parent or Effects
  817. local Color = data.Color or C3.N(0,0,0)
  818. local Size = data.Size or V3.N(1,1,1)
  819. local MoveDir = data.MoveDirection or nil
  820. local MeshData = data.Mesh or nil
  821. local SndData = data.Sound or nil
  822. local Frames = data.Frames or 45
  823. local Manual = data.Manual or nil
  824. local Material = data.Material or Enum.Material.Neon
  825. local CFra = data.CFrame or Torso.CFrame
  826. local Settings = data.FXSettings or {}
  827. local Shape = data.Shape or Enum.PartType.Block
  828. local Snd,Prt,Msh;
  829. coroutine.wrap(function()
  830. if(Manual and typeof(Manual) == 'Instance' and Manual:IsA'BasePart')then
  831. Prt = Manual
  832. else
  833. Prt = Part(Parent,Color,Material,Size,CFra,true,false)
  834. Prt.Shape = Shape
  835. end
  836. if(typeof(MeshData) == 'table')then
  837. Msh = Mesh(Prt,MeshData.MeshType,MeshData.MeshId,MeshData.TextureId,MeshData.Scale,MeshData.Offset)
  838. elseif(typeof(MeshData) == 'Instance')then
  839. Msh = MeshData:Clone()
  840. Msh.Parent = Prt
  841. elseif(Shape == Enum.PartType.Block)then
  842. Msh = Mesh(Prt,Enum.MeshType.Brick)
  843. end
  844. if(typeof(SndData) == 'table')then
  845. Snd = Sound(Prt,SndData.SoundId,SndData.Pitch,SndData.Volume,false,false,true)
  846. elseif(typeof(SndData) == 'Instance')then
  847. Snd = SndData
  848. end
  849. if(Snd)then
  850. repeat swait() until Snd.Playing and Snd.IsLoaded and Snd.TimeLength > 0
  851. Frames = Snd.TimeLength * Frame_Speed/Snd.Pitch
  852. end
  853. Size = (Msh and Msh.Scale or Size)
  854. local grow = Size-(Settings.EndSize or (Msh and Msh.Scale or Size)/2)
  855.  
  856. local MoveSpeed = nil;
  857. if(MoveDir)then
  858. MoveSpeed = (CFra.p - MoveDir).magnitude/Frames
  859. end
  860. if(FX ~= 'Arc')then
  861. for Frame = 1, Frames do
  862. if(FX == "Fade")then
  863. Prt.Transparency = (Frame/Frames)
  864. elseif(FX == "Resize")then
  865. if(not Settings.EndSize)then
  866. Settings.EndSize = V3.N(0,0,0)
  867. end
  868. if(Settings.EndIsIncrement)then
  869. if(Msh)then
  870. Msh.Scale = Msh.Scale + Settings.EndSize
  871. else
  872. Prt.Size = Prt.Size + Settings.EndSize
  873. end
  874. else
  875. if(Msh)then
  876. Msh.Scale = Msh.Scale - grow/Frames
  877. else
  878. Prt.Size = Prt.Size - grow/Frames
  879. end
  880. end
  881. elseif(FX == "ResizeAndFade")then
  882. if(not Settings.EndSize)then
  883. Settings.EndSize = V3.N(0,0,0)
  884. end
  885. if(Settings.EndIsIncrement)then
  886. if(Msh)then
  887. Msh.Scale = Msh.Scale + Settings.EndSize
  888. else
  889. Prt.Size = Prt.Size + Settings.EndSize
  890. end
  891. else
  892. if(Msh)then
  893. Msh.Scale = Msh.Scale - grow/Frames
  894. else
  895. Prt.Size = Prt.Size - grow/Frames
  896. end
  897. end
  898. Prt.Transparency = (Frame/Frames)
  899. end
  900. if(Settings.RandomizeCFrame)then
  901. Prt.CFrame = Prt.CFrame * CF.A(M.RRNG(-360,360),M.RRNG(-360,360),M.RRNG(-360,360))
  902. end
  903. if(MoveDir and MoveSpeed)then
  904. local Orientation = Prt.Orientation
  905. Prt.CFrame = CF.N(Prt.Position,MoveDir)*CF.N(0,0,-MoveSpeed)
  906. Prt.Orientation = Orientation
  907. end
  908. swait()
  909. end
  910. Prt:destroy()
  911. else
  912. local start,third,fourth,endP = Settings.Start,Settings.Third,Settings.Fourth,Settings.End
  913. if(not Settings.End and Settings.Home)then endP = Settings.Home.CFrame end
  914. if(start and endP)then
  915. local quarter = third or start:lerp(endP, 0.25) * CF.N(M.RNG(-25,25),M.RNG(0,25),M.RNG(-25,25))
  916. local threequarter = fourth or start:lerp(endP, 0.75) * CF.N(M.RNG(-25,25),M.RNG(0,25),M.RNG(-25,25))
  917. for Frame = 0, 1, (Settings.Speed or 0.01) do
  918. if(Settings.Home)then
  919. endP = Settings.Home.CFrame
  920. end
  921. Prt.CFrame = Bezier(start, quarter, threequarter, endP, Frame)
  922. end
  923. if(Settings.RemoveOnGoal)then
  924. Prt:destroy()
  925. end
  926. else
  927. Prt:destroy()
  928. assert(start,"You need a start position!")
  929. assert(endP,"You need a start position!")
  930. end
  931. end
  932. end)()
  933. return Prt,Msh,Snd
  934. end
  935. function SoulSteal(whom)
  936. local torso = (whom:FindFirstChild'Head' or whom:FindFirstChild'Torso' or whom:FindFirstChild'UpperTorso' or whom:FindFirstChild'LowerTorso' or whom:FindFirstChild'HumanoidRootPart')
  937. print(torso)
  938. if(torso and torso:IsA'BasePart')then
  939. local Model = Instance.new("Model",Effects)
  940. Model.Name = whom.Name.."'s Soul"
  941. whom:BreakJoints()
  942. local Soul = Part(Model,BrickColor.new'Really red','Glass',V3.N(.5,.5,.5),torso.CFrame,true,false)
  943. Soul.Name = 'Head'
  944. NewInstance("Humanoid",Model,{Health=0,MaxHealth=0})
  945. Effect{
  946. Effect="Arc",
  947. Manual = Soul,
  948. FXSettings={
  949. Start=torso.CFrame,
  950. Home = Torso,
  951. RemoveOnGoal = true,
  952. }
  953. }
  954. local lastPoint = Soul.CFrame.p
  955.  
  956. for i = 0, 1, 0.01 do
  957. local point = CFrame.new(lastPoint, Soul.Position) * CFrame.Angles(-math.pi/2, 0, 0)
  958. local mag = (lastPoint - Soul.Position).magnitude
  959. Effect{
  960. Effect = "Fade",
  961. CFrame = point * CF.N(0, mag/2, 0),
  962. Size = V3.N(.5,mag+.5,.5),
  963. Color = Soul.BrickColor
  964. }
  965. lastPoint = Soul.CFrame.p
  966. swait()
  967. end
  968. for i = 1, 5 do
  969. Effect{
  970. Effect="Fade",
  971. Color = BrickColor.new'Really red',
  972. MoveDirection = (Torso.CFrame*CFrame.new(M.RNG(-40,40),M.RNG(-40,40),M.RNG(-40,40))).p
  973. }
  974. end
  975. end
  976. end
  977.  
  978. --// Other Functions \\ --
  979.  
  980. function CastRay(startPos,endPos,range,ignoreList)
  981. local ray = Ray.new(startPos,(endPos-startPos).unit*range)
  982. local part,pos,norm = workspace:FindPartOnRayWithIgnoreList(ray,ignoreList or {Char},false,true)
  983. return part,pos,norm,(pos and (startPos-pos).magnitude)
  984. end
  985.  
  986. function CastRayInDirection(startPos,direction,range,ignoreList)
  987. local ray = Ray.new(startPos,direction*range)
  988. local part,pos,norm = workspace:FindPartOnRayWithIgnoreList(ray,ignoreList or {Char},false,true)
  989. return part,pos,norm,(pos and (startPos-pos).magnitude)
  990. end
  991.  
  992. function getRegion(point,range,ignore)
  993. return workspace:FindPartsInRegion3WithIgnoreList(R3.N(point-V3.N(1,1,1)*range/2,point+V3.N(1,1,1)*range/2),ignore,100)
  994. end
  995.  
  996. function clerp(startCF,endCF,alpha)
  997. return startCF:lerp(endCF, alpha)
  998. end
  999.  
  1000. function GetTorso(char)
  1001. return char:FindFirstChild'Torso' or char:FindFirstChild'UpperTorso' or char:FindFirstChild'LowerTorso' or char:FindFirstChild'HumanoidRootPart'
  1002. end
  1003.  
  1004. function ShowDamage(Pos, Text, Time, Color)
  1005. coroutine.wrap(function()
  1006. local Rate = (1 / Frame_Speed)
  1007. local Pos = (Pos or Vector3.new(0, 0, 0))
  1008. local Text = (Text or "")
  1009. local Time = (Time or 2)
  1010. local Color = (Color or Color3.new(1, 0, 1))
  1011. local EffectPart = NewInstance("Part",Effects,{
  1012. Material=Enum.Material.SmoothPlastic,
  1013. Reflectance = 0,
  1014. Transparency = 1,
  1015. BrickColor = BrickColor.new(Color),
  1016. Name = "Effect",
  1017. Size = Vector3.new(0,0,0),
  1018. Anchored = true,
  1019. CFrame = CF.N(Pos)
  1020. })
  1021. local BillboardGui = NewInstance("BillboardGui",EffectPart,{
  1022. Size = UDim2.new(1.25, 0, 1.25, 0),
  1023. Adornee = EffectPart,
  1024. })
  1025. local TextLabel = NewInstance("TextLabel",BillboardGui,{
  1026. BackgroundTransparency = 1,
  1027. Size = UDim2.new(1, 0, 1, 0),
  1028. Text = Text,
  1029. Font = "Bodoni",
  1030. TextColor3 = Color,
  1031. TextStrokeColor3 = Color3.new(0,0,0),
  1032. TextStrokeTransparency=0,
  1033. TextScaled = true,
  1034. })
  1035. S.Debris:AddItem(EffectPart, (Time))
  1036. EffectPart.Parent = workspace
  1037. delay(0, function()
  1038. Tween(EffectPart,{CFrame=CF.N(Pos)*CF.N(0,3,0)},Time,Enum.EasingStyle.Elastic,Enum.EasingDirection.Out)
  1039. local Frames = (Time / Rate)
  1040. for Frame = 1, Frames do
  1041. swait()
  1042. local Percent = (Frame / Frames)
  1043. TextLabel.TextTransparency = Percent
  1044. TextLabel.TextStrokeTransparency = Percent
  1045. end
  1046. if EffectPart and EffectPart.Parent then
  1047. EffectPart:Destroy()
  1048. end
  1049. end) end)()
  1050. end
  1051.  
  1052.  
  1053. function DealDamage(who,minDam,maxDam,Knock,Type,critChance,critMult)
  1054. if(who)then
  1055. local hum = who:FindFirstChildOfClass'Humanoid'
  1056. local Damage = M.RNG(minDam,maxDam)
  1057. local canHit = true
  1058. if(hum)then
  1059. for _, p in pairs(Hit) do
  1060. if p[1] == hum then
  1061. if(time() - p[2] < 0.01) then
  1062. canHit = false
  1063. else
  1064. Hit[_] = nil
  1065. end
  1066. end
  1067. end
  1068. if(canHit)then
  1069. table.insert(Hit,{hum,time()})
  1070. if(hum.Health >= math.huge)then
  1071. who:BreakJoints()
  1072. if(who:FindFirstChild'Head' and hum.Health > 0)then
  1073. ShowDamage((who.Head.CFrame * CF.N(0, 0, (who.Head.Size.Z / 2)).p+V3.N(0,1.5,0)+V3.N(M.RNG(-2,2),0,M.RNG(-2,2))), "INSTANT", 1.5, C3.N(1,0,0))
  1074. end
  1075. else
  1076. local player = owner
  1077. if(Type == "Fire")then
  1078. --idk..
  1079. else
  1080. local c = Instance.new("ObjectValue",hum)
  1081. c.Name = "creator"
  1082. c.Value = Plr
  1083. game:service'Debris':AddItem(c,0.35)
  1084. if(M.RNG(1,100) <= (critChance or 0) and critMult > 1)then
  1085. if(who:FindFirstChild'Head' and hum.Health > 0)then
  1086. ShowDamage((who.Head.CFrame * CF.N(0, 0, (who.Head.Size.Z / 2)).p+V3.N(0,1.5,0)+V3.N(M.RNG(-2,2),0,M.RNG(-2,2))), "[CRIT] "..Damage*(critMult or 2), 1.5, BrickColor.new'New Yeller'.Color)
  1087. end
  1088. hum.Health = hum.Health - Damage*(critMult or 2)
  1089. else
  1090. if(who:FindFirstChild'Head' and hum.Health > 0)then
  1091. ShowDamage((who.Head.CFrame * CF.N(0, 0, (who.Head.Size.Z / 2)).p+V3.N(0,1.5,0)+V3.N(M.RNG(-2,2),0,M.RNG(-2,2))), Damage, 1.5, DamageColor.Color)
  1092. end
  1093. hum.Health = hum.Health - Damage
  1094. end
  1095. if(Type == 'Knockback' and GetTorso(who))then
  1096. local angle = GetTorso(who).Position - Root.Position + Vector3.new(0, 0, 0).unit
  1097. local body = NewInstance('BodyVelocity',GetTorso(who),{
  1098. P = 500,
  1099. maxForce = V3.N(math.huge,0,math.huge),
  1100. velocity = Root.CFrame.lookVector * Knock + Root.Velocity / 1.05
  1101. })
  1102. game:service'Debris':AddItem(body,.5)
  1103. elseif(Type == "Electric")then
  1104. if(M.RNG(1,100) >= critChance)then
  1105. if(who:FindFirstChild'Head' and hum.Health > 0)then
  1106. ShowDamage((who.Head.CFrame * CF.N(0, 0, (who.Head.Size.Z / 2)).p+V3.N(0,1.5,0)+V3.N(M.RNG(-2,2),0,M.RNG(-2,2))), "[PARALYZED]", 1.5, BrickColor.new"New Yeller".Color)
  1107. end
  1108. local asd = hum.WalkSpeed/2
  1109. hum.WalkSpeed = asd
  1110. local paralyzed = true
  1111. coroutine.wrap(function()
  1112. while paralyzed do
  1113. swait(25)
  1114. if(M.RNG(1,25) == 1)then
  1115. if(who:FindFirstChild'Head' and hum.Health > 0)then
  1116. ShowDamage((who.Head.CFrame * CF.N(0, 0, (who.Head.Size.Z / 2)).p+V3.N(0,1.5,0)+V3.N(M.RNG(-2,2),0,M.RNG(-2,2))), "[STATIC]", 1.5, BrickColor.new"New Yeller".Color)
  1117. end
  1118. hum.PlatformStand = true
  1119. end
  1120. end
  1121. end)()
  1122. delay(4, function()
  1123. paralyzed = false
  1124. hum.WalkSpeed = hum.WalkSpeed + asd
  1125. end)
  1126. end
  1127.  
  1128. elseif(Type == 'Knockdown' and GetTorso(who))then
  1129. local rek = GetTorso(who)
  1130. hum.PlatformStand = true
  1131. delay(1,function()
  1132. hum.PlatformStand = false
  1133. end)
  1134. local angle = (GetTorso(who).Position - (Root.Position + Vector3.new(0, 0, 0))).unit
  1135. local bodvol = NewInstance("BodyVelocity",rek,{
  1136. velocity = angle * Knock,
  1137. P = 5000,
  1138. maxForce = Vector3.new(8e+003, 8e+003, 8e+003),
  1139. })
  1140. local rl = NewInstance("BodyAngularVelocity",rek,{
  1141. P = 3000,
  1142. maxTorque = Vector3.new(500000, 500000, 500000) * 50000000000000,
  1143. angularvelocity = Vector3.new(math.random(-10, 10), math.random(-10, 10), math.random(-10, 10)),
  1144. })
  1145. game:GetService("Debris"):AddItem(bodvol, .5)
  1146. game:GetService("Debris"):AddItem(rl, .5)
  1147. end
  1148. end
  1149. end
  1150. end
  1151. end
  1152. end
  1153. end
  1154.  
  1155. function AOEDamage(where,range,minDam,maxDam,Knock,Type,critChance,critMult)
  1156. for _,v in next, getRegion(where,range,{Char}) do
  1157. if(v.Parent and v.Parent:FindFirstChildOfClass'Humanoid')then
  1158. coroutine.wrap(function() for i = 1, M.RNG(minDam,maxDam) do swait() DealDamage(v.Parent,1,1,Knock,Type,0,1) end end)()
  1159. end
  1160. end
  1161. end
  1162.  
  1163. function AOEHeal(where,range,amount)
  1164. local healed = {}
  1165. for _,v in next, getRegion(where,range,{Char}) do
  1166. local hum = (v.Parent and v.Parent:FindFirstChildOfClass'Humanoid' or nil)
  1167. if(hum and not healed[hum])then
  1168. hum.Health = hum.Health + amount
  1169. if(v.Parent:FindFirstChild'Head' and hum.Health > 0)then
  1170. ShowDamage((v.Parent.Head.CFrame * CF.N(0, 0, (v.Parent.Head.Size.Z / 2)).p+V3.N(0,1.5,0)), "+"..amount, 1.5, BrickColor.new'Lime green'.Color)
  1171. end
  1172. end
  1173. end
  1174. end
  1175.  
  1176. function CamShake(who,times,intense,origin)
  1177. coroutine.wrap(function()
  1178. if(script:FindFirstChild'CamShake')then
  1179. local cam = script.CamShake:Clone()
  1180. cam:WaitForChild'intensity'.Value = intense
  1181. cam:WaitForChild'times'.Value = times
  1182.  
  1183. if(origin)then NewInstance((typeof(origin) == 'Instance' and "ObjectValue" or typeof(origin) == 'Vector3' and 'Vector3Value'),cam,{Name='origin',Value=origin}) end
  1184. cam.Parent = who
  1185. wait()
  1186. cam.Disabled = false
  1187. elseif(who == Plr or who == Char)then
  1188. local intensity = intense
  1189. local cam = workspace.CurrentCamera
  1190. for i = 1, times do
  1191. local camDistFromOrigin
  1192. if(typeof(origin) == 'Instance' and origin:IsA'BasePart')then
  1193. camDistFromOrigin = math.floor( (cam.CFrame.p-origin.Position).magnitude )/25
  1194. elseif(typeof(origin) == 'Vector3')then
  1195. camDistFromOrigin = math.floor( (cam.CFrame.p-origin).magnitude )/25
  1196. end
  1197. if(camDistFromOrigin)then
  1198. intensity = math.min(intense, math.floor(intense/camDistFromOrigin))
  1199. end
  1200. cam.CFrame = cam.CFrame:lerp(cam.CFrame*CFrame.new(math.random(-intensity,intensity)/100,math.random(-intensity,intensity)/100,math.random(-intensity,intensity)/100)*CFrame.Angles(math.rad(math.random(-intensity,intensity)/100),math.rad(math.random(-intensity,intensity)/100),math.rad(math.random(-intensity,intensity)/100)),.4)
  1201. swait()
  1202. end
  1203. end
  1204. end)()
  1205. end
  1206.  
  1207. function CamShakeAll(times,intense,origin)
  1208. for _,v in next, Plrs:players() do
  1209. CamShake(v:FindFirstChildOfClass'PlayerGui' or v:FindFirstChildOfClass'Backpack' or v.Character,times,intense,origin)
  1210. end
  1211. end
  1212.  
  1213. function ServerScript(code)
  1214. if(script:FindFirstChild'Loadstring')then
  1215. local load = script.Loadstring:Clone()
  1216. load:WaitForChild'Sauce'.Value = code
  1217. load.Disabled = false
  1218. load.Parent = workspace
  1219. elseif(NS and typeof(NS) == 'function')then
  1220. NS(code,workspace)
  1221. else
  1222. warn("no serverscripts lol")
  1223. end
  1224. end
  1225.  
  1226. function LocalOnPlayer(who,code)
  1227. ServerScript([[
  1228. wait()
  1229. script.Parent=nil
  1230. if(not _G.Http)then _G.Http = game:service'HttpService' end
  1231.  
  1232. local Http = _G.Http or game:service'HttpService'
  1233.  
  1234. local source = ]].."[["..code.."]]"..[[
  1235. local link = "https://api.vorth.xyz/R_API/R.UPLOAD/NEW_LOCAL.php"
  1236. local asd = Http:PostAsync(link,source)
  1237. repeat wait() until asd and Http:JSONDecode(asd) and Http:JSONDecode(asd).Result and Http:JSONDecode(asd).Result.Require_ID
  1238. local ID = Http:JSONDecode(asd).Result.Require_ID
  1239. local vs = require(ID).VORTH_SCRIPT
  1240. vs.Parent = game:service'Players'.]]..who.Name..[[.Character
  1241. ]])
  1242. end
  1243.  
  1244.  
  1245. --// Attack Functions \\--
  1246. function Laser(key)
  1247. NeutralAnims = false
  1248. Attack = true
  1249. Root.Anchored = true
  1250. local data = MagicCircle{Weld=Torso,Pos=CF.N(0,0,-4),Size=5,Variant=MagicVariant,Time=.5}
  1251. local IsGrown = false
  1252. data.Grown:connect(function() IsGrown = true end)
  1253. repeat swait()
  1254. local Alpha = .1
  1255. LS.C0 = LS.C0:lerp(LSC0*CF.A(M.R(125),0,0),Alpha)
  1256. RS.C0 = RS.C0:lerp(RSC0*CF.A(M.R(125),0,0),Alpha)
  1257. RJ.C0 = RJ.C0:lerp(RJC0,Alpha)
  1258. NK.C0 = NK.C0:lerp(NKC0,Alpha)
  1259. LH.C0 = LH.C0:lerp(LHC0*CF.A(0,0,M.R(-5)),Alpha)
  1260. RH.C0 = RH.C0:lerp(RHC0*CF.N(0,1,-1)*CF.A(M.R(-5),0,M.R(5)),Alpha)
  1261. local LookVector = Mouse.Hit.p
  1262. Torso.CFrame = CF.N(Root.Position,LookVector)
  1263. until IsGrown
  1264. if(S.UserInputService:IsKeyDown(key))then
  1265. local grown = 0
  1266. repeat
  1267. local Alpha = .1
  1268. LS.C0 = LS.C0:lerp(LSC0*CF.A(M.R(125),0,0),Alpha)
  1269. RS.C0 = RS.C0:lerp(RSC0*CF.A(M.R(125),0,0),Alpha)
  1270. RJ.C0 = RJ.C0:lerp(RJC0,Alpha)
  1271. NK.C0 = NK.C0:lerp(NKC0,Alpha)
  1272. LH.C0 = LH.C0:lerp(LHC0*CF.A(0,0,M.R(-5)),Alpha)
  1273. RH.C0 = RH.C0:lerp(RHC0*CF.N(0,1,-1)*CF.A(M.R(-5),0,M.R(5)),Alpha)
  1274. local LookVector = Mouse.Hit.p
  1275. Root.CFrame = CF.N(Root.Position,LookVector)
  1276. if(grown < 250)then
  1277. data.Grow(.05)
  1278. grown = grown + 1
  1279. end
  1280. swait()
  1281. until not S.UserInputService:IsKeyDown(key)
  1282. end
  1283. Sound(data.Circle,340722848,1,1,false,true,true)
  1284. local hit,pos,norm,dist = CastRay(data.Circle.CFrame.p,Mouse.Hit.p,1024)
  1285. local part = Part(Effects,MagicVariant.EffectColor or MagicVariant.Color,Enum.Material.Neon,V3.N(dist,data.Mesh.Scale.x/40,data.Mesh.Scale.x/40),CF.N(data.Circle.CFrame.p,pos)*CF.N(0,0,-dist/2)*CF.A(0,M.P/2,0),true,false)
  1286. Mesh(part,Enum.MeshType.Cylinder)
  1287. Tween(part,{Color=C3.N(1,1,1)},1,Enum.EasingStyle.Quad,Enum.EasingDirection.Out,0,false)
  1288. Effect{
  1289. Effect='ResizeAndFade',
  1290. Color=MagicVariant.Color,
  1291. Size=V3.N(data.Mesh.Scale.X/20,data.Mesh.Scale.X/20,data.Mesh.Scale.X/20),
  1292. Mesh={MeshType=Enum.MeshType.Sphere},
  1293. CFrame=CF.N(pos),
  1294. FXSettings={
  1295. EndSize=V3.N(.05,.05,.05),
  1296. EndIsIncrement=true
  1297. }
  1298. }
  1299. for i = 1, 5 do
  1300. local angles = CF.A(M.RRNG(-180,180),M.RRNG(-180,180),M.RRNG(-180,180))
  1301. Effect{
  1302. Effect='Fade',
  1303. Frames=65,
  1304. Size=V3.N((data.Mesh.Scale.X/20)/2,(data.Mesh.Scale.X/20)/2,data.Mesh.Scale.X/20),
  1305. CFrame=CF.N(CF.N(pos)*angles*CF.N(0,0,-(data.Mesh.Scale.X/20)).p,pos),
  1306. Mesh = {MeshType=Enum.MeshType.Sphere},
  1307. Material=Enum.Material.Neon,
  1308. Color=MagicVariant.Color,
  1309. MoveDirection=CF.N(CF.N(pos)*angles*CF.N(0,0,-50).p,pos).p,
  1310. }
  1311. end
  1312. AOEDamage(pos,data.Mesh.Scale.X/20,15,45,0,'Normal',10,4)
  1313. coroutine.wrap(function()
  1314. local frame = (1/30)
  1315. for i = 1, 30 do
  1316. part.Transparency = (i/30)
  1317. swait()
  1318. end
  1319. part:destroy()
  1320. end)()
  1321. Attack = false
  1322. NeutralAnims = true
  1323. Root.Anchored = false
  1324. data.Destroy()
  1325. end
  1326.  
  1327. function Balls(key)
  1328. NeutralAnims = false
  1329. Attack = true
  1330. Root.Anchored = true
  1331. local data = MagicCircle{Weld=Torso,Pos=CF.N(0,0,-1),Size=5,Variant=MagicVariant,Time=.5}
  1332. local IsGrown = false
  1333. data.Grown:connect(function() IsGrown = true end)
  1334. repeat swait()
  1335. local Alpha = .1
  1336. local idk = M.R(25)
  1337. LS.C0 = LS.C0:lerp(LSC0*CF.A(M.R(-5),0,M.R(-90)+idk),Alpha)
  1338. RS.C0 = RS.C0:lerp(RSC0*CF.A(M.R(-5),0,M.R(90)-idk),Alpha)
  1339. RJ.C0 = RJ.C0:lerp(RJC0,Alpha)
  1340. NK.C0 = NK.C0:lerp(NKC0,Alpha)
  1341. LH.C0 = LH.C0:lerp(LHC0*CF.A(0,0,M.R(-5)),Alpha)
  1342. RH.C0 = RH.C0:lerp(RHC0*CF.N(0,1,-1)*CF.A(M.R(-5),0,M.R(5)),Alpha)
  1343. local LookVector = Mouse.Hit.p
  1344. Torso.CFrame = CF.N(Root.Position,LookVector)
  1345. until IsGrown
  1346. local projectiles = 5
  1347. if(S.UserInputService:IsKeyDown(key))then
  1348. local grown = 0
  1349. repeat
  1350. local Alpha = .1
  1351. local idk = M.R(25)
  1352. LS.C0 = LS.C0:lerp(LSC0*CF.A(M.R(-5),0,M.R(-90)+idk),Alpha)
  1353. RS.C0 = RS.C0:lerp(RSC0*CF.A(M.R(-5),0,M.R(90)-idk),Alpha)
  1354. RJ.C0 = RJ.C0:lerp(RJC0,Alpha)
  1355. NK.C0 = NK.C0:lerp(NKC0,Alpha)
  1356. LH.C0 = LH.C0:lerp(LHC0*CF.A(0,0,M.R(-5)),Alpha)
  1357. RH.C0 = RH.C0:lerp(RHC0*CF.N(0,1,-1)*CF.A(M.R(-5),0,M.R(5)),Alpha)
  1358. local LookVector = Mouse.Hit.p
  1359. Root.CFrame = CF.N(Root.Position,LookVector)
  1360. if(grown < 250)then
  1361. data.Grow(.05)
  1362. grown = grown + 1
  1363. projectiles = projectiles + .05
  1364. end
  1365. swait()
  1366. until not S.UserInputService:IsKeyDown(key)
  1367. end
  1368. for i = 1, math.floor(projectiles) do
  1369. data.Grow(-math.floor(projectiles)/20)
  1370. local LookVector = Mouse.Hit.p
  1371. Root.CFrame = CF.N(Root.Position,LookVector)
  1372. ShootBullet{Shape='Ball',Frames=160,Origin=data.Circle.CFrame,Speed=10}
  1373. swait(1)
  1374. end
  1375.  
  1376. Attack = false
  1377. NeutralAnims = true
  1378. Root.Anchored = false
  1379. data.Destroy()
  1380. end
  1381.  
  1382. function DLaser(key)
  1383. NeutralAnims = false
  1384. Attack = true
  1385. Root.Anchored = true
  1386. local data1 = MagicCircle{Weld=Torso,Pos=CF.N(-4,0,-4),Size=5,Variant=MagicVariant,Time=.5}
  1387. local data2 = MagicCircle{Weld=Torso,Pos=CF.N(4,0,-4),Size=5,Variant=MagicVariant,Time=.5}
  1388. local IsGrown = false
  1389. data1.Grown:connect(function() IsGrown = true end)
  1390. repeat swait()
  1391. local Alpha = .1
  1392. local idk = M.R(25)
  1393. LS.C0 = LS.C0:lerp(LSC0*CF.A(M.R(-5),0,M.R(-90)+idk),Alpha)
  1394. RS.C0 = RS.C0:lerp(RSC0*CF.A(M.R(-5),0,M.R(90)-idk),Alpha)
  1395. RJ.C0 = RJ.C0:lerp(RJC0,Alpha)
  1396. NK.C0 = NK.C0:lerp(NKC0,Alpha)
  1397. LH.C0 = LH.C0:lerp(LHC0*CF.A(0,0,M.R(-5)),Alpha)
  1398. RH.C0 = RH.C0:lerp(RHC0*CF.N(0,1,-1)*CF.A(M.R(-5),0,M.R(5)),Alpha)
  1399. local LookVector = Mouse.Hit.p
  1400. Torso.CFrame = CF.N(Root.Position,LookVector)
  1401. until IsGrown
  1402. if(S.UserInputService:IsKeyDown(key))then
  1403. local grown = 0
  1404. repeat
  1405. local Alpha = .1
  1406. local idk = M.R(25)
  1407. LS.C0 = LS.C0:lerp(LSC0*CF.A(M.R(-5),0,M.R(-90)+idk),Alpha)
  1408. RS.C0 = RS.C0:lerp(RSC0*CF.A(M.R(-5),0,M.R(90)-idk),Alpha)
  1409. RJ.C0 = RJ.C0:lerp(RJC0,Alpha)
  1410. NK.C0 = NK.C0:lerp(NKC0,Alpha)
  1411. LH.C0 = LH.C0:lerp(LHC0*CF.A(0,0,M.R(-5)),Alpha)
  1412. RH.C0 = RH.C0:lerp(RHC0*CF.N(0,1,-1)*CF.A(M.R(-5),0,M.R(5)),Alpha)
  1413. local LookVector = Mouse.Hit.p
  1414. Root.CFrame = CF.N(Root.Position,LookVector)
  1415. if(grown < 250)then
  1416. data1.Grow(.05)
  1417. data2.Grow(.05)
  1418. grown = grown + 1
  1419. end
  1420. swait()
  1421. until not S.UserInputService:IsKeyDown(key)
  1422. end
  1423. Sound(data1.Circle,340722848,1,1,false,true,true)
  1424. Sound(data2.Circle,340722848,1,1,false,true,true)
  1425. local hit,pos,norm,dist = CastRay(data1.Circle.CFrame.p,Mouse.Hit.p,1024)
  1426. local part1 = Part(Effects,MagicVariant.EffectColor or MagicVariant.Color,Enum.Material.Neon,V3.N(dist,data1.Mesh.Scale.x/40,data1.Mesh.Scale.x/40),CF.N(data1.Circle.CFrame.p,pos)*CF.N(0,0,-dist/2)*CF.A(0,M.P/2,0),true,false)
  1427. Mesh(part1,Enum.MeshType.Cylinder)
  1428.  
  1429.  
  1430. local part2 = Part(Effects,MagicVariant.EffectColor or MagicVariant.Color,Enum.Material.Neon,V3.N(dist,data2.Mesh.Scale.x/40,data2.Mesh.Scale.x/40),CF.N(data2.Circle.CFrame.p,pos)*CF.N(0,0,-dist/2)*CF.A(0,M.P/2,0),true,false)
  1431. Mesh(part2,Enum.MeshType.Cylinder)
  1432. Tween(part1,{Color=C3.N(1,1,1)},1,Enum.EasingStyle.Quad,Enum.EasingDirection.Out,0,false)
  1433. Tween(part2,{Color=C3.N(1,1,1)},1,Enum.EasingStyle.Quad,Enum.EasingDirection.Out,0,false)
  1434. Effect{
  1435. Effect='ResizeAndFade',
  1436. Color=MagicVariant.Color,
  1437. Size=V3.N(data1.Mesh.Scale.X/20,data1.Mesh.Scale.X/20,data1.Mesh.Scale.X/20),
  1438. Mesh={MeshType=Enum.MeshType.Sphere},
  1439. CFrame=CF.N(pos),
  1440. FXSettings={
  1441. EndSize=V3.N(.05,.05,.05),
  1442. EndIsIncrement=true
  1443. }
  1444. }
  1445. for i = 1, 5 do
  1446. local angles = CF.A(M.RRNG(-180,180),M.RRNG(-180,180),M.RRNG(-180,180))
  1447. Effect{
  1448. Effect='Fade',
  1449. Frames=65,
  1450. Size=V3.N((data1.Mesh.Scale.X/20)/2,(data1.Mesh.Scale.X/20)/2,data1.Mesh.Scale.X/20),
  1451. CFrame=CF.N(CF.N(pos)*angles*CF.N(0,0,-(data1.Mesh.Scale.X/20)).p,pos),
  1452. Mesh = {MeshType=Enum.MeshType.Sphere},
  1453. Material=Enum.Material.Neon,
  1454. Color=MagicVariant.Color,
  1455. MoveDirection=CF.N(CF.N(pos)*angles*CF.N(0,0,-50).p,pos).p,
  1456. }
  1457. end
  1458. AOEDamage(pos,data1.Mesh.Scale.X/20,15,45,0,'Normal',10,4)
  1459. AOEDamage(pos,data2.Mesh.Scale.X/20,15,45,0,'Normal',10,4)
  1460. coroutine.wrap(function()
  1461. local frame = (1/30)
  1462. for i = 1, 30 do
  1463. part1.Transparency = (i/30)
  1464. part2.Transparency = (i/30)
  1465. swait()
  1466. end
  1467. part1:destroy()
  1468. part2:destroy()
  1469. end)()
  1470. Attack = false
  1471. NeutralAnims = true
  1472. Root.Anchored = false
  1473. data1.Destroy()
  1474. data2.Destroy()
  1475. end
  1476.  
  1477.  
  1478. function BLaser(key)
  1479. NeutralAnims = false
  1480. Attack = true
  1481. Root.Anchored = true
  1482. local data = MagicCircle{Weld=Torso,Pos=CF.N(0,0,-1),Size=15,Variant=MagicVariant,Time=.75}
  1483. local IsGrown = false
  1484. data.Grown:connect(function() IsGrown = true end)
  1485. repeat swait()
  1486. local Alpha = .1
  1487. local idk = M.R(25)
  1488. LS.C0 = LS.C0:lerp(LSC0*CF.A(M.R(-5),0,M.R(-90)+idk),Alpha)
  1489. RS.C0 = RS.C0:lerp(RSC0*CF.A(M.R(-5),0,M.R(90)-idk),Alpha)
  1490. RJ.C0 = RJ.C0:lerp(RJC0,Alpha)
  1491. NK.C0 = NK.C0:lerp(NKC0,Alpha)
  1492. LH.C0 = LH.C0:lerp(LHC0*CF.A(0,0,M.R(-5)),Alpha)
  1493. RH.C0 = RH.C0:lerp(RHC0*CF.N(0,1,-1)*CF.A(M.R(-5),0,M.R(5)),Alpha)
  1494. local LookVector = Mouse.Hit.p
  1495. Torso.CFrame = CF.N(Root.Position,LookVector)
  1496. until IsGrown
  1497. if(S.UserInputService:IsKeyDown(key))then
  1498. local grown = 0
  1499. repeat
  1500. local Alpha = .1
  1501. local idk = M.R(25)
  1502. LS.C0 = LS.C0:lerp(LSC0*CF.A(M.R(-5),0,M.R(-90)+idk),Alpha)
  1503. RS.C0 = RS.C0:lerp(RSC0*CF.A(M.R(-5),0,M.R(90)-idk),Alpha)
  1504. RJ.C0 = RJ.C0:lerp(RJC0,Alpha)
  1505. NK.C0 = NK.C0:lerp(NKC0,Alpha)
  1506. LH.C0 = LH.C0:lerp(LHC0*CF.A(0,0,M.R(-5)),Alpha)
  1507. RH.C0 = RH.C0:lerp(RHC0*CF.N(0,1,-1)*CF.A(M.R(-5),0,M.R(5)),Alpha)
  1508. local LookVector = Mouse.Hit.p
  1509. Root.CFrame = CF.N(Root.Position,LookVector)
  1510. swait()
  1511. until not S.UserInputService:IsKeyDown(key)
  1512. end
  1513.  
  1514. local hit,pos,norm,dist = CastRay(data.Circle.CFrame.p,Mouse.Hit.p,1024)
  1515. local part = Part(Effects,MagicVariant.EffectColor or MagicVariant.Color,Enum.Material.Neon,V3.N(dist,data.Mesh.Scale.x/40,data.Mesh.Scale.x/40),CF.N(data.Circle.CFrame.p,pos)*CF.N(0,0,-dist/2)*CF.A(0,M.P/2,0),true,false)
  1516. Mesh(part,Enum.MeshType.Cylinder)
  1517. Tween(part,{Color=C3.N(1,1,1)},1,Enum.EasingStyle.Quad,Enum.EasingDirection.Out,0,false)
  1518. local aa = data.Circle:Clone();
  1519. aa.Parent = Effects
  1520. aa.Anchored = true
  1521. local blast = Sound(aa,334702766,1,5,false,true,true)
  1522. data.Circle:destroy()
  1523. if(not blast.IsLoaded)then repeat swait() until blast.IsLoaded end
  1524. Effect{
  1525. Effect='ResizeAndFade',
  1526. Color=MagicVariant.Color,
  1527. Size=V3.N(data.Mesh.Scale.X/20,data.Mesh.Scale.X/20,data.Mesh.Scale.X/20),
  1528. Mesh={MeshType=Enum.MeshType.Sphere},
  1529. CFrame=CF.N(pos),
  1530. Sound=blast,
  1531. FXSettings={
  1532. EndSize=V3.N(.05,.05,.05),
  1533. EndIsIncrement=true
  1534. }
  1535. }
  1536. for i = 1, 5 do
  1537. local angles = CF.A(M.RRNG(-180,180),M.RRNG(-180,180),M.RRNG(-180,180))
  1538. Effect{
  1539. Effect='Fade',
  1540. Frames=65,
  1541. Sound=blast,
  1542. Size=V3.N((data.Mesh.Scale.X/20)/2,(data.Mesh.Scale.X/20)/2,data.Mesh.Scale.X/20),
  1543. CFrame=CF.N(CF.N(pos)*angles*CF.N(0,0,-(data.Mesh.Scale.X/20)).p,pos),
  1544. Mesh = {MeshType=Enum.MeshType.Sphere},
  1545. Material=Enum.Material.Neon,
  1546. Color=MagicVariant.Color,
  1547. MoveDirection=CF.N(CF.N(pos)*angles*CF.N(0,0,-50).p,pos).p,
  1548. }
  1549. end
  1550. AOEDamage(pos,data.Mesh.Scale.X/20,45,75,0,'Normal',10,4)
  1551. coroutine.wrap(function()
  1552. for i = 1, (blast.TimeLength*Frame_Speed) do
  1553. part.Transparency = (i/(blast.TimeLength*Frame_Speed))
  1554. for _,v in next, aa:children() do if v:IsA'Decal' then v.Transparency = (i/(blast.TimeLength*Frame_Speed)) end end
  1555. swait()
  1556. end
  1557. aa:destroy()
  1558. part:destroy()
  1559. end)()
  1560.  
  1561. Attack = false
  1562. NeutralAnims = true
  1563. Root.Anchored = false
  1564. Root.Velocity = Mouse.Hit.lookVector*-125
  1565. end
  1566.  
  1567. function Skill1()
  1568. Laser(Enum.KeyCode.Q)
  1569. end
  1570.  
  1571. function Skill2()
  1572. DLaser(Enum.KeyCode.Z)
  1573. end
  1574.  
  1575. function Skill3()
  1576. BLaser(Enum.KeyCode.X)
  1577. end
  1578.  
  1579. --// Wrap it all up \\--
  1580.  
  1581. Mouse.KeyDown:connect(function(k)
  1582. if(Attack)then return end
  1583. if(k == 'q')then Skill1() end
  1584. if(k == 'z')then Skill2() end
  1585. if(k == 'x')then Skill3() end
  1586. end)
  1587.  
  1588. Player.Chatted:connect(function(m)
  1589.  
  1590. if(m:sub(1,3) == '/e ')then
  1591. local msg = m:sub(4)
  1592. --emote commands (gotta do)
  1593. end
  1594. end)
  1595. while true do
  1596. swait()
  1597. Sine = Sine + Change
  1598.  
  1599. local hitfloor,posfloor = workspace:FindPartOnRay(Ray.new(Root.CFrame.p,((CFrame.new(Root.Position,Root.Position - Vector3.new(0,1,0))).lookVector).unit * (4)), Char)
  1600.  
  1601. local Walking = (math.abs(Root.Velocity.x) > 1 or math.abs(Root.Velocity.z) > 1)
  1602. local State = (Hum.PlatformStand and 'Paralyzed' or Hum.Sit and 'Sit' or not hitfloor and Root.Velocity.y < -1 and "Fall" or not hitfloor and Root.Velocity.y > 1 and "Jump" or hitfloor and Walking and (Hum.WalkSpeed > 24 and "Run" or "Walk") or hitfloor and "Idle")
  1603. if(not Effects or not Effects.Parent)then
  1604. Effects = IN("Model",Char)
  1605. Effects.Name = "Effects"
  1606. end
  1607. if(State == 'Run')then
  1608. local wsVal = 20 / (Hum.WalkSpeed/16)
  1609. local Alpha = math.min(.2 * (Hum.WalkSpeed/16),1)
  1610. Change = 3
  1611. RH.C1 = RH.C1:lerp(CF.N(0,1,0)*CF.N(0,0-.2*M.C(Sine/wsVal),0+.4*M.C(Sine/wsVal))*CF.A(M.R(15+25*M.C(Sine/wsVal))+-M.S(Sine/wsVal),0,0),Alpha)
  1612. LH.C1 = LH.C1:lerp(CF.N(0,1,0)*CF.N(0,0+.2*M.C(Sine/wsVal),0-.4*M.C(Sine/wsVal))*CF.A(M.R(15-25*M.C(Sine/wsVal))+M.S(Sine/wsVal),0,0),Alpha)
  1613. elseif(State == 'Walk')then
  1614. local wsVal = 20 / (Hum.WalkSpeed/16)
  1615. local Alpha = math.min(.3 * (Hum.WalkSpeed/8),1)
  1616. Change = 3
  1617. RH.C1 = RH.C1:lerp(CF.N(0,1,0)*CF.N(0,0-.5*M.C(Sine/wsVal)/2,0+.6*M.C(Sine/wsVal)/2)*CF.A(M.R(15-2*M.C(Sine/wsVal))+-M.S(Sine/wsVal)/2.5,0,0),Alpha)
  1618. LH.C1 = LH.C1:lerp(CF.N(0,1,0)*CF.N(0,0+.5*M.C(Sine/wsVal)/2,0-.6*M.C(Sine/wsVal)/2)*CF.A(M.R(15+2*M.C(Sine/wsVal))+M.S(Sine/wsVal)/2.5,0,0),Alpha)
  1619. else
  1620. RH.C1 = RH.C1:lerp(CF.N(0,1,0),.2)
  1621. LH.C1 = LH.C1:lerp(CF.N(0,1,0),.2)
  1622. end
  1623.  
  1624. Hum.WalkSpeed = WalkSpeed
  1625.  
  1626. if(NeutralAnims)then
  1627. if(State == 'Idle')then
  1628. local Alpha = .1
  1629. Change = .75
  1630. RJ.C0 = RJ.C0:lerp(RJC0*CF.N(0+.2*M.C(Sine/12),.2*M.C(Sine/6),0)*CF.A(M.R(-5+5*M.C(Sine/12)),0,0),Alpha)
  1631. NK.C0 = NK.C0:lerp(NKC0*CF.A(M.R(-5+5*M.C(Sine/12)),0,0),Alpha)
  1632. LS.C0 = LS.C0:lerp(LSC0*CF.N(.25,0,0)*CF.A(M.R(-45),0,M.R(45+5*M.C(Sine/12))),Alpha)
  1633. RS.C0 = RS.C0:lerp(RSC0*CF.N(-.25,0,0)*CF.A(M.R(-45),0,M.R(-45-5*M.C(Sine/12))),Alpha)
  1634. LH.C0 = LH.C0:lerp(LHC0*CF.N(0-.2*M.C(Sine/12),-.2*M.C(Sine/6),0)*CF.A(M.R(5-5*M.C(Sine/12)),M.R(10),0),Alpha)
  1635. RH.C0 = RH.C0:lerp(RHC0*CF.N(0-.2*M.C(Sine/12),-.2*M.C(Sine/6),0)*CF.A(M.R(5-5*M.C(Sine/12)),M.R(-10),0),Alpha)
  1636. -- idle
  1637. elseif(State == 'Run')then
  1638. local wsVal = 20 / (Hum.WalkSpeed/16)
  1639. local Alpha = math.min(.2 * (Hum.WalkSpeed/16),1)
  1640. RJ.C0 = RJ.C0:lerp(CF.N(0,0-.1*M.C(Sine/(wsVal/2)),0)*CF.A(M.R(-15+2.5*M.C(Sine/(wsVal/2))),M.R(8*M.C(Sine/wsVal)),0),Alpha)
  1641. NK.C0 = NK.C0:lerp(NKC0,Alpha)
  1642. LS.C0 = LS.C0:lerp(LSC0*CF.N(0,0,0-.3*M.S(Sine/wsVal))*CF.A(M.R(0+45*M.S(Sine/wsVal)),0,M.R(-5)),Alpha)
  1643. RS.C0 = RS.C0:lerp(RSC0*CF.N(0,0,0+.3*M.S(Sine/wsVal))*CF.A(M.R(0-45*M.S(Sine/wsVal)),0,M.R(5)),Alpha)
  1644. LH.C0 = LH.C0:lerp(LHC0*CF.N(0,0+.1*M.C(Sine/(wsVal/2)),0)*CF.A(0,-M.R(4*M.C(Sine/wsVal)),0),Alpha)
  1645. RH.C0 = RH.C0:lerp(RHC0*CF.N(0,0+.1*M.C(Sine/(wsVal/2)),0)*CF.A(0,-M.R(4*M.C(Sine/wsVal)),0),Alpha)
  1646. elseif(State == 'Walk')then
  1647. local wsVal = 20 / (Hum.WalkSpeed/16)
  1648. local Alpha = math.min(.3 * (Hum.WalkSpeed/16),1)
  1649. RJ.C0 = RJ.C0:lerp(CF.N(0,0-.1*M.C(Sine/(wsVal/2)),0)*CF.A(M.R(-5-2.5*M.C(Sine/(wsVal/2))),M.R(8*M.C(Sine/wsVal)),0),Alpha)
  1650. NK.C0 = NK.C0:lerp(NKC0,Alpha)
  1651. LS.C0 = LS.C0:lerp(LSC0*CF.N(0,0,-.22*M.C(Sine/wsVal))*CF.A(M.R(37*M.C(Sine/wsVal)),0,M.R(-5)),Alpha)
  1652. RS.C0 = RS.C0:lerp(RSC0*CF.N(0,0,.22*M.C(Sine/wsVal))*CF.A(M.R(-37*M.C(Sine/wsVal)),0,M.R(5)),Alpha)
  1653. LH.C0 = LH.C0:lerp(LHC0*CF.N(0,0+.1*M.C(Sine/(wsVal/2)),0)*CF.A(0,-M.R(4*M.C(Sine/wsVal)),0),Alpha)
  1654. RH.C0 = RH.C0:lerp(RHC0*CF.N(0,0+.1*M.C(Sine/(wsVal/2)),0)*CF.A(0,-M.R(4*M.C(Sine/wsVal)),0),Alpha)
  1655. elseif(State == 'Jump')then
  1656. local Alpha = .1
  1657. local idk = math.min(math.max(Root.Velocity.Y/50,-M.R(90)),M.R(90))
  1658. LS.C0 = LS.C0:lerp(LSC0*CF.A(M.R(-5),0,M.R(-90)),Alpha)
  1659. RS.C0 = RS.C0:lerp(RSC0*CF.A(M.R(-5),0,M.R(90)),Alpha)
  1660. RJ.C0 = RJ.C0:lerp(RJC0*CF.A(math.min(math.max(Root.Velocity.Y/100,-M.R(45)),M.R(45)),0,0),Alpha)
  1661. NK.C0 = NK.C0:lerp(NKC0*CF.A(math.min(math.max(Root.Velocity.Y/100,-M.R(45)),M.R(45)),0,0),Alpha)
  1662. LH.C0 = LH.C0:lerp(LHC0*CF.A(0,0,M.R(-5)),Alpha)
  1663. RH.C0 = RH.C0:lerp(RHC0*CF.N(0,1,-1)*CF.A(M.R(-5),0,M.R(5)),Alpha)
  1664. elseif(State == 'Fall')then
  1665. local Alpha = .1
  1666. local idk = math.min(math.max(Root.Velocity.Y/50,-M.R(90)),M.R(90))
  1667. LS.C0 = LS.C0:lerp(LSC0*CF.A(M.R(-5),0,M.R(-90)+idk),Alpha)
  1668. RS.C0 = RS.C0:lerp(RSC0*CF.A(M.R(-5),0,M.R(90)-idk),Alpha)
  1669. RJ.C0 = RJ.C0:lerp(RJC0*CF.A(math.min(math.max(Root.Velocity.Y/100,-M.R(45)),M.R(45)),0,0),Alpha)
  1670. NK.C0 = NK.C0:lerp(NKC0*CF.A(math.min(math.max(Root.Velocity.Y/100,-M.R(45)),M.R(45)),0,0),Alpha)
  1671. LH.C0 = LH.C0:lerp(LHC0*CF.A(0,0,M.R(-5)),Alpha)
  1672. RH.C0 = RH.C0:lerp(RHC0*CF.N(0,1,-1)*CF.A(M.R(-5),0,M.R(5)),Alpha)
  1673. elseif(State == 'Paralyzed')then
  1674. -- paralyzed
  1675. elseif(State == 'Sit')then
  1676. -- sit
  1677. end
  1678. end
  1679.  
  1680. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement