G.CreateSprite

From GMod Wiki

Revision as of 12:10, 15 December 2010 by Wizard of Ass (Talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search
Function
Syntax CreateSprite( Material Material )
Where is this used?
Description:
This is a binding to create a DSprite.
Returns: Panel DSprite
Part of Library: Global Functions
Realm: NewerClient.png
BBCode Link: [b][url=http://wiki.garrysmod.com/?title=G.CreateSprite]G.CreateSprite [img]http://wiki.garrysmod.com/favicon.ico[/img][/url][/b]



Examples

DescriptionThis is how it is defined in. Also watch derma/lua/vgui/DSprite.lua
Used onNewerClient.png
Code
 
  function CreateSprite( mat )
        local sprite = vgui.Create( "DSprite" )
        sprite:SetMaterial( mat )
        return sprite
end
 
OutputNone
Personal tools
Namespaces
Variants
Actions
Navigation
Lua Scripting
Functions
Hooks
Toolbox