Skip to main content

AdorneeUtils

Utilities involving an "Adornee" effectively, any Roblox instance. This is an extremely useful library to use as it lets you abstract applying effects to any Roblox instance instead of specifically switching for different Roblox types.

Functions

getCenter

AdorneeUtils.getCenter(adorneeInstance) → Vector3?

Gets the center of the adornee

getBoundingBox

AdorneeUtils.getBoundingBox(adorneeInstance) → (
CFrame?,--

Center of the bounding box

Vector3?--

Size of the bounding box

)

Gets the bounding box of the adornee

setBoundingBoxCFrame

AdorneeUtils.setBoundingBoxCFrame(
adorneeInstance,
cframeCFrame--

New bounding box cframe

) → boolean--

False when the adornee has no bounding box to move

Moves the adornee so its bounding box sits at the given cframe, keeping every part where it sits relative to the others.

This is the counterpart to AdorneeUtils.getBoundingBox, and is not the same as PivotTo, which moves the adornee by its pivot rather than by the center of its bounds.

isPartOfAdornee

AdorneeUtils.isPartOfAdornee(
adorneeInstance,
partBasePart
) → boolean

Returns whether a part is a part of an adornee

getParts

AdorneeUtils.getParts(adorneeInstance) → {BasePart}

Retrieves all parts of an adornee

getAlignedSize

AdorneeUtils.getAlignedSize(adorneeInstance) → Vector3?

Retrieves a size aligned the adornee's CFrame

getPartCFrame

AdorneeUtils.getPartCFrame(adorneeInstance) → CFrame

Retrieves this adornee's "part"'s CFrame.

getPartPosition

AdorneeUtils.getPartPosition(adorneeInstance) → Position

Retrieves this adornee's "part"'s position.

getPartVelocity

AdorneeUtils.getPartVelocity(adorneeInstance) → Vector3

Retrieves this adornee's "part"'s Velocity.

getPart

AdorneeUtils.getPart(adorneeInstance) → BasePart

Retrieves this adornee's part

getRenderAdornee

AdorneeUtils.getRenderAdornee(adorneeInstance) → Instance

Retrieves this adornee's part on which to attach a rendering instance to

Show raw api
{
    "functions": [
        {
            "name": "getCenter",
            "desc": "Gets the center of the adornee",
            "params": [
                {
                    "name": "adornee",
                    "desc": "",
                    "lua_type": "Instance"
                }
            ],
            "returns": [
                {
                    "desc": "",
                    "lua_type": "Vector3?"
                }
            ],
            "function_type": "static",
            "source": {
                "line": 19,
                "path": "src/adorneeutils/src/Shared/AdorneeUtils.lua"
            }
        },
        {
            "name": "getBoundingBox",
            "desc": "Gets the bounding box of the adornee",
            "params": [
                {
                    "name": "adornee",
                    "desc": "",
                    "lua_type": "Instance"
                }
            ],
            "returns": [
                {
                    "desc": "Center of the bounding box",
                    "lua_type": "CFrame?"
                },
                {
                    "desc": "Size of the bounding box",
                    "lua_type": "Vector3?"
                }
            ],
            "function_type": "static",
            "source": {
                "line": 60,
                "path": "src/adorneeutils/src/Shared/AdorneeUtils.lua"
            }
        },
        {
            "name": "setBoundingBoxCFrame",
            "desc": "Moves the adornee so its bounding box sits at the given cframe, keeping every part where it\nsits relative to the others.\n\nThis is the counterpart to [AdorneeUtils.getBoundingBox], and is not the same as `PivotTo`,\nwhich moves the adornee by its pivot rather than by the center of its bounds.",
            "params": [
                {
                    "name": "adornee",
                    "desc": "",
                    "lua_type": "Instance"
                },
                {
                    "name": "cframe",
                    "desc": "New bounding box cframe",
                    "lua_type": "CFrame"
                }
            ],
            "returns": [
                {
                    "desc": "False when the adornee has no bounding box to move",
                    "lua_type": "boolean"
                }
            ],
            "function_type": "static",
            "source": {
                "line": 83,
                "path": "src/adorneeutils/src/Shared/AdorneeUtils.lua"
            }
        },
        {
            "name": "isPartOfAdornee",
            "desc": "Returns whether a part is a part of an adornee",
            "params": [
                {
                    "name": "adornee",
                    "desc": "",
                    "lua_type": "Instance"
                },
                {
                    "name": "part",
                    "desc": "",
                    "lua_type": "BasePart"
                }
            ],
            "returns": [
                {
                    "desc": "",
                    "lua_type": "boolean"
                }
            ],
            "function_type": "static",
            "source": {
                "line": 110,
                "path": "src/adorneeutils/src/Shared/AdorneeUtils.lua"
            }
        },
        {
            "name": "getParts",
            "desc": "Retrieves all parts of an adornee",
            "params": [
                {
                    "name": "adornee",
                    "desc": "",
                    "lua_type": "Instance"
                }
            ],
            "returns": [
                {
                    "desc": "",
                    "lua_type": "{ BasePart }"
                }
            ],
            "function_type": "static",
            "source": {
                "line": 129,
                "path": "src/adorneeutils/src/Shared/AdorneeUtils.lua"
            }
        },
        {
            "name": "getAlignedSize",
            "desc": "Retrieves a size aligned the adornee's CFrame",
            "params": [
                {
                    "name": "adornee",
                    "desc": "",
                    "lua_type": "Instance"
                }
            ],
            "returns": [
                {
                    "desc": "",
                    "lua_type": "Vector3?"
                }
            ],
            "function_type": "static",
            "source": {
                "line": 160,
                "path": "src/adorneeutils/src/Shared/AdorneeUtils.lua"
            }
        },
        {
            "name": "getPartCFrame",
            "desc": "Retrieves this adornee's \"part\"'s CFrame.",
            "params": [
                {
                    "name": "adornee",
                    "desc": "",
                    "lua_type": "Instance"
                }
            ],
            "returns": [
                {
                    "desc": "",
                    "lua_type": "CFrame"
                }
            ],
            "function_type": "static",
            "source": {
                "line": 190,
                "path": "src/adorneeutils/src/Shared/AdorneeUtils.lua"
            }
        },
        {
            "name": "getPartPosition",
            "desc": "Retrieves this adornee's \"part\"'s position.",
            "params": [
                {
                    "name": "adornee",
                    "desc": "",
                    "lua_type": "Instance"
                }
            ],
            "returns": [
                {
                    "desc": "",
                    "lua_type": "Position"
                }
            ],
            "function_type": "static",
            "source": {
                "line": 206,
                "path": "src/adorneeutils/src/Shared/AdorneeUtils.lua"
            }
        },
        {
            "name": "getPartVelocity",
            "desc": "Retrieves this adornee's \"part\"'s Velocity.",
            "params": [
                {
                    "name": "adornee",
                    "desc": "",
                    "lua_type": "Instance"
                }
            ],
            "returns": [
                {
                    "desc": "",
                    "lua_type": "Vector3"
                }
            ],
            "function_type": "static",
            "source": {
                "line": 222,
                "path": "src/adorneeutils/src/Shared/AdorneeUtils.lua"
            }
        },
        {
            "name": "getPart",
            "desc": "Retrieves this adornee's part",
            "params": [
                {
                    "name": "adornee",
                    "desc": "",
                    "lua_type": "Instance"
                }
            ],
            "returns": [
                {
                    "desc": "",
                    "lua_type": "BasePart"
                }
            ],
            "function_type": "static",
            "source": {
                "line": 236,
                "path": "src/adorneeutils/src/Shared/AdorneeUtils.lua"
            }
        },
        {
            "name": "getRenderAdornee",
            "desc": "Retrieves this adornee's part on which to attach a rendering instance to",
            "params": [
                {
                    "name": "adornee",
                    "desc": "",
                    "lua_type": "Instance"
                }
            ],
            "returns": [
                {
                    "desc": "",
                    "lua_type": "Instance"
                }
            ],
            "function_type": "static",
            "source": {
                "line": 271,
                "path": "src/adorneeutils/src/Shared/AdorneeUtils.lua"
            }
        }
    ],
    "properties": [],
    "types": [],
    "name": "AdorneeUtils",
    "desc": "Utilities involving an \"Adornee\" effectively, any Roblox instance. This is an extremely\nuseful library to use as it lets you abstract applying effects to any Roblox instance\ninstead of specifically switching for different Roblox types.",
    "source": {
        "line": 9,
        "path": "src/adorneeutils/src/Shared/AdorneeUtils.lua"
    }
}