Josemmoya

Untitled

Feb 20th, 2019
80
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 14.71 KB | None | 0 0
  1. if game:GetService("RunService"):IsClient()then error("Please run as a server script. Use h/ instead of hl/.")end;print("FE Compatibility by WaverlyCole & Fireboltofdeath");print("https://github.com/WaverlyCole/FE-Compatibility-VoidSb-")
  2. local Wrapper = {};Wrapper.Fake = {};Wrapper.Real = {};Wrapper.Data = {};
  3. local sGame = game;local sScript = script;local sOwner = owner;local sInstance = Instance;local sLoadLibrary = LoadLibrary
  4. Wrapper.Event = Instance.new("RemoteEvent");Wrapper.Event.Name = "UserInput";
  5. Wrapper.CreateObject = function(connections, index)
  6. local proxy = newproxy (true);local meta = getmetatable (proxy);
  7. local runbind = function (self, i, ...) connections[i]:Fire (...); end;
  8. while (#connections > 0) do connections[table.remove(connections, 1)] = Instance.new ('BindableEvent');end;
  9. meta.__index = function (self, i)
  10. if (i == 'TriggerEvent') then return runbind end;
  11. return connections[i] and connections[i].Event or index[i];
  12. end;
  13. meta.__newindex = index;meta.__metatable = false;return proxy
  14. end;
  15. Wrapper.Mouse = Wrapper.CreateObject({"KeyUp","KeyDown","Button1Down","Button1Up","Move","Button2Down","Button2Up"},{["Target"] = nil;["Hit"] = CFrame.new()})
  16. Wrapper.UserInputService = Wrapper.CreateObject({"InputBegan","InputEnded"},{})
  17. Wrapper.ContextActionService = {Actions={};BindAction = function(self,actionName,Func,touch,...)self.Actions[actionName] = Func and {Name=actionName,Function=Func,Keys={...}} or nil end;UnBindAction = function(self,actionName,Func,touch,...)self.Actions[actionName] = Func and {Name=actionName,Function=Func,Keys={...}} or nil end};
  18. Wrapper.Sandbox = function(...)
  19. local Unwrap = {...};
  20. for obi = 1,#Unwrap do
  21. local Object = Unwrap[obi];
  22. if (Wrapper.Fake[Object] == nil and Wrapper.Real[Object] == nil) then
  23. local Type = typeof(Object);local Replacement = Object;
  24. if (Type == "function") then
  25. Replacement = function(...)
  26. local IsRoblox = not (pcall(function() string.dump(Object) end))
  27. if IsRoblox then
  28. return Object(Wrapper.Unsandbox(...))
  29. end
  30. return Object(Wrapper.Sandbox(...))
  31. end
  32. elseif (Type == "table") then
  33. Replacement = {};
  34. setmetatable(Replacement, {
  35. __index = function(self, i)
  36. return Wrapper.Sandbox(Object[Wrapper.Unsandbox(i)])
  37. end,
  38. __newindex = function(self,i,v)
  39. Object[Wrapper.Unsandbox(i)] = Wrapper.Unsandbox(v)
  40. end;
  41. })
  42. elseif (Type == "Instance") then
  43. Replacement = newproxy(true);
  44. local Mt = getmetatable(Replacement);
  45. Mt.__namecall = function(self, ...)
  46. local Pack = {...};local Name = Pack[#Pack];table.remove(Pack, #Pack);
  47. local Rest = nil;pcall(function()Rest = Object[Name];end);
  48. for g, x in pairs (Wrapper.InstanceMT["GET"]) do
  49. if (Object:IsA(g) or g == "Global") then
  50. for t, v in pairs(x) do
  51. for str in string.gmatch(t .. ",", "(%w+),") do
  52. if (Name == str) then
  53. if typeof(v) == "function" then
  54. return Wrapper.Sandbox(v(Wrapper.Unsandbox(self), Wrapper.Unsandbox(unpack(Pack))))
  55. else
  56. return v;
  57. end
  58. end
  59. end
  60. end
  61. end
  62. end
  63. if (Rest == nil) then
  64. if Wrapper.Sandbox(sGame):GetService(unpack(Pack)) then return Wrapper.Sandbox(sGame):GetService(unpack(Pack))end;
  65. return Wrapper.Sandbox(Object[Name]);
  66. elseif (typeof(Rest) == "function") then
  67. return Wrapper.Sandbox(Rest(Wrapper.Unsandbox(self), Wrapper.Unsandbox(unpack(Pack))))
  68. end
  69. return Wrapper.Sandbox(Object[Name]);
  70. end
  71. Mt.__index = function(self, i)
  72. local Rest = nil;pcall(function()Rest = Object[i];end)
  73. for g, x in pairs (Wrapper.InstanceMT["GET"]) do
  74. if (Object:IsA(g) or g == "Global") then
  75. for t, v in pairs(x) do
  76. for str in string.gmatch(t .. ",", "(%w+),") do
  77. if (i == str) then
  78. if typeof(v) == "function" then
  79. return function(...)return Wrapper.Sandbox(v(Wrapper.Unsandbox(self), Wrapper.Unsandbox(...)))end;
  80. else
  81. return v;
  82. end
  83. end
  84. end
  85. end
  86. end
  87. end
  88. if (Object:IsA("Sound") and i == "PlaybackLoudness") then return Wrapper.SoundLoudness[Wrapper.Unsandbox(Object)];end;
  89. if (Rest == nil) then
  90. if Wrapper.Sandbox(sGame):GetService(i) then return Wrapper.Sandbox(sGame):GetService(i)end;
  91. return Wrapper.Sandbox(Object[i]);
  92. elseif (typeof(Rest) == "function") then
  93. local isService,Service = pcall(function() return sGame:GetService(i) end)
  94. if isService and Service then return Wrapper.Sandbox(Service) end
  95. return function(self, ...)
  96. return Wrapper.Sandbox(Rest(Wrapper.Unsandbox(self), Wrapper.Unsandbox(...)))
  97. end
  98. end
  99. return Wrapper.Sandbox(Object[i]);
  100. end
  101. Mt.__newindex = function(self, i, v)
  102. for g,x in pairs (Wrapper.InstanceMT["SET"]) do
  103. if (Object:IsA(g)) then
  104. for t, v in pairs(x) do
  105. for str in string.gmatch( t .. ",", "(%w+),") do
  106. if v(Wrapper.Unsandbox(self, i, v)) == true then
  107. Object[Wrapper.Unsandbox(i)] = Wrapper.Unsandbox(v);return
  108. end
  109. end
  110. end
  111. end
  112. end
  113. Object[Wrapper.Unsandbox(i)] = Wrapper.Unsandbox(v);
  114. end
  115. Mt.__tostring = function(self) return tostring(Object) end
  116. --elseif (Type == "") then -- Etc
  117. end
  118. Wrapper.Fake[Object] = Replacement;Wrapper.Real[Replacement] = Object;Unwrap[obi] = Replacement;
  119. else
  120. return Wrapper.Fake[Object] or Object;
  121. end
  122. end
  123. return unpack(Unwrap);
  124. end
  125. Wrapper.Unsandbox = function(...)
  126. local Unsandbox = {...};
  127. for i,v in pairs (Unsandbox) do Unsandbox[i] = Wrapper.Real[v] or Unsandbox[i]end;
  128. return unpack(Unsandbox)
  129. end
  130. Wrapper.Services = {
  131. ['contextactionservice'] = Wrapper.ContextActionService;
  132. ["userinputservice"] = Wrapper.UserInputService;
  133. }
  134. Wrapper.InstanceMT = {
  135. ["GET"] = {
  136. ["Global"] = {
  137. ["IsFake,isFake"] = function(self)return true;end;
  138. };
  139. ["Player"] = {
  140. ["mouse,Mouse,getMouse,GetMouse"] = function(self)return Wrapper.Mouse;end;
  141. };
  142. ["Players"] = {
  143. ["localPlayer,LocalPlayer"] = Wrapper.Sandbox(owner)
  144. };
  145. ["DataModel"] = {
  146. ["getService,GetService"] = function(self,service)
  147. if Wrapper.Services[service:lower()] then return Wrapper.Sandbox(Wrapper.Services[service:lower()])end;
  148. return Wrapper.Sandbox(sGame:GetService(service))
  149. end
  150. };
  151. ["RunService"] = {
  152. ["renderstepped,renderStepped,RenderStepped"] = sGame:GetService("RunService").Stepped;
  153. }
  154. };
  155. ["SET"] = {
  156. }
  157. }
  158. Wrapper.SoundLoudness = {};
  159. Wrapper.Event.OnServerEvent:Connect(function(FiredBy,Input)
  160. if FiredBy ~= sOwner then return end
  161. if Input.MouseEvent then
  162. Wrapper.Mouse.Target = Input.Target;Wrapper.Mouse.Hit = Input.Hit;Wrapper.Mouse:TriggerEvent("Move")
  163. elseif Input.Sound then
  164. if Wrapper.SoundLoudness[Input.Sound] then Wrapper.SoundLoudness[Input.Sound] = Input.Loudness end
  165. else
  166. local Begin = Input.UserInputState == Enum.UserInputState.Begin
  167. if Input.UserInputType == Enum.UserInputType.MouseButton1 then return Wrapper.Mouse:TriggerEvent(Begin and "Button1Down" or "Button1Up") end
  168. if Input.UserInputType == Enum.UserInputType.MouseButton2 then return Wrapper.Mouse:TriggerEvent(Begin and "Button2Down" or "Button2Up") end
  169. for _,Action in pairs(Wrapper.ContextActionService.Actions) do
  170. for _,Key in pairs(Action.Keys) do if Key==Input.KeyCode then Action.Function(Action.Name,Input.UserInputState,Input) end end
  171. end
  172. Wrapper.Mouse:TriggerEvent(Begin and "KeyDown" or "KeyUp",Input.KeyCode.Name:lower());Wrapper.UserInputService:TriggerEvent(Begin and "InputBegan" or "InputEnded",Input,false)
  173. end
  174. end);
  175. Wrapper.Event.Parent = NLS([[
  176. local Player = owner;local Sounds = {};local Event = script:WaitForChild("UserInput");local UserInputService = game:GetService("UserInputService");local Mouse = Player:GetMouse();
  177. local Input = function(Input,gameProcessedEvent)
  178. if gameProcessedEvent then return end;
  179. Event:FireServer({KeyCode=Input.KeyCode,UserInputType=Input.UserInputType,UserInputState=Input.UserInputState})
  180. end
  181. Event.OnClientEvent:connect(function(Args)
  182. if Args[1] == "NewSound" and Args[2]:IsA("Sound") then table.insert(Sounds,Args[2]) end
  183. end)
  184. UserInputService.InputBegan:Connect(Input);UserInputService.InputEnded:Connect(Input)
  185. local Hit,Target;while wait(1/30) do
  186. for x,Sound in pairs(Sounds) do if Sound.Parent then Event:FireServer({["Sound"]=Sound,["Loudness"]=Sound.PlaybackLoudness}) end; end;
  187. if Hit ~= Mouse.Hit or Target ~= Mouse.Target then
  188. Hit = Mouse.Hit;Target = Mouse.Target;Event:FireServer({["MouseEvent"]=true,["Target"]=Target,["Hit"]=Hit})
  189. end
  190. end]],sOwner.Character)
  191. Instance = {
  192. ["new"] = function(Type,Parent)
  193. local Real = sInstance.new(Type,Wrapper.Unsandbox(Parent))
  194. if Type:lower() == "sound" then
  195. if not Parent then
  196. Parent = sOwner.Character
  197. end
  198. Wrapper.SoundLoudness[Real] = 0;Wrapper.Event:FireClient(sOwner,{"NewSound",Real})
  199. end
  200. return Wrapper.Sandbox(Real)
  201. end
  202. }
  203. LoadLibrary = function(Library)
  204. if Library == "RbxUtility" then
  205. return setmetatable({},{
  206. __tostring = function() return "RbxUtility" end;
  207. __index = function(self, Index)
  208. if Index:lower() == "create" then
  209. return function(Type) return function(Data)
  210. Data = Data or {};local Inst = Instance.new(Type)
  211. for x,y in pairs(Data) do Inst[x] = y end
  212. return Inst
  213. end;end;
  214. end
  215. return sLoadLibrary(Library)[Index]
  216. end})
  217. end
  218. return sLoadLibrary(Library)
  219. end
  220. owner = Wrapper.Sandbox(owner);game = Wrapper.Sandbox(game)workspace = Wrapper.Sandbox(workspace)
  221. Game= game;Workspace = workspace;
  222.  
  223. --//Paste script below this line.
  224. wait(1)
  225.  
  226. -- Get LocalPlayer
  227. local p = game.Players.LocalPlayer
  228.  
  229. -- Instance New Objects
  230. local gui = Instance.new('ScreenGui',p.PlayerGui)
  231. local frame = Instance.new('Frame',gui)
  232. local open = Instance.new('TextButton',gui)
  233. local bool = Instance.new('BoolValue',frame)
  234. local button = Instance.new('TextButton',frame)
  235. local name = Instance.new('TextLabel',frame)
  236. local box = Instance.new('TextBox',frame)
  237. local msg = Instance.new('StringValue',box)
  238. local exit = Instance.new('TextButton',frame)
  239. local spamon = Instance.new('TextButton',frame)
  240. local spamoff = Instance.new('TextButton',frame)
  241. local search = Instance.new('TextBox',frame)
  242. local people = Instance.new('StringValue',frame)
  243.  
  244. -- Objects Name
  245. gui.Name = "SpamGUI"
  246. frame.Name = "SpawnFrame"
  247. open.Name = "OpenButton"
  248. bool.Name = "Bool"
  249. button.Name = "Open/Close"
  250. name.Name = "Title"
  251. box.Name = "TextBox"
  252. msg.Name = "Msg"
  253. exit.Name = "ExitButton"
  254. spamon.Name = "SpamON"
  255. spamoff.Name = "SpamOFF"
  256. search.Name = "SearchPeople"
  257. people.Name = "Result"
  258.  
  259. -- Objects Position
  260. frame.Position = UDim2.new(0.7,7,0,3)
  261. open.Position = UDim2.new(0,-100,0.7,0)
  262. button.Position = UDim2.new(0,170,0.7,13)
  263. name.Position = UDim2.new(0,0,0,0)
  264. box.Position = UDim2.new(0,0,0,45)
  265. exit.Position = UDim2.new(0.8,30,0,0)
  266. spamon.Position = UDim2.new(0,5,0.7,13)
  267. spamoff.Position = UDim2.new(0,245,0.7,13)
  268. search.Position = UDim2.new(0,0,0,200)
  269.  
  270. -- Object Size
  271. frame.Size = UDim2.new(0,400,0,200)
  272. open.Size = UDim2.new(0,100,0,40)
  273. button.Size = UDim2.new(0,60,0,40)
  274. name.Size = UDim2.new(0.8,25,0,40)
  275. box.Size = UDim2.new(1,0,0,100)
  276. exit.Size = UDim2.new(0,50,0,43)
  277. spamon.Size = UDim2.new(0,150,0,40)
  278. spamoff.Size = UDim2.new(0,150,0,40)
  279. search.Size = UDim2.new(0,400,0,50)
  280.  
  281. -- Dragggable Frame
  282. frame.Active = true
  283. frame.Draggable = true
  284.  
  285. -- Objects Background Color
  286. frame.BackgroundColor3 = Color3.new(0,0,0)
  287. open.BackgroundColor3 = Color3.new(255, 255, 0)
  288. button.BackgroundColor3 = Color3.new(255, 255, 255)
  289. name.BackgroundColor3 = Color3.new(255, 255, 255)
  290. box.BackgroundColor3 = Color3.new(255, 255, 255)
  291. exit.BackgroundColor3 = Color3.new(255, 0, 0)
  292. spamon.BackgroundColor3 = Color3.new(255, 0, 0)
  293. spamoff.BackgroundColor3 = Color3.new(255, 0, 0)
  294. search.BackgroundColor3 = Color3.new(255,255,255)
  295.  
  296. -- Object Background Transparency
  297. frame.BackgroundTransparency = 0.5
  298. box.BackgroundTransparency = 0.5
  299. button.BackgroundTransparency = 0.6
  300. name.BackgroundTransparency = 1
  301. search.BackgroundTransparency = 0.6
  302.  
  303. -- Visible
  304. open.Visible = false
  305. search.Visible = false
  306.  
  307. -- Text Size/Scaled enabled
  308. open.TextScaled = true
  309. exit.TextScaled = true
  310. spamon.TextScaled = true
  311. spamoff.TextScaled = true
  312. box.TextScaled = true
  313. button.TextScaled = true
  314. name.TextScaled = true
  315. search.TextScaled = true
  316.  
  317. -- Box Line
  318. box.ClearTextOnFocus = true
  319. box.MultiLine = true
  320.  
  321. -- Text Color
  322. name.TextColor3 = Color3.new(255,0,0)
  323.  
  324. -- Text
  325. open.Text = "Open"
  326. exit.Text = "Exit"
  327. spamoff.Text = "Turn Off"
  328. spamon.Text = "Turn On"
  329. box.Text = "Message Here ....."
  330. button.Text = "Close"
  331. name.Text = "Unique's Spam GUI"
  332. search.Text = "Search people"
  333.  
  334. -- Value
  335. bool.Value = false
  336. msg.Value = ""
  337. people.Value = ""
  338.  
  339. -- Spam On
  340. spamon.MouseButton1Down:connect(function()
  341. bool.Value = true
  342. msg.Value = box.Text
  343. box.Text = "Success !"
  344. search.Text = ""
  345. wait(1)
  346. box.Text = "Message Here ....."
  347. end)
  348.  
  349. -- Spam Off
  350. spamoff.MouseButton1Down:connect(function()
  351. bool.Value = false
  352. end)
  353.  
  354. -- Exit Function
  355. exit.MouseButton1Down:connect(function()
  356. frame:TweenPosition(UDim2.new(1,0,0,3),"Out","Quad",1,true)
  357. wait(1)
  358. frame.Visible = false
  359. wait(.5)
  360. open.Visible = true
  361. open:TweenPosition(UDim2.new(0,5,0.7,0),"Out","Bounce",1,true)
  362. end)
  363.  
  364. -- Open Function
  365. open.MouseButton1Down:connect(function()
  366. open:TweenPosition(UDim2.new(0,-100,0.7,0),"Out","Quad",1,true)
  367. wait(1)
  368. open.Visible = false
  369. wait(.5)
  370. frame.Visible = true
  371. frame:TweenPosition(UDim2.new(0.7,7,0,3),"Out","Bounce",1,true)
  372. end)
  373.  
  374. -- Search People Box
  375. button.MouseButton1Down:connect(function()
  376. if search.Visible == false then
  377. button.Text = "Open"
  378. search.Visible = true
  379. else
  380. button.Text = "Close"
  381. search.Visible = false
  382. end
  383. end)
  384.  
  385. -- Spam Function
  386. while true do
  387. wait(.1)
  388. if bool.Value == true then
  389. local ppl = game.Players:FindFirstChild(people.Value)
  390. if ppl then
  391. game:GetService('Chat'):Chat(ppl.Character, msg.Value)
  392. elseif not ppl then
  393. for i,v in pairs(game.Players:GetChildren()) do
  394. game:GetService('Chat'):Chat(v.Character, msg.Value)
  395. end
  396. end
  397. end
  398. end
Add Comment
Please, Sign In to add comment