JohnDude Newbie cheater Reputation: 0
Joined: 30 Aug 2013 Posts: 20
|
Posted: Sat Jul 05, 2014 4:17 pm Post subject: D3D clearing drawn text |
|
|
Hi. I have one question about the example below
Whenever I use 'd3dhook_textcontainer_setText' it overwrites previous one.Would you tell me guys how to clear Old Drawn Text before updating it.Thanks in advance
Code: | d3dhook_initializeHook()
font=createFont() --Default initialized to the mainform font. (black and small)
--You can change the font properties like size, type, bold, color, etc.. (Don't do italic as it can break the fontmap)
fontmap=d3dhook_createFontmap(font) --create a fontmap from the defined font. After this font can be destroyed. If you wish different colors and types, create a new fontmap each time
DisplayedTextObject=d3dhook_createTextContainer(fontmap,100,100,'LOLOLOLOLOLOLOLOL')
--The DisplayedTextObject is a TextContainer class. It inherits from the D3DHook_RenderObject, so d3dhook_renderobject_* methods work on this object
--example to change the y position to 300 you'd do
d3dhook_renderobject_setY(DisplayedTextObject, 300)
--The textcontainer also has it's own methods, like d3dhook_textcontainer_setText
d3dhook_textcontainer_setText(DisplayedTextObject, "Updated Text") |
|
|