Advertisement
Baldeagle22

hat test?

Sep 12th, 2018
344
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.83 KB | None | 0 0
  1. if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
  2. local Player,game,owner = owner,game
  3. local RealPlayer = Player
  4. do
  5. print("FE made by SoulCah | Dennis <3")
  6. local rp = RealPlayer
  7. script.Parent = rp.Character
  8.  
  9. --RemoteEvent for communicating
  10. local Event = Instance.new("RemoteEvent")
  11. Event.Name = "UserInput_Event"
  12.  
  13. --Fake event to make stuff like Mouse.KeyDown work
  14. local function fakeEvent()
  15. local t = {_fakeEvent=true,Functions={},Connect=function(self,f)table.insert(self.Functions,f) end}
  16. t.connect = t.Connect
  17. return t
  18. end
  19.  
  20. --Creating fake input objects with fake variables
  21. local m = {Target=nil,Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent()}
  22. local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()}
  23. local CAS = {Actions={},BindAction=function(self,name,fun,touch,...)
  24. CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil
  25. end}
  26. --Merged 2 functions into one by checking amount of arguments
  27. CAS.UnbindAction = CAS.BindAction
  28.  
  29. --This function will trigger the events that have been :Connect()'ed
  30. local function te(self,ev,...)
  31. local t = m[ev]
  32. if t and t._fakeEvent then
  33. for _,f in pairs(t.Functions) do
  34. f(...)
  35. end
  36. end
  37. end
  38. m.TrigEvent = te
  39. UIS.TrigEvent = te
  40.  
  41. Event.OnServerEvent:Connect(function(plr,io)
  42. if plr~=rp then return end
  43. m.Target = io.Target
  44. m.Hit = io.Hit
  45. if not io.isMouse then
  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.  
  62. function chatfunc(text)
  63. local chat = coroutine.wrap(function()
  64. if Character:FindFirstChild("TalkingBillBoard")~= nil then
  65. Character:FindFirstChild("TalkingBillBoard"):destroy()
  66. end
  67. local naeeym2 = Instance.new("BillboardGui",Character)
  68. naeeym2.Size = UDim2.new(0,100,0,40)
  69. naeeym2.StudsOffset = Vector3.new(0,3,0)
  70. naeeym2.Adornee = Character.Head
  71. naeeym2.Name = "TalkingBillBoard"
  72. local tecks2 = Instance.new("TextLabel",naeeym2)
  73. tecks2.BackgroundTransparency = 1
  74. tecks2.BorderSizePixel = 0
  75. tecks2.Text = ""
  76. tecks2.Font = "Cartoon"
  77. tecks2.TextSize = 30
  78. tecks2.TextStrokeTransparency = 0
  79. tecks2.TextColor3 = Color3.new(.6,0,0)
  80. tecks2.TextStrokeColor3 = Color3.new(0,0,0)
  81. tecks2.Size = UDim2.new(1,0,0.5,0)
  82. local tecks3 = Instance.new("TextLabel",naeeym2)
  83. tecks3.BackgroundTransparency = 1
  84. tecks3.BorderSizePixel = 0
  85. tecks3.Text = ""
  86. tecks3.Font = "Cartoon"
  87. tecks3.TextSize = 30
  88. tecks3.TextStrokeTransparency = 0
  89. tecks3.TextColor3 = BrickColor.new("Hot white").Color
  90. tecks3.TextStrokeColor3 = Color3.new(0,0,0)
  91. tecks3.Size = UDim2.new(1,0,0.5,0)
  92. spawn(function()
  93. while wait() do
  94. tecks3.TextColor3 = BrickColor.random().Color
  95. tecks2.TextColor3 = BrickColor.random().Color
  96. end
  97. end)
  98. for i = 1,string.len(text),1 do
  99. CFuncs["Sound"].Create("http://www.roblox.com/asset/?id=178104975", Character, 1, 1)
  100. tecks2.Text = string.sub(text,1,i)
  101. tecks3.Text = string.sub(text,1,i)
  102. wait(0.01)
  103. end
  104. wait(2)
  105. for i = 1, 50 do
  106. swait()
  107. tecks2.Position = tecks2.Position - UDim2.new(math.random(-1,1),math.random(-5,5),.05,math.random(-5,5))
  108. tecks2.Rotation = tecks2.Rotation - .8
  109. tecks2.TextStrokeTransparency = tecks2.TextStrokeTransparency +.04
  110. tecks2.TextTransparency = tecks2.TextTransparency + .04
  111. tecks3.Position = tecks2.Position - UDim2.new(math.random(-1,1),math.random(-5,5),.05,math.random(-5,5))
  112. tecks3.Rotation = tecks2.Rotation + .8
  113. tecks3.TextStrokeTransparency = tecks2.TextStrokeTransparency +.04
  114. tecks3.TextTransparency = tecks2.TextTransparency + .04
  115. end
  116. naeeym2:Destroy()
  117. end)
  118. chat()
  119. end
  120. function onChatted(msg)
  121. chatfunc(msg)
  122. end
  123. Player.Chatted:connect(onChatted)
  124.  
  125. abss = Instance.new("BillboardGui",Character)
  126. abss.Size = UDim2.new(10,0,10,0)
  127. abss.Enabled = false
  128. imgl = Instance.new("ImageLabel",abss)
  129. imgl.Position = UDim2.new(0,0,0,0)
  130. imgl.Size = UDim2.new(1,0,1,0)
  131. imgl.Image = "rbxassetid://183711814"
  132. imgl.BackgroundTransparency = 1
  133. imgl.ImageColor3 = Color3.new(.9,0,0)
  134. img2 = Instance.new("ImageLabel",abss)
  135. img2.Position = UDim2.new(0,0,0,0)
  136. img2.Size = UDim2.new(1,0,1,0)
  137. img2.Image = "rbxassetid://183711814"
  138. img2.BackgroundTransparency = 1
  139. img2.ImageColor3 = Color3.new(.9,0,0)
  140. spawn(function()
  141. while wait() do
  142. imgl.ImageColor3 = BrickColor.random().Color
  143. img2.ImageColor3 = BrickColor.random().Color
  144. end
  145. end)
  146.  
  147. spawn(function()
  148. chatfunc("It Has Begun")
  149. wait(3)
  150. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement