Difference between revisions of "DrawIconByName"
From King Arthur's Gold Wiki
Shadlington (Talk | contribs) (Created page with "<onlyinclude> Draws an icon added by AddIconToken using its token name. </onlyinclude> This method has two variants. They both specify the token name as a string and the pos...") |
Shadlington (Talk | contribs) |
||
Line 2: | Line 2: | ||
Draws an icon added by [[AddIconToken]] using its token name. | Draws an icon added by [[AddIconToken]] using its token name. | ||
</onlyinclude> | </onlyinclude> | ||
+ | |||
+ | As this is GUI-related this is client only - it should be wrapped in "if ( getNet().isClient( ))" or in a client-only script. | ||
This method has two variants. They both specify the token name as a string and the position to draw the icon at with a [[position2d]]i but one also specifies a scale factor for the icon as a float. | This method has two variants. They both specify the token name as a string and the position to draw the icon at with a [[position2d]]i but one also specifies a scale factor for the icon as a float. |
Revision as of 16:04, 22 August 2012
Draws an icon added by AddIconToken using its token name.
As this is GUI-related this is client only - it should be wrapped in "if ( getNet().isClient( ))" or in a client-only script.
This method has two variants. They both specify the token name as a string and the position to draw the icon at with a position2di but one also specifies a scale factor for the icon as a float.
void DrawIconByName( const string &iconName, position2di pos ) void DrawIconByName( const string &iconName, position2di pos, f32 scale )