Advertisement
Zach_script_stealer2

Le sans FE fix?

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