draw.SimpleText

From GMod Wiki

Revision as of 21:41, 2 February 2011 by Donkie (Talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search
Function
Syntax draw.SimpleText( String Text, String Font, Number X, Number Y, Color Color, Number Xalign, Number Yalign )
Where is this used?
Description:
Draws simple text on the clients HUD
Returns: nil
Part of Library: Draw
Realm: NewerClient.png
BBCode Link: [b][url=http://wiki.garrysmod.com/?title=Draw.SimpleText]Draw.SimpleText [img]http://wiki.garrysmod.com/favicon.ico[/img][/url][/b]



Examples

DescriptionPrints text on the screen.
Used onNewerClient.png
Code
 
function GM:HUDPaint()
	draw.SimpleText("Oh No!", "ScoreboardText", ScrW() / 2 - 70, ScrH() - 63, Color(255,255,255,255), TEXT_ALIGN_CENTER, TEXT_ALIGN_CENTER)
end
 
Output"Oh No!" is printed on the screen.


Additional Notes

SHARED | 0000000000000000 | 00000000000000000 | TEXT_ALIGN_LEFT
SHARED | 0000000000000001 | 00000000000000001 | TEXT_ALIGN_CENTER
SHARED | 0000000000000002 | 00000000000000010 | TEXT_ALIGN_RIGHT
SHARED | 0000000000000003 | 00000000000000011 | TEXT_ALIGN_TOP
SHARED | 0000000000000004 | 00000000000000100 | TEXT_ALIGN_BOTTOM

See Also

Personal tools
Namespaces
Variants
Actions
Navigation
Lua Scripting
Functions
Hooks
Toolbox