Advertisement
wormybag9035

sdsada

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