Advertisement
Hermaxs

Untitled

Jan 14th, 2019
131
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 24.48 KB | None | 0 0
  1. --https://github.com/Mokiros/roblox-FE-compatibility
  2. if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
  3. local Player,game,owner = owner,game
  4. local RealPlayer = Player
  5. do print("FE Compatibility code V2 by Mokiros")local RealPlayer=RealPlayer;script.Parent=RealPlayer.Character;local a=function(b)b[1].f[b[2]]=nil end;local c={__index={disconnect=a,Disconnect=a}}local d={__index={Connect=function(b,e)local f=tostring(math.random(0,10000))while b.f[f]do f=tostring(math.random(0,10000))end;b.f[f]=e;return setmetatable({b,f},c)end}}d.__index.connect=d.__index.Connect;local function g()return setmetatable({f={}},d)end;local h={Hit=CFrame.new(),KeyUp=g(),KeyDown=g(),Button1Up=g(),Button1Down=g(),Button2Up=g(),Button2Down=g()}h.keyUp=h.KeyUp;h.keyDown=h.KeyDown;local i={InputBegan=g(),InputEnded=g()}local CAS={Actions={},BindAction=function(self,j,k,l,...)CAS.Actions[j]=k and{Name=j,Function=k,Keys={...}}or nil end}CAS.UnbindAction=CAS.BindAction;local function m(self,n,...)for o,e in pairs(self[n].f)do e(...)end end;h.T=m;i.T=m;local p=Instance.new("RemoteEvent")p.Name="UserInput_Event"p.OnServerEvent:Connect(function(q,r)if q~=RealPlayer then return end;h.Target=r.e;h.Hit=r.d;if not r.f then local s=r.c==Enum.UserInputState.Begin;if r.b==Enum.UserInputType.MouseButton1 then return h:T(s and"Button1Down"or"Button1Up")end;if r.b==Enum.UserInputType.MouseButton2 then return h:T(s and"Button2Down"or"Button2Up")end;for o,t in pairs(CAS.Actions)do for o,u in pairs(t.Keys)do if u==r.a then t.Function(t.Name,r.c,r)end end end;h:T(s and"KeyDown"or"KeyUp",r.a.Name:lower())i:T(s and"InputBegan"or"InputEnded",r,false)end end)p.Parent=NLS([==[local a=script:WaitForChild("UserInput_Event")local b=owner:GetMouse()local c=game:GetService("UserInputService")local d=function(e,f)if f then return end;a:FireServer({a=e.KeyCode,b=e.UserInputType,c=e.UserInputState,d=b.Hit,e=b.Target})end;c.InputBegan:Connect(d)c.InputEnded:Connect(d)local g,h;local i=game:GetService("RunService").Heartbeat;while true do if g~=b.Hit or h~=b.Target then g,h=b.Hit,b.Target;a:FireServer({f=1,Target=h,d=g})end;for j=1,2 do i:Wait()end end]==],script)local v=game;local w={__index=function(self,u)local x=rawget(self,"_RealService")if x then return typeof(x[u])=="function"and function(o,...)return x[u](x,...)end or x[u]end end,__newindex=function(self,u,y)local x=rawget(self,"_RealService")if x then x[u]=y end end}local function z(t,A)t._RealService=typeof(A)=="string"and v:GetService(A)or A;return setmetatable(t,w)end;local B={GetService=function(self,x)return rawget(self,x)or v:GetService(x)end,Players=z({LocalPlayer=z({GetMouse=function(self)return h end},Player)},"Players"),UserInputService=z(i,"UserInputService"),ContextActionService=z(CAS,"ContextActionService"),RunService=z({_btrs={},RenderStepped=v:GetService("RunService").Heartbeat,BindToRenderStep=function(self,j,o,k)self._btrs[j]=self.Heartbeat:Connect(k)end,UnbindFromRenderStep=function(self,j)self._btrs[j]:Disconnect()end},"RunService")}rawset(B.Players,"localPlayer",B.Players.LocalPlayer)B.service=B.GetService;z(B,game)game,owner=B,B.Players.LocalPlayer end
  6.  
  7.  
  8. --[[ Script Converted by WafflesAreVeryGood (Nobody#3907 on discord) ]]--
  9. local plr = game:GetService('Players').LocalPlayer
  10. local char = plr.Character
  11. local mouse = plr:GetMouse()
  12. --Converted with ttyyuu12345's model to script plugin v4
  13. function sandbox(var,func)
  14. local env = getfenv(func)
  15. local newenv = setmetatable({},{
  16. __index = function(self,k)
  17. if k=="script" then
  18. return var
  19. else
  20. return env[k]
  21. end
  22. end,
  23. })
  24. setfenv(func,newenv)
  25. return func
  26. end
  27. cors = {}
  28. mas = Instance.new("Model",game:GetService("Lighting"))
  29. Tool0 = Instance.new("Tool")
  30. Folder1 = Instance.new("Folder")
  31. Sound2 = Instance.new("Sound")
  32. Model3 = Instance.new("Model")
  33. Part4 = Instance.new("Part")
  34. SpecialMesh5 = Instance.new("SpecialMesh")
  35. ManualWeld6 = Instance.new("ManualWeld")
  36. ManualWeld7 = Instance.new("ManualWeld")
  37. ManualWeld8 = Instance.new("ManualWeld")
  38. WedgePart9 = Instance.new("WedgePart")
  39. Part10 = Instance.new("Part")
  40. SpecialMesh11 = Instance.new("SpecialMesh")
  41. Script12 = Instance.new("Script")
  42. Part13 = Instance.new("Part")
  43. ParticleEmitter14 = Instance.new("ParticleEmitter")
  44. Part15 = Instance.new("Part")
  45. ParticleEmitter16 = Instance.new("ParticleEmitter")
  46. Animation17 = Instance.new("Animation")
  47. Tool0.Name = "Gaster Blaster"
  48. Tool0.Parent = mas
  49. Tool0.TextureId = "rbxassetid://382220657"
  50. Tool0.ToolTip = "Gaster Blaster: Used By Sans"
  51. Tool0.CanBeDropped = false
  52. Folder1.Parent = Tool0
  53. Sound2.Name = "GBSound"
  54. Sound2.Parent = Folder1
  55. Sound2.SoundId = "rbxassetid://382265669"
  56. Sound2.Volume = 1
  57. Model3.Name = "GB"
  58. Model3.Parent = Folder1
  59. Model3.PrimaryPart = Part4
  60. Part4.Name = "Main"
  61. Part4.Parent = Model3
  62. Part4.Material = Enum.Material.SmoothPlastic
  63. Part4.BrickColor = BrickColor.new("Institutional white")
  64. Part4.Rotation = Vector3.new(178.669998, -0.049999997, 179.819992)
  65. Part4.Anchored = true
  66. Part4.CanCollide = false
  67. Part4.FormFactor = Enum.FormFactor.Custom
  68. Part4.Size = Vector3.new(0.200000003, 0.200000003, 0.200000003)
  69. Part4.CFrame = CFrame.new(9.6476717, 212.837067, 62.5175667, -0.999994874, -0.0030922927, -0.000849041739, -0.00307168509, 0.999724269, -0.0232850946, 0.000920811843, -0.0232823677, -0.99972856)
  70. Part4.BackSurface = Enum.SurfaceType.SmoothNoOutlines
  71. Part4.BottomSurface = Enum.SurfaceType.SmoothNoOutlines
  72. Part4.FrontSurface = Enum.SurfaceType.SmoothNoOutlines
  73. Part4.LeftSurface = Enum.SurfaceType.SmoothNoOutlines
  74. Part4.RightSurface = Enum.SurfaceType.SmoothNoOutlines
  75. Part4.TopSurface = Enum.SurfaceType.SmoothNoOutlines
  76. Part4.Color = Color3.new(0.972549, 0.972549, 0.972549)
  77. Part4.Position = Vector3.new(9.6476717, 212.837067, 62.5175667)
  78. Part4.Orientation = Vector3.new(1.32999992, -179.949997, -0.179999992)
  79. Part4.Color = Color3.new(0.972549, 0.972549, 0.972549)
  80. SpecialMesh5.Parent = Part4
  81. SpecialMesh5.MeshId = "http://www.roblox.com/asset/?id=14028428"
  82. SpecialMesh5.Scale = Vector3.new(4.23171806, 4.23171759, 4.23171663)
  83. SpecialMesh5.VertexColor = Vector3.new(1000000, 10000, 10000)
  84. SpecialMesh5.MeshType = Enum.MeshType.FileMesh
  85. SpecialMesh5.Scale = Vector3.new(4.23171806, 4.23171759, 4.23171663)
  86. ManualWeld6.Name = "Weld"
  87. ManualWeld6.Parent = Part4
  88. ManualWeld6.C0 = CFrame.new(0, 0, 0, -0.999994874, -0.00307097379, 0.000981842401, -0.00309300236, 0.99972415, -0.0232822727, -0.000910072413, -0.0232851878, -0.999728441)
  89. ManualWeld6.C1 = CFrame.new(0.225479126, 3.69114685, 0.0936775208, -0.0154458769, 0.34394905, 0.93886131, 0.0187007096, 0.938908398, -0.343658656, -0.999705911, 0.0122492611, -0.0209343527)
  90. ManualWeld6.Part0 = Part4
  91. ManualWeld6.Part1 = nil
  92. ManualWeld7.Name = "Weld"
  93. ManualWeld7.Parent = Part4
  94. ManualWeld7.C0 = CFrame.new(0, 0, 0, -0.999994874, -0.00307097379, 0.000981842401, -0.00309300236, 0.99972415, -0.0232822727, -0.000910072413, -0.0232851878, -0.999728441)
  95. ManualWeld7.C1 = CFrame.new(0.141029358, 4.85009766, 0.616783142, -0.872494459, -0.293409586, 0.390722692, -0.0644136816, 0.861726344, 0.503268003, -0.484359652, 0.413930595, -0.770751119)
  96. ManualWeld7.Part0 = Part4
  97. ManualWeld7.Part1 = nil
  98. ManualWeld8.Name = "Weld"
  99. ManualWeld8.Parent = Part4
  100. ManualWeld8.C0 = CFrame.new(0, 0, 0, -0.999994874, -0.00307097379, 0.000981842401, -0.00309300236, 0.99972415, -0.0232822727, -0.000910072413, -0.0232851878, -0.999728441)
  101. ManualWeld8.C1 = CFrame.new(0.0476670265, 0.962097168, 5.07106781, 1, 3.98733209e-05, -1.65144629e-05, -1.65144629e-05, 0.707063794, 0.707141817, 3.98733209e-05, -0.707141817, 0.707063794)
  102. ManualWeld8.Part0 = Part4
  103. ManualWeld8.Part1 = WedgePart9
  104. WedgePart9.Parent = Model3
  105. WedgePart9.BrickColor = BrickColor.new("Institutional white")
  106. WedgePart9.Rotation = Vector3.new(45, 0, 0)
  107. WedgePart9.CanCollide = false
  108. WedgePart9.FormFactor = Enum.FormFactor.Symmetric
  109. WedgePart9.Size = Vector3.new(1.60000014, 1.5999999, 4.4000001)
  110. WedgePart9.CFrame = CFrame.new(9.59999466, 215.742599, 58.2514572, 1, 1.65165984e-05, -3.98718948e-05, -3.98723896e-05, 0.707119346, -0.707094252, 1.65153942e-05, 0.707094252, 0.707119346)
  111. WedgePart9.BackSurface = Enum.SurfaceType.SmoothNoOutlines
  112. WedgePart9.BottomSurface = Enum.SurfaceType.SmoothNoOutlines
  113. WedgePart9.FrontSurface = Enum.SurfaceType.SmoothNoOutlines
  114. WedgePart9.LeftSurface = Enum.SurfaceType.SmoothNoOutlines
  115. WedgePart9.RightSurface = Enum.SurfaceType.SmoothNoOutlines
  116. WedgePart9.TopSurface = Enum.SurfaceType.SmoothNoOutlines
  117. WedgePart9.Color = Color3.new(0.972549, 0.972549, 0.972549)
  118. WedgePart9.Position = Vector3.new(9.59999466, 215.742599, 58.2514572)
  119. WedgePart9.Orientation = Vector3.new(45, 0, 0)
  120. WedgePart9.Color = Color3.new(0.972549, 0.972549, 0.972549)
  121. Part10.Name = "GBBeam"
  122. Part10.Parent = Folder1
  123. Part10.Material = Enum.Material.SmoothPlastic
  124. Part10.BrickColor = BrickColor.new("Institutional white")
  125. Part10.Rotation = Vector3.new(0, 90, 0)
  126. Part10.Anchored = true
  127. Part10.CanCollide = false
  128. Part10.FormFactor = Enum.FormFactor.Custom
  129. Part10.Size = Vector3.new(200, 6, 6)
  130. Part10.CFrame = CFrame.new(-2.50004816, 4.40002823, -1021.19995, 5.34682295e-05, 1.23517841e-13, 1, -4.3159529e-05, 1, 2.30754016e-09, -1, -4.3159529e-05, 5.34682331e-05)
  131. Part10.BackSurface = Enum.SurfaceType.SmoothNoOutlines
  132. Part10.BottomSurface = Enum.SurfaceType.SmoothNoOutlines
  133. Part10.FrontSurface = Enum.SurfaceType.SmoothNoOutlines
  134. Part10.LeftSurface = Enum.SurfaceType.SmoothNoOutlines
  135. Part10.RightSurface = Enum.SurfaceType.SmoothNoOutlines
  136. Part10.TopSurface = Enum.SurfaceType.SmoothNoOutlines
  137. Part10.Color = Color3.new(1, 1, 1)
  138. Part10.Position = Vector3.new(-2.50004816, 4.40002823, -1021.19995)
  139. Part10.Orientation = Vector3.new(0, 90, 0)
  140. Part10.Color = Color3.new(1, 1, 1)
  141. SpecialMesh11.Parent = Part10
  142. SpecialMesh11.MeshType = Enum.MeshType.Cylinder
  143. Script12.Parent = Part10
  144. Script12.Disabled = true
  145. Part13.Name = "HandFlame"
  146. Part13.Parent = Folder1
  147. Part13.Transparency = 1
  148. Part13.Rotation = Vector3.new(0, 0, -30)
  149. Part13.Anchored = true
  150. Part13.CanCollide = false
  151. Part13.FormFactor = Enum.FormFactor.Custom
  152. Part13.Size = Vector3.new(0.200000003, 0.200000003, 0.200000003)
  153. Part13.CFrame = CFrame.new(-8.29995918, 203.950241, 50.9999504, 0.866004944, 0.500030637, -2.15781438e-05, -0.500030637, 0.866004944, 3.73764087e-05, 3.73764087e-05, -2.15781438e-05, 1)
  154. Part13.Position = Vector3.new(-8.29995918, 203.950241, 50.9999504)
  155. Part13.Orientation = Vector3.new(0, 0, -30)
  156. ParticleEmitter14.Name = "Flame"
  157. ParticleEmitter14.Parent = Part13
  158. ParticleEmitter14.Transparency = NumberSequence.new(0.69999998807907,0.69999998807907,0.94999998807907,1)
  159. ParticleEmitter14.Rotation = NumberRange.new(-180, 180)
  160. ParticleEmitter14.Size = NumberSequence.new(0.5,0.5)
  161. ParticleEmitter14.Color = ColorSequence.new(Color3.new(0, 0.392157, 1),Color3.new(0, 0.392157, 1))
  162. ParticleEmitter14.LightEmission = 1
  163. ParticleEmitter14.Texture = "http://www.roblox.com/asset/?id=298319954"
  164. ParticleEmitter14.ZOffset = 0.5
  165. ParticleEmitter14.Lifetime = NumberRange.new(3, 3)
  166. ParticleEmitter14.Rate = 500
  167. ParticleEmitter14.Speed = NumberRange.new(2, 2)
  168. ParticleEmitter14.VelocitySpread = 45
  169. ParticleEmitter14.Color = ColorSequence.new(Color3.new(0, 0.392157, 1),Color3.new(0, 0.392157, 1))
  170. Part15.Name = "HeadFlame"
  171. Part15.Parent = Folder1
  172. Part15.Transparency = 1
  173. Part15.Rotation = Vector3.new(0, 0, 79.6899948)
  174. Part15.Anchored = true
  175. Part15.CanCollide = false
  176. Part15.FormFactor = Enum.FormFactor.Custom
  177. Part15.Size = Vector3.new(0.200000003, 0.200000003, 0.200000003)
  178. Part15.CFrame = CFrame.new(-10.0999317, 211.071381, 50.400013, 0.178991079, -0.983850658, -4.29847787e-05, 0.983850658, 0.178991094, 3.88006174e-06, 3.87649106e-06, -4.29850988e-05, 1)
  179. Part15.Position = Vector3.new(-10.0999317, 211.071381, 50.400013)
  180. Part15.Orientation = Vector3.new(0, 0, 79.6899948)
  181. ParticleEmitter16.Name = "Flame"
  182. ParticleEmitter16.Parent = Part15
  183. ParticleEmitter16.Transparency = NumberSequence.new(0.69999998807907,0.89999997615814,1)
  184. ParticleEmitter16.Rotation = NumberRange.new(-180, 180)
  185. ParticleEmitter16.Size = NumberSequence.new(0.5,0.5)
  186. ParticleEmitter16.Color = ColorSequence.new(Color3.new(0, 0.392157, 1),Color3.new(0, 0.392157, 1))
  187. ParticleEmitter16.LightEmission = 1
  188. ParticleEmitter16.Texture = "http://www.roblox.com/asset/?id=134531489"
  189. ParticleEmitter16.Acceleration = Vector3.new(0, 20, 0)
  190. ParticleEmitter16.Lifetime = NumberRange.new(0.60000002384186, 0.60000002384186)
  191. ParticleEmitter16.Rate = 500
  192. ParticleEmitter16.Speed = NumberRange.new(10, 10)
  193. ParticleEmitter16.Color = ColorSequence.new(Color3.new(0, 0.392157, 1),Color3.new(0, 0.392157, 1))
  194. Animation17.Name = "GBSend"
  195. Animation17.Parent = Folder1
  196. Animation17.AnimationId = "http://www.roblox.com/GBSend-item?id=388238523"
  197. for i,v in pairs(mas:GetChildren()) do
  198. v.Parent = game:GetService("Players").LocalPlayer.Character
  199. pcall(function() v:MakeJoints() end)
  200. end
  201. mas:Destroy()
  202. for i,v in pairs(cors) do
  203. spawn(function()
  204. pcall(v)
  205. end)
  206. end
  207. Tool0.RequiresHandle = false
  208. local tool = char["Gaster Blaster"]
  209. for i,v in pairs(tool.Folder:GetChildren()) do
  210. v.Parent = script
  211. end
  212. script.Parent = tool
  213. tool.Parent = plr.Backpack
  214. local hum=char:WaitForChild("Humanoid")
  215. local torso=char:WaitForChild("Torso")
  216. local hrp=char:WaitForChild("HumanoidRootPart")
  217. local check=false
  218. local dmg=false
  219. local combo=false
  220. local comboing=false
  221. local gb=script.GB
  222. local gbsend=hum:LoadAnimation(script.GBSend)
  223. local equipped=false
  224. local tool=script.Parent
  225. local closest=nil
  226. crosstab={
  227. [1]={math.cos(math.rad(45)),math.sin(math.rad(45))},
  228. [2]={math.cos(math.rad(135)),math.sin(math.rad(135))},
  229. [3]={math.cos(math.rad(225)),math.sin(math.rad(225))},
  230. [4]={math.cos(math.rad(315)),math.sin(math.rad(315))}
  231. }
  232. local attacklist={}
  233. local rignore={}
  234. local lgb=nil
  235. local rgb=nil
  236. local lgbbp=nil
  237. local rgbbp=nil
  238. local lgbbg=nil
  239. local rgbbg=nil
  240. local headf=nil
  241. local handf=nil
  242.  
  243. for _,v in pairs(workspace:GetChildren()) do
  244. if not v:FindFirstChild("Humanoid") then
  245. table.insert(rignore,v)
  246. end
  247. end
  248.  
  249. function Loop()
  250. coroutine.resume(coroutine.create(function()
  251. while equipped==true do
  252. repeat wait() until rgb:FindFirstChild("Main") and lgb:FindFirstChild("Main")
  253. rgb.Main.Velocity = Vector3.new()
  254. lgb.Main.Velocity = Vector3.new()
  255. rgbbp.Position=(hrp.CFrame*CFrame.new(10,5,0)).p
  256. lgbbp.Position=(hrp.CFrame*CFrame.new(-10,5,0)).p
  257. rgbbg.CFrame=CFrame.new(rgb.Main.Position,mouse.Hit.p)
  258. lgbbg.CFrame=CFrame.new(lgb.Main.Position,mouse.Hit.p)
  259. rgb.Main.Anchored = false
  260. lgb.Main.Anchored = false
  261. wait()
  262. end
  263. end))
  264. end
  265.  
  266. local function PrepareHurt(proj,dmgcheck,dmg)
  267. return --[[
  268. local ray=Ray.new((proj.CFrame*CFrame.new(-proj.Size.X/2,0,0)).p,(hitpos-(proj.CFrame*CFrame.new(-proj.Size.X/2,0,0)).p).unit*100)
  269. for _,v in pairs(workspace:GetChildren()) do
  270. if v.Name=="GBBeam" then
  271. table.insert(rignore,v)
  272. end
  273. end
  274. local hit=workspace:FindPartOnRayWithIgnoreList(ray,rignore)
  275. if hit then
  276. if hit.Parent:FindFirstChild("Humanoid") and hit.Parent.Name~=plr.Name then
  277. if hit.Parent.Humanoid.Health>0 then
  278. hit.Parent.Humanoid:TakeDamage(dmg)
  279. end
  280. end
  281. end]]
  282. end
  283. function fakescript(beamasd)
  284. local script = {Parent = beamasd}
  285. local key=math.random()
  286.  
  287. function onTouched(hit)
  288. local human = hit.Parent:FindFirstChildOfClass("Humanoid")
  289. --Basically this just checks to see if it is a real player touching this brick.
  290. if (human ~= nil) and hit.Parent ~= char then --If it is a real player, then DESTROY THEM!
  291. print("y'all")
  292. human.Health = human.Health - 7.5*(1-script.Parent.Transparency)
  293. end
  294. end
  295.  
  296.  
  297. if (script.Parent ~= nil) and (script.Parent.className == "Part") then --Work if in a block
  298. connection = script.Parent.Touched:connect(onTouched)
  299. end
  300. local beam=script.Parent
  301. local bp = Instance.new("BodyPosition")
  302. bp.MaxForce = Vector3.new(math.huge,math.huge,math.huge)
  303. bp.Position = beam.Position
  304. bp.Parent = beam
  305. beam.Anchored = false
  306. coroutine.resume(coroutine.create(function()
  307. wait(0.3)
  308. for i=1,10 do
  309. if not beam:FindFirstChild"Mesh" then return end
  310. beam.Mesh.Scale=Vector3.new(1,1-(i/9),1-(i/9))
  311. wait()
  312. end
  313. end))
  314. wait(0.4)
  315. for i=1,15 do
  316. bp.Position = beam.Position
  317. beam.Transparency=i/15
  318. wait()
  319. end
  320. wait()
  321. beam:Destroy()
  322. end
  323. local function FIRE(obj,mode,thitpos)
  324. coroutine.resume(coroutine.create(function()
  325. if mode=="Normal" then
  326. obj.Main.CFrame=hrp.CFrame*CFrame.new(math.random(-100,100),math.random(0,200),math.random(-100,100))
  327. end
  328. local dmgcheck=false
  329. local gbsfx=script.GBSound:Clone()
  330. gbsfx.Parent=obj.Main
  331. gbsfx:Play()
  332. game.Debris:AddItem(gbsfx,3)
  333. wait(1)
  334. local beam=script.GBBeam:Clone()
  335. beam.CFrame=obj.Main.CFrame*CFrame.new(0,-3,1)
  336. spawn(function()
  337. fakescript(beam)
  338. end)
  339. beam.Size=Vector3.new(((beam.CFrame*CFrame.new(0,0,-beam.Size.X/2)).p-hitpos).magnitude*2,beam.Size.Y,beam.Size.Z)
  340. if mode~="Dual" then
  341. beam.CFrame=CFrame.new(beam.Position,thitpos)*CFrame.Angles(0,math.pi/2,0)
  342. else
  343. beam.CFrame=CFrame.new(beam.Position,mouse.Hit.p)*CFrame.Angles(0,math.pi/2,0)
  344. end
  345. beam.CFrame=beam.CFrame*CFrame.new(beam.Size.X/2,0,0)
  346. beam.Transparency=0
  347. local m = Instance.new("SpecialMesh")
  348. m.MeshType = "Cylinder"
  349. m.Parent = beam
  350. beam.Mesh.Scale=Vector3.new(1,1,1)
  351. --PrepareHurt(beam,dmgcheck,10)
  352. beam.Parent = char
  353. if mode=="Dual" then
  354. end
  355. end))
  356. end
  357.  
  358. local function Lerp(obj,kind,nb,total,spec)
  359. obj.Main.Anchored=false
  360. local bodyp=Instance.new("BodyPosition",obj.Main)
  361. bodyp.MaxForce=Vector3.new(math.huge,math.huge,math.huge)
  362. bodyp.D=100
  363. bodyp.P=1000
  364. local gyro=Instance.new("BodyGyro",obj.Main)
  365. gyro.MaxTorque=Vector3.new(10000,10000,10000)
  366. gyro.D=80
  367. if kind=="Front" then
  368. obj.CFrame=hrp.CFrame*CFrame.new(math.random(-10,10),math.random(0,5),-5)
  369. end
  370. coroutine.resume(coroutine.create(function()
  371. wait()
  372. gyro.CFrame=CFrame.new(obj.Main.Position,hitpos)
  373. wait(0.5)
  374. gyro.CFrame=CFrame.new(obj.Main.Position,hitpos)
  375. end))
  376. if kind=="Line" then
  377. if total==0 then
  378. bodyp.Position=hrp.Position+Vector3.new(0,10,0)
  379. elseif total==2 then
  380. if nb==1 then
  381. bodyp.Position=hrp.Position+Vector3.new(5,0,4)
  382. elseif nb==2 then
  383. bodyp.Position=hrp.Position+Vector3.new(-5,0,4)
  384. end
  385. elseif total==6 then
  386. if nb==1 then
  387. bodyp.Position=(hrp.CFrame*CFrame.new(-30,1,0)).p
  388. elseif nb==2 then
  389. bodyp.Position=(hrp.CFrame*CFrame.new(-20,1,0)).p
  390. elseif nb==3 then
  391. bodyp.Position=(hrp.CFrame*CFrame.new(-10,1,0)).p
  392. elseif nb==4 then
  393. bodyp.Position=(hrp.CFrame*CFrame.new(10,1,0)).p
  394. elseif nb==5 then
  395. bodyp.Position=(hrp.CFrame*CFrame.new(20,1,0)).p
  396. elseif nb==6 then
  397. bodyp.Position=(hrp.CFrame*CFrame.new(30,1,0)).p
  398. end
  399. end
  400. elseif kind=="Circle" then
  401. if spec=="Cross" then
  402. bodyp.Position=hitpos+Vector3.new(crosstab[nb][1],3/50,crosstab[nb][2])*50
  403. elseif spec=="Plus" or spec=="Total" then
  404. bodyp.Position=hitpos+Vector3.new(math.cos(math.rad(nb*(360/total))),3/50,math.sin(math.rad(nb*(360/total))))*50
  405. end
  406. end
  407. end
  408. function debris(obj, t)
  409. spawn(function()
  410. wait(t)
  411. for i = 1, 10 do
  412. for _,v in pairs(obj:GetChildren()) do
  413. if v:IsA("BasePart") and v.Transparency < 1 then
  414. v.Transparency = i/10
  415. end
  416. end
  417. game:GetService('RunService').Stepped:wait(0)
  418. end
  419. for _,v in pairs(obj:GetChildren()) do
  420. v:Destroy()
  421. end
  422. end)
  423. end
  424.  
  425. local function PrepareAttack(key)
  426. if check==false and hum.Health>0 then
  427. if closest==nil then
  428. hitpos=mouse.Hit.p
  429. else
  430. hitpos=closest.Torso.Position
  431. end
  432. if equipped==true then
  433. if key=="q" then
  434. combo=true
  435. elseif key=="e" then
  436. if combo==false then
  437. check=true
  438. hum.WalkSpeed=0
  439. gbsend:Play()
  440. local gbc=gb:Clone()
  441. gbc.Parent=char
  442. gbc.Main.CFrame=hrp.CFrame*CFrame.new(math.random(-100,100),math.random(0,200),math.random(-100,100))
  443. Lerp(gbc,"Line",0,0)
  444. FIRE(gbc,"Normal",hitpos)
  445. hum.WalkSpeed=30
  446. debris(gbc, 1.8)
  447. if comboing==false then
  448. wait(1)
  449. else
  450. wait(0.25)
  451. end
  452. check=false
  453. elseif combo==true and #attacklist<5 then
  454. table.insert(attacklist,key)
  455. end
  456. elseif key=="r" then
  457. if combo==false then
  458. check=true
  459. hum.WalkSpeed=0
  460. gbsend:Play()
  461. FIRE(lgb,"Dual",hitpos)
  462. FIRE(rgb,"Dual",hitpos)
  463. hum.WalkSpeed=30
  464. if comboing==false then
  465. wait(1.5)
  466. else
  467. wait(0.325)
  468. end
  469. check=false
  470. elseif combo==true and #attacklist<5 then
  471. table.insert(attacklist,key)
  472. end
  473. elseif key=="t" then
  474. if combo==false then
  475. check=true
  476. hum.WalkSpeed=0
  477. gbsend:Play()
  478. for i=1,12 do
  479. local gbc=gb:Clone()
  480. gbc.Parent=char
  481. debris(gbc, 1.8)
  482. gbc.Main.CFrame=hrp.CFrame*CFrame.new(math.random(-100,100),math.random(0,200),math.random(-100,100))
  483. coroutine.resume(coroutine.create(function()
  484. Lerp(gbc,"Circle",i,12,"Total")
  485. FIRE(gbc,"Normal",hitpos)
  486. end))
  487. wait(0.05)
  488. end
  489. hum.WalkSpeed=30
  490. if comboing==false then
  491. wait(7)
  492. else
  493. wait(5)
  494. end
  495. check=false
  496. elseif combo==true and #attacklist==4 then
  497. table.insert(attacklist,key)
  498. end
  499. elseif key=="f" then
  500. if combo==false then
  501. check=true
  502. hum.WalkSpeed=0
  503. gbsend:Play()
  504. for i=1,4 do
  505. local gbc=gb:Clone()
  506. gbc.Parent=char
  507. debris(gbc, 1.8)
  508. coroutine.resume(coroutine.create(function()
  509. Lerp(gbc,"Circle",i,4,"Plus")
  510. FIRE(gbc,"Normal",hitpos)
  511. end))
  512. end
  513. hum.WalkSpeed=30
  514. if comboing==false then
  515. wait(2)
  516. else
  517. wait(0.5)
  518. end
  519. check=false
  520. elseif combo==true and #attacklist<5 then
  521. table.insert(attacklist,key)
  522. end
  523. elseif key=="g" then
  524. if combo==false then
  525. check=true
  526. hum.WalkSpeed=0
  527. gbsend:Play()
  528. for i=1,4 do
  529. local gbc=gb:Clone()
  530. gbc.Parent=char
  531. debris(gbc, 1.8)
  532. coroutine.resume(coroutine.create(function()
  533. Lerp(gbc,"Circle",i,4,"Cross")
  534. FIRE(gbc,"Normal",hitpos)
  535. end))
  536. end
  537. hum.WalkSpeed=30
  538. if comboing==false then
  539. wait(2)
  540. else
  541. wait(0.5)
  542. end
  543. check=false
  544. elseif combo==true and #attacklist<5 then
  545. table.insert(attacklist,key)
  546. end
  547. elseif key=="h" then
  548. if combo==false then
  549. check=true
  550. hum.WalkSpeed=0
  551. gbsend:Play()
  552. for i=1,8 do
  553. local gbc=gb:Clone()
  554. gbc.Parent=char
  555. debris(gbc, 1.8)
  556. coroutine.resume(coroutine.create(function()
  557. Lerp(gbc,"Circle",i,8,"Total")
  558. FIRE(gbc,"Normal",hitpos)
  559. end))
  560. end
  561. hum.WalkSpeed=30
  562. if comboing==false then
  563. wait(2)
  564. else
  565. wait(.5)
  566. end
  567. check=false
  568. elseif combo==true and #attacklist<3 then
  569. table.insert(attacklist,key)
  570. end
  571. end
  572. end
  573. end
  574. end
  575.  
  576. mouse.KeyUp:connect(function(key)
  577. if key=="q" and combo==true and check==false then
  578. combo=false
  579. comboing=true
  580. for _,v in pairs(attacklist) do
  581. PrepareAttack(v)
  582. end
  583. attacklist={}
  584. comboing=false
  585. check=true
  586. wait(5)
  587. check=false
  588. end
  589. end)
  590.  
  591. mouse.KeyDown:connect(PrepareAttack)
  592.  
  593. tool.Equipped:connect(function()
  594. equipped=true
  595. lgb=script.GB:Clone()
  596. lgb.Parent=char
  597. lgb.Main.Anchored=true
  598. rgb=script.GB:Clone()
  599. rgb.Parent=char
  600. rgb.Main.Anchored=true
  601. rgbbp=Instance.new("BodyPosition")
  602. rgbbp.MaxForce=Vector3.new(math.huge,math.huge,math.huge)
  603. rgbbp.D=200
  604. rgbbp.Position = char.Torso.Position
  605. rgbbp.P=300
  606. lgbbp=Instance.new("BodyPosition")
  607. lgbbp.MaxForce=Vector3.new(math.huge,math.huge,math.huge)
  608. lgbbp.D=200
  609. lgbbp.P=300
  610. lgbbp.Position = char.Torso.Position
  611. lgbbg=Instance.new("BodyGyro")
  612. lgbbg.MaxTorque=Vector3.new(10000,10000,10000)
  613. lgbbg.D=400
  614. rgbbg=Instance.new("BodyGyro")
  615. rgbbg.MaxTorque=Vector3.new(10000,10000,10000)
  616. rgbbg.D=400
  617. headf=script.HeadFlame:Clone()
  618. headf.Parent=char
  619. headf.Anchored=false
  620. local headfw=Instance.new("Weld",headf)
  621. headfw.Part0=char.Head
  622. headfw.Part1=headf
  623. headfw.C0=CFrame.new(-0.125,0.22,-0.55)*CFrame.Angles(0,0,math.pi/2)
  624. handf=script.HandFlame:Clone()
  625. handf.Parent=char
  626. handf.Anchored=false
  627. local handfw=Instance.new("Weld",handf)
  628. handfw.Part0=char["Right Arm"]
  629. handfw.Part1=handf
  630. handfw.C0=CFrame.new(0,-1.25,0)*CFrame.Angles(0,0,-math.pi/4)
  631. rgbbp.Position = char.Torso.Position
  632. lgbbp.Position = char.Torso.Position
  633. rgbbp.Parent = rgb.Main
  634. lgbbp.Parent = lgb.Main
  635. lgbbg.Parent = lgb.Main
  636. rgbbg.Parent = rgb.Main
  637. Loop()
  638. end)
  639. tool.Unequipped:connect(function()
  640. equipped=false
  641. lgb:Destroy()
  642. rgb:Destroy()
  643. headf:Destroy()
  644. handf:Destroy()
  645. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement