Advertisement
StarzoZero

Roblox FE Sans Script

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