ManOhMan

Untitled

Jul 27th, 2019
43
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. -- This script has been converted to FE by iPxter
  2.  
  3.  
  4. if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
  5. local Player,Mouse,mouse,UserInputService,ContextActionService = owner
  6. do
  7. print("FE Compatibility code by Mokiros | Translated to FE by iPxter")
  8. script.Parent = Player.Character
  9.  
  10. --RemoteEvent for communicating
  11. local Event = Instance.new("RemoteEvent")
  12. Event.Name = "UserInput_Event"
  13.  
  14. --Fake event to make stuff like Mouse.KeyDown work
  15. local function fakeEvent()
  16. local t = {_fakeEvent=true,Connect=function(self,f)self.Function=f end}
  17. t.connect = t.Connect
  18. return t
  19. end
  20.  
  21. --Creating fake input objects with fake variables
  22. local m = {Target=nil,Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent()}
  23. local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()}
  24. local CAS = {Actions={},BindAction=function(self,name,fun,touch,...)
  25. CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil
  26. end}
  27. --Merged 2 functions into one by checking amount of arguments
  28. CAS.UnbindAction = CAS.BindAction
  29.  
  30. --This function will trigger the events that have been :Connect()'ed
  31. local function te(self,ev,...)
  32. local t = m[ev]
  33. if t and t._fakeEvent and t.Function then
  34. t.Function(...)
  35. end
  36. end
  37. m.TrigEvent = te
  38. UIS.TrigEvent = te
  39.  
  40. Event.OnServerEvent:Connect(function(plr,io)
  41. if plr~=Player then return end
  42. if io.isMouse then
  43. m.Target = io.Target
  44. m.Hit = io.Hit
  45. else
  46. local b = io.UserInputState == Enum.UserInputState.Begin
  47. if io.UserInputType == Enum.UserInputType.MouseButton1 then
  48. return m:TrigEvent(b and "Button1Down" or "Button1Up")
  49. end
  50. for _,t in pairs(CAS.Actions) do
  51. for _,k in pairs(t.Keys) do
  52. if k==io.KeyCode then
  53. t.Function(t.Name,io.UserInputState,io)
  54. end
  55. end
  56. end
  57. m:TrigEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower())
  58. UIS:TrigEvent(b and "InputBegan" or "InputEnded",io,false)
  59. end
  60. end)
  61. Event.Parent = NLS([==[
  62. local Player = game:GetService("Players").LocalPlayer
  63. local Event = script:WaitForChild("UserInput_Event")
  64.  
  65. local UIS = game:GetService("UserInputService")
  66. local input = function(io,a)
  67. if a then return end
  68. --Since InputObject is a client-side instance, we create and pass table instead
  69. Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState})
  70. end
  71. UIS.InputBegan:Connect(input)
  72. UIS.InputEnded:Connect(input)
  73.  
  74. local Mouse = Player:GetMouse()
  75. local h,t
  76. --Give the server mouse data 30 times every second, but only if the values changed
  77. --If player is not moving their mouse, client won't fire events
  78. while wait(1/30) do
  79. if h~=Mouse.Hit or t~=Mouse.Target then
  80. h,t=Mouse.Hit,Mouse.Target
  81. Event:FireServer({isMouse=true,Target=t,Hit=h})
  82. end
  83. end]==],Player.Character)
  84. Mouse,mouse,UserInputService,ContextActionService = m,m,UIS,CAS
  85. end
  86. --[[
  87. made by mr steal yo bork dont edit anything below plz just run script and you will see
  88. --]]
  89.  
  90.  
  91. p = owner
  92. t = Instance.new("Tool")
  93. t.Parent = p.Backpack
  94. t.Name = "Sign lololo"
  95. local handlelol = Instance.new("Part")
  96. handlelol.Name = "Handle"
  97. handlelol.Parent = t
  98. handlelol.formFactor = "Plate"
  99. handlelol.BrickColor = BrickColor.new("Brown")
  100. handlelol.Size = Vector3.new(1, 4.5, .5)
  101. handlelol.TopSurface = "Smooth"
  102. handlelol.BottomSurface = "Smooth"
  103. handlelol.Reflectance = 0
  104. handlelol.Material = "Wood"
  105. local sign = Instance.new("Part")
  106. sign.Name = "Part"
  107. sign.Parent = t
  108. sign.formFactor = "Plate"
  109. sign.BrickColor = BrickColor.new("Bright bluish green")
  110. sign.Size = Vector3.new(5, 4, 1)
  111. sign.TopSurface = "Smooth"
  112. sign.BottomSurface = "Smooth"
  113. sign.Reflectance = 0
  114.  
  115. mesh123 = Instance.new("BlockMesh")
  116. mesh123.Parent = sign
  117. mesh123.Scale = Vector3.new(1.1, 1.1, 0.8)
  118.  
  119. w2 = Instance.new("Weld")
  120. w2.Parent = handlelol
  121. w2.Part0 = sign
  122. w2.Part1 = handlelol
  123. w2.C0 = CFrame.fromEulerAnglesXYZ(0, 0, 0) + Vector3.new(0, -2.5, 0)
  124. -----------------------------------------------------------------------
  125. local SurfaceGui = Instance.new("SurfaceGui")
  126. local TextBox = Instance.new("TextBox")
  127. local ScreenGui = Instance.new("ScreenGui")
  128. local TextLabel = Instance.new("TextBox")
  129. ScreenGui.Parent = p.PlayerGui
  130. TextBox.Parent = ScreenGui
  131. TextBox.BackgroundColor3 = Color3.new(0.756863, 0.705882, 1)
  132. TextBox.Position = UDim2.new(0, 74, 0, 374)
  133. TextBox.Size = UDim2.new(0, 176, 0, 50)
  134. TextBox.Font = Enum.Font.Highway
  135. TextBox.FontSize = Enum.FontSize.Size28
  136. TextBox.Text = "Type text you want here"
  137. TextBox.TextSize = 10
  138. TextBox.TextWrapped = true
  139. TextBox.Visible = false
  140. SurfaceGui.Parent = sign
  141. SurfaceGui.Face = Enum.NormalId.Front
  142. TextLabel.Parent = SurfaceGui
  143. TextLabel.BackgroundColor3 = Color3.new(1, 1, 1)
  144. TextLabel.BackgroundTransparency = 1
  145. TextLabel.Size = UDim2.new(0, 800, 0, 600)
  146. TextLabel.Font = Enum.Font.SourceSans
  147. TextLabel.FontSize = Enum.FontSize.Size96
  148. TextLabel.Text = "same"
  149. TextLabel.TextColor3 = Color3.new(0.956863, 0.345098, 0.0588235)
  150. TextLabel.TextSize = 100
  151. TextLabel.TextWrapped = true
  152. t.Equipped:connect(function()
  153. TextBox.Visible = true
  154. end)
  155.  
  156. t.Unequipped:connect(function()
  157. TextBox.Visible = false
  158. end)
  159. wait(1)
  160. TextBox.Changed:connect(function()
  161. TextLabel.Text = TextBox.Text
  162. end)
Add Comment
Please, Sign In to add comment