Question

I'm trying to parse chat messages for keywords that I will use to trigger various functions. In order to use the chat I have to test in game mode, which is started by first clicking Tools-> Test-> Start Server and then clicking Tools-> Test-> Start Player. The command window is not available in game mode so I need a way to get some debugging feedback. I figured a popup message would be good for that purpose.

I suspect its fairly simple to display a popup message but I cant find any information on it.

Was it helpful?

Solution

Did you enable the Output window?

View -> Output menu

Then e.g. if you script does

print("Hello world!")

You should see that in the output window. Else take a look at

How to add messages

OTHER TIPS

Enable the output, Press Test >> Start Server In that new window press Test >> Start Player In the server window (Not the new player window), open the command bar and type:

game.Players.Player.SuperSafeChat = false

And press enter. You can test it, and get output.

to see the output, go into the server window, and make sure the output window is shown.

While the following answers are of course correct, you CAN create a popup to display output from the...output. This can be done by overriding the default "print" function:

_G["dprint"] = _G.print
_G["print"] = function(...)
   pargs = {...}
   lMessage = Instance.new("Message")
   lMessage.Parent = workspace
   lMessage.Text = table.concat(pargs, " ") -- Is it concat?
   wait(10)
   lMessage:remove()

end

native.showAlert(parameters list)

This can be best way to implement.

There are some ways you can achieve this.

  1. Roblox recently added a developer console that you can also use in game, so basically you can see the output window even online.
  2. You can use Messages or Hints
  3. You can make your own GUI
  4. If you don't need it online, you can use the output window.

ROBLOX has actually added a developer console (see it at the wiki: wiki.roblox.com/index.php?title=Developer_console) to the game client AND added its availability to studio 2015. You can access using the f9 button (or alt+f9 on laptops). You could've also opened the output window (see it at the wiki: wiki.roblox.com/index.php?title=Output) and see the errors there. Hope this helped!

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top