getrenderproperty
Dynamically get a named property from a Drawing object.
function getrenderproperty(drawing: Drawing, property: string): anySynopsis
How it works
Reads a render property from a
Drawing object or Roblox Instance by direct struct field access. For Drawing objects, this reads from the internal C++ render data struct (position, size, color, transparency, thickness, font, etc.). The property name is hashed and looked up in the object's property table.Drawing properties
Each Drawing type exposes different renderable properties:
| Type | Properties |
|---|---|
Line | From, To, Color, Thickness, Transparency, Visible |
Text | Position, Text, Size, Color, Center, Outline, OutlineColor, Font, Transparency, Visible |
Circle | Position, Radius, Color, Thickness, Filled, NumSides, Transparency, Visible |
Square | Position, Size, Color, Thickness, Filled, Transparency, Visible |
Image | Position, Size, Data, Color, Transparency, Rounding, Visible |
Usage
Read Circle properties dynamically
local circle = Drawing.new("Circle")
circle.Radius = 50
circle.Visible = true
print(getrenderproperty(circle, "Radius")) "cc">-- 50
print(getrenderproperty(circle, "Visible")) "cc">-- trueParameters
drawing Drawing A valid Drawing object.
property string The name of the property to retrieve.
Returns
any The current value of the specified Drawing property.