Alessandro Posted September 16, 2010 Share Posted September 16, 2010 Hello, I often need to print some info on the screen in order to speed-up development and debugging phases, but I noticed that AddText has no effect. Is there any way to print text in the editor (even for CTRL-G only)? Thank you! Quote Link to comment Share on other sites More sharing options...
Rick Posted September 16, 2010 Share Posted September 16, 2010 There is a drawing hook that you can assign a Lua method to and inside there you can draw 2D stuff like text. AddHook("Flip", MyFunction) "Flip" is a keyword and for drawing you need that, then the function can be any Lua function. function MyFunction() -- Draw images or text here end Quote Link to comment Share on other sites More sharing options...
Alessandro Posted September 16, 2010 Author Share Posted September 16, 2010 There is a drawing hook that you can assign a Lua method to and inside there you can draw 2D stuff like text. AddHook("Flip", MyFunction) "Flip" is a keyword and for drawing you need that, then the function can be any Lua function. function MyFunction() -- Draw images or text here end Thank you Rick! I will test it tonight (I'm at work now :-) Quote Link to comment Share on other sites More sharing options...
AggrorJorn Posted September 16, 2010 Share Posted September 16, 2010 RemoveHook("Flip", MyFunction) when you don't want to show it any more. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.