Advertisement
sawgamer1

Untitled

May 20th, 2019
155
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 7.59 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. --Converted with ttyyuu12345's model to script plugin v4
  8. function sandbox(var,func)
  9. local env = getfenv(func)
  10. local newenv = setmetatable({},{
  11. __index = function(self,k)
  12. if k=="script" then
  13. return var
  14. else
  15. return env[k]
  16. end
  17. end,
  18. })
  19. setfenv(func,newenv)
  20. return func
  21. end
  22. cors = {}
  23. mas = Instance.new("Model",game:GetService("Lighting"))
  24. Tool0 = Instance.new("Tool")
  25. Part1 = Instance.new("Part")
  26. Part2 = Instance.new("Part")
  27. PointLight3 = Instance.new("PointLight")
  28. Sparkles4 = Instance.new("Sparkles")
  29. WeldConstraint5 = Instance.new("WeldConstraint")
  30. Script6 = Instance.new("Script")
  31. LocalScript7 = Instance.new("LocalScript")
  32. Part8 = Instance.new("Part")
  33. Script9 = Instance.new("Script")
  34. Script10 = Instance.new("Script")
  35. Tool0.Name = "SMITE WAND"
  36. Tool0.Parent = mas
  37. Tool0.Grip = CFrame.new(0, -1.5, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  38. Tool0.GripPos = Vector3.new(0, -1.5, 0)
  39. Part1.Name = "Handle"
  40. Part1.Parent = Tool0
  41. Part1.CFrame = CFrame.new(-10.3500004, -6.04999876, 16.1999989, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  42. Part1.Position = Vector3.new(-10.3500004, -6.04999876, 16.1999989)
  43. Part1.Color = Color3.new(0.501961, 0.733333, 0.858824)
  44. Part1.Size = Vector3.new(0.300000012, 2.89999938, 0.299999923)
  45. Part1.BottomSurface = Enum.SurfaceType.Smooth
  46. Part1.BrickColor = BrickColor.new("Pastel Blue")
  47. Part1.Material = Enum.Material.DiamondPlate
  48. Part1.TopSurface = Enum.SurfaceType.Smooth
  49. Part1.brickColor = BrickColor.new("Pastel Blue")
  50. Part2.Parent = Tool0
  51. Part2.CFrame = CFrame.new(-10.3500004, -4.45000029, 16.2000008, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  52. Part2.Position = Vector3.new(-10.3500004, -4.45000029, 16.2000008)
  53. Part2.Color = Color3.new(0.972549, 0.972549, 0.972549)
  54. Part2.Size = Vector3.new(0.300000012, 0.299999833, 0.300000012)
  55. Part2.BottomSurface = Enum.SurfaceType.Smooth
  56. Part2.BrickColor = BrickColor.new("Institutional white")
  57. Part2.Material = Enum.Material.Neon
  58. Part2.TopSurface = Enum.SurfaceType.Smooth
  59. Part2.brickColor = BrickColor.new("Institutional white")
  60. PointLight3.Parent = Part2
  61. Sparkles4.Parent = Part2
  62. Sparkles4.Color = Color3.new(1.77083, 10.2, 1)
  63. Sparkles4.SparkleColor = Color3.new(1, 1, 1)
  64. WeldConstraint5.Parent = Tool0
  65. WeldConstraint5.Part0 = Part2
  66. WeldConstraint5.Part1 = Part1
  67. Script6.Parent = Tool0
  68. table.insert(cors,sandbox(Script6,function()
  69. local tool = script.Parent
  70. local sound = workspace["Lightning Strike"]
  71.  
  72. local remoteEvent = Instance.new("RemoteEvent", tool)
  73. remoteEvent.Name = "MouseLocation"
  74.  
  75. local money = game.ServerStorage.Lightning
  76.  
  77. local function spawnMoney(player, mousePos)
  78. local boomboom = Instance.new("Explosion")
  79. sound:Play()
  80. sound.TimePosition = 0.5
  81. local cash = money:clone()
  82. boomboom.Parent = workspace
  83. boomboom.Position = mousePos.Position
  84. cash.Parent = workspace
  85. cash.Position = mousePos.Position
  86. end
  87.  
  88. remoteEvent.OnServerEvent:Connect(spawnMoney)
  89. end))
  90. LocalScript7.Parent = Tool0
  91. table.insert(cors,sandbox(LocalScript7,function()
  92. local tool = script.Parent
  93. local remoteEvent = tool:WaitForChild("MouseLocation")
  94. local mouse = game.Players.LocalPlayer:GetMouse()
  95.  
  96. local function remoteSend()
  97. remoteEvent:FireServer(mouse.Hit)
  98. end
  99.  
  100. tool.Activated:Connect(remoteSend)
  101. end))
  102. Part8.Name = "Lightning"
  103. Part8.Parent = Tool0
  104. Part8.CFrame = CFrame.new(-18.5, 174.5, -26.5, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  105. Part8.Position = Vector3.new(-18.5, 174.5, -26.5)
  106. Part8.Color = Color3.new(0.972549, 0.972549, 0.972549)
  107. Part8.Transparency = 0.69999998807907
  108. Part8.Size = Vector3.new(3, 364, 3)
  109. Part8.Anchored = true
  110. Part8.BottomSurface = Enum.SurfaceType.Smooth
  111. Part8.BrickColor = BrickColor.new("Institutional white")
  112. Part8.CanCollide = false
  113. Part8.Material = Enum.Material.Neon
  114. Part8.TopSurface = Enum.SurfaceType.Smooth
  115. Part8.brickColor = BrickColor.new("Institutional white")
  116. Script9.Parent = Part8
  117. table.insert(cors,sandbox(Script9,function()
  118. local model = script.Parent
  119.  
  120. local function ontouch(otherPart)
  121. local char = otherPart.Parent
  122. local human = char:FindFirstChild("Humanoid")
  123. if human and human.Health > 0 then
  124. human.Health = 0
  125. end
  126. end
  127.  
  128. model.Touched:Connect(ontouch)
  129. end))
  130. Script10.Name = "Despawn"
  131. Script10.Parent = Part8
  132. table.insert(cors,sandbox(Script10,function()
  133. local money = script.Parent
  134.  
  135. wait(0.2)
  136. money:Destroy()
  137.  
  138. end))
  139. for i,v in pairs(mas:GetChildren()) do
  140. v.Parent = game:GetService("Players").LocalPlayer.Backpack
  141. pcall(function() v:MakeJoints() end)
  142. end
  143. mas:Destroy()
  144. for i,v in pairs(cors) do
  145. spawn(function()
  146. pcall(v)
  147. end)
  148. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement