find_first

Returns the first loaded instance of an Unreal class.

Syntax

ue.find_first(class_name: string) -> UObjectProxy?, string?

Parameters

ParameterTypeDescription
class_namestringUnreal class name. Derived-class instances are included.

Returns

TypeDescription
UObjectProxyThe first matching object.
nil, stringNo matching instance was found.

Example

local game = assert(ue.find_first("BreakerGameInstance"))
print(game:path())

On this page