FreeFormButton

From Crumbled World Wiki
Revision as of 13:42, 5 July 2025 by Anders (talk | contribs) (Created page with "{{:FreeFormButtonExampleCode}} ==Inheritance== Panel ==Constructor== {| class="wikitable" !|function !|description |- |FreeFormButton(Vec2 centerPos, FreeFormButtonDesign design) | |- |FreeFormButton(Vec2 centerPos, FreeFormButtonDesign design, Texture textureName, Vec2 minCoord, Vec2 maxCoord) | |- |} ==Functions== {| class="wikitable" !|return !|function !|description |- | |FreeFormButton:setColor(Vec3 innerRingColorTop, Vec3 inner...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

FreeFormButtonExampleCode

Inheritance

Panel

Constructor

function description
FreeFormButton(Vec2 centerPos, FreeFormButtonDesign design)
FreeFormButton(Vec2 centerPos, FreeFormButtonDesign design, Texture textureName, Vec2 minCoord, Vec2 maxCoord)

Functions

return function description
setColor(Vec3 innerRingColorTop, Vec3 innerRingColorBottom, Vec3 outerRingColorTop, Vec3 outerRingColorBottom) Set button color
setEnabled(bool enable) Set enabled
setButtonDesign(FreeFormButtonDesign design) Set button design
Sprite getImage() Return the image sprite
Sprite getSecondaryImage() Return the secondary image sprite
setSelected(bool selected) set if button is in selected
bool getSelected() get if selected