GetPlayer
7/14/25Less than 1 minute
GameObject.GetPlayer()
Returns a MLPlayer object if this object or any of its ancestors is a ML Player. Null Otherwise.
Returns:
| type | Description |
|---|---|
| MLPlayer | MLPlayer object if this object or any of its ancestors is a ML Player |
Usage
---@type GameObject
local gameobject;
local val0 = gameobject.GetPlayer()Extra Detail
Use GameObject.IsPlayer() to check if it can return a MLPlayer.

