Api > GameObject > GetComponentsInParent()
GameObject.GetComponentsInParent([]{Generic : Component|info} type)⚓︎
Returns all components of Type type in the GameObject or any of its parents.
Parameters:⚓︎
Name | Type | Description |
---|---|---|
type | [ |
info} |
Returns:⚓︎
type | Description |
---|---|
[ |
info}[] |
Usage⚓︎
---@type GameObject
local gameobject;
---@type TComponent
local type;
local val0 = gameobject.GetComponentsInParent(type)