s&box docs

public sealed class Sandbox.GameObjectDirectory

New GameObjects and Components are registered with this class when they're created, and unregistered when they're removed. This gives us a single place to enforce Id uniqueness in the scene, and allows for fast lookups by Id.

Methods

Showing 3 methods

public Sandbox.GameObject FindByGuid(System.Guid guid)

Find a GameObject in the scene by Guid. This should be really really fast.

public System.Collections.Generic.IEnumerable`1<Sandbox.GameObject> FindByName(string name, bool caseinsensitive = True)

Find objects with this name. Not performant.

Parameters

  • caseinsensitive: Default: True

public Sandbox.Component FindComponentByGuid(System.Guid guid)

Find a Component in the scene by Guid. This should be really really fast.

Properties

Showing 3 properties

Metadata

FieldValue
NamespaceSandbox
Typeclass
AssemblySandbox.Engine
Doc IDT:Sandbox.GameObjectDirectory

On this page