SHOW:
|
|
- or go back to the newest paste.
1 | - | plr = game.Players.LocalPlayer |
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,Mouse,mouse,UserInputService,ContextActionService = owner | |
4 | local RealPlayer = Player | |
5 | do print("FE Compatibility code by Mokiros")local a=RealPlayer;script.Parent=a.Character;local b=Instance.new("RemoteEvent")b.Name="UserInput_Event"local function c()local d={_fakeEvent=true,Functions={},Connect=function(self,e)table.insert(self.Functions,e)end}d.connect=d.Connect;return d end;local f={Target=nil,Hit=CFrame.new(),KeyUp=c(),KeyDown=c(),Button1Up=c(),Button1Down=c(),Button2Up=c(),Button2Down=c()}local g={InputBegan=c(),InputEnded=c()}local CAS={Actions={},BindAction=function(self,h,i,j,...)CAS.Actions[h]=i and{Name=h,Function=i,Keys={...}}or nil end}CAS.UnbindAction=CAS.BindAction;local function k(self,l,...)local d=f[l]if d and d._fakeEvent then for m,e in pairs(d.Functions)do e(...)end end end;f.TrigEvent=k;g.TrigEvent=k;b.OnServerEvent:Connect(function(n,o)if n~=a then return end;f.Target=o.Target;f.Hit=o.Hit;if not o.isMouse then local p=o.UserInputState==Enum.UserInputState.Begin;if o.UserInputType==Enum.UserInputType.MouseButton1 then return f:TrigEvent(p and"Button1Down"or"Button1Up")end;if o.UserInputType==Enum.UserInputType.MouseButton2 then return f:TrigEvent(p and"Button2Down"or"Button2Up")end;for m,d in pairs(CAS.Actions)do for m,q in pairs(d.Keys)do if q==o.KeyCode then d.Function(d.Name,o.UserInputState,o)end end end;f:TrigEvent(p and"KeyDown"or"KeyUp",o.KeyCode.Name:lower())g:TrigEvent(p and"InputBegan"or"InputEnded",o,false)end end)b.Parent=NLS([==[local a=game:GetService("Players").LocalPlayer;local b=script:WaitForChild("UserInput_Event")local c=a:GetMouse()local d=game:GetService("UserInputService")local e=function(f,g)if g then return end;b:FireServer({KeyCode=f.KeyCode,UserInputType=f.UserInputType,UserInputState=f.UserInputState,Hit=c.Hit,Target=c.Target})end;d.InputBegan:Connect(e)d.InputEnded:Connect(e)local h,i;while wait(1/30)do if h~=c.Hit or i~=c.Target then h,i=c.Hit,c.Target;b:FireServer({isMouse=true,Target=i,Hit=h})end end]==],Player.Character)local r=game;local s={__index=function(self,q)local t=rawget(self,"_RealService")if t then return typeof(t[q])=="function"and function(m,...)return t[q](t,...)end or t[q]end end,__newindex=function(self,q,u)local t=rawget(self,"_RealService")if t then t[q]=u end end}local function v(d,w)d._RealService=typeof(w)=="string"and r:GetService(w)or w;return setmetatable(d,s)end;local x={GetService=function(self,t)return rawget(self,t)or r:GetService(t)end,Players=v({LocalPlayer=v({GetMouse=function(self)return f end},Player)},"Players"),UserInputService=v(g,"UserInputService"),ContextActionService=v(CAS,"ContextActionService"),RunService=v({_btrs={},RenderStepped=r:GetService("RunService").Heartbeat,BindToRenderStep=function(self,h,m,i)self._btrs[h]=self.Heartbeat:Connect(i)end,UnbindFromRenderStep=function(self,h)self._btrs[h]:Disconnect()end},"RunService")}rawset(x.Players,"localPlayer",x.Players.LocalPlayer)x.service=x.GetService;v(x,game)game,owner=x,x.Players.LocalPlayer end plr = game.Players.LocalPlayer | |
6 | char = plr.Character | |
7 | msg = Instance.new("Message",workspace) | |
8 | msg.Text = "" | |
9 | gui = Instance.new("ScreenGui",plr.PlayerGui) | |
10 | textbox = Instance.new("TextBox",gui) | |
11 | textbox.Position = UDim2.new(0.23,0,0.269,0) | |
12 | textbox.Text = "" | |
13 | textbox.Size = UDim2.new(0,200,0,50) | |
14 | textbox.Visible = true | |
15 | textbox.Active = true | |
16 | textbox.Changed:connect(function(property) | |
17 | if property == "Text" then | |
18 | if textbox.Text == "WHERE IS MY HOUSE" then | |
19 | wait(2) | |
20 | part = Instance.new("Part",workspace) | |
21 | part.Anchored = true | |
22 | wait(0.1) | |
23 | part.CFrame = CFrame.new(0,5,0) | |
24 | wait(0.1) | |
25 | part.Size = Vector3.new(10,10,10) | |
26 | wait(0.1) | |
27 | part.BrickColor = BrickColor.Green() | |
28 | wait(0.1) | |
29 | part2 = part:Clone() | |
30 | part2.Parent = workspace | |
31 | wait(0.1) | |
32 | part2.Size = Vector3.new(10,3,10) | |
33 | wait(0.1) | |
34 | part2.CFrame = part.CFrame + Vector3.new(0,6,0) | |
35 | wait(0.1) | |
36 | part2.BrickColor = BrickColor.Gray() | |
37 | end | |
38 | if textbox.Text == "WHERE IS THE SCHOOL" then | |
39 | wait(2) | |
40 | part = Instance.new("Part",workspace) | |
41 | part.Anchored = true | |
42 | wait(0.1) | |
43 | part.CFrame = CFrame.new(0,15,0) | |
44 | wait(0.1) | |
45 | part.Size = Vector3.new(100,25,100) | |
46 | wait(0.1) | |
47 | part.BrickColor = BrickColor.Red() | |
48 | wait(0.1) | |
49 | end | |
50 | if textbox.Text == "DESTROY GAME" then | |
51 | wait(2) | |
52 | game.Lighting.Ambient = BrickColor.Random().Color | |
53 | wait(0.25) | |
54 | game.Lighting.Ambient = BrickColor.Random().Color | |
55 | wait(0.25) | |
56 | game.Lighting.Ambient = BrickColor.Random().Color | |
57 | wait(0.25) | |
58 | game.Lighting.Ambient = BrickColor.Random().Color | |
59 | wait(0.25) | |
60 | game.Lighting.Ambient = BrickColor.Random().Color | |
61 | wait(0.25) | |
62 | game.Lighting.Ambient = BrickColor.Random().Color | |
63 | wait(0.25) | |
64 | game.Lighting.FogEnd = math.random(10,25) | |
65 | wait(0.1) | |
66 | game.Lighting.FogEnd = math.random(10,25) | |
67 | wait(0.1) | |
68 | game.Lighting.FogEnd = math.random(10,25) | |
69 | wait(0.1) | |
70 | game.Lighting.FogEnd = math.random(10,25) | |
71 | wait(0.1) | |
72 | game.Lighting.FogEnd = math.random(10,25) | |
73 | wait(0.1) | |
74 | game.Lighting.FogEnd = math.random(10,25) | |
75 | wait(0.1) | |
76 | game.Lighting.FogEnd = math.random(10,25) | |
77 | wait(0.1) | |
78 | game.Lighting.FogEnd = math.random(10,25) | |
79 | wait(0.1) | |
80 | game.Lighting.FogEnd = math.random(10,25) | |
81 | wait(0.1) | |
82 | game.Lighting.FogColor = game.Lighting.Ambient | |
83 | workspace.Camera.FieldOfView = math.random(10,20) | |
84 | while true do | |
85 | wait(0.01) | |
86 | part = Instance.new("Part",workspace) | |
87 | gp = game.Players:GetPlayers() | |
88 | for i=1, #gp do | |
89 | tool = Instance.new("Tool",gp[i].Backpack) | |
90 | tool.Name = "Destroy_Game_"..tostring(math.random(10,25)) | |
91 | game.Debris:AddItem(tool,1) | |
92 | game.StarterGui:SetCore("ChatMakeSystemMessage",{ | |
93 | Text = "Destroy_Game_"..tostring(math.random(10,25)); | |
94 | Color = Color3.new(1,1,1); | |
95 | Font = Enum.Font.Arcade; | |
96 | FontSize = Enum.FontSize.Size96; | |
97 | }) | |
98 | for i=1, #gp do | |
99 | ff = Instance.new("ForceField",gp[i].Character) | |
100 | if gp[i].Character:FindFirstChild("Head") then | |
101 | fire = Instance.new("ForceField",gp[i].Character.Head) | |
102 | end | |
103 | tool = Instance.new("Tool",gp[i].Backpack) | |
104 | tool.Name = "Destroy_Game_"..tostring(math.random(10,25)) | |
105 | game.Debris:AddItem(tool,1) | |
106 | for i=1, #gp do | |
107 | ff = Instance.new("ForceField",gp[i].Character) | |
108 | if gp[i].Character:FindFirstChild("Head") then | |
109 | fire = Instance.new("ForceField",gp[i].Character.Head) | |
110 | end | |
111 | tool = Instance.new("Tool",gp[i].Backpack) | |
112 | tool.Name = "Destroy_Game_"..tostring(math.random(10,25)) | |
113 | game.Debris:AddItem(tool,1) | |
114 | for i=1, #gp do | |
115 | ff = Instance.new("ForceField",gp[i].Character) | |
116 | if gp[i].Character:FindFirstChild("Head") then | |
117 | fire = Instance.new("ForceField",gp[i].Character.Head) | |
118 | end | |
119 | tool = Instance.new("Tool",gp[i].Backpack) | |
120 | tool.Name = "Destroy_Game_"..tostring(math.random(10,25)) | |
121 | game.Debris:AddItem(tool,1) | |
122 | end | |
123 | end | |
124 | end | |
125 | end | |
126 | end | |
127 | end | |
128 | end | |
129 | end) | |
130 | while true do | |
131 | wait(0.01) | |
132 | msg.Text = textbox.Text | |
133 | end |