isrenderobj Synchronous
Check whether a value is a live drawing object. Use it before accepting an object in code that works with drawings. A removed drawing returns false, even if your script still holds its old handle. This makes it useful for checking object lifetime before an update.
Luau
isrenderobj(value: any) -> booleanParameters
| Parameter | Type | Description |
|---|---|---|
value | any | Value to inspect. |
Returns
booleantrue for an existing DrawingObject; false for other values and for a drawing that has been removed.
Example
Luau
local square = Drawing.new("Square")
print(isrenderobj(square)) -- true
square:Remove()
print(isrenderobj(square)) -- false