Baldi's Basics Plus Glue API
Modding API for Baldi's Basics Plus
Loading...
Searching...
No Matches
BBPGlue.API.BBPAuthoredPrefab Struct Reference

Represents a prefab-like object authored or registered through BBPGlue. More...

Public Member Functions

T? As< T > ()
 Casts the raw object to a specific type when possible.
BBPItemObject AsItemObject ()
 Wraps this prefab as an item object.
BBPNpc AsNpc ()
 Wraps this prefab as an NPC.
BBPPickup AsPickup ()
 Wraps this prefab as a pickup.
 BBPAuthoredPrefab (string id, object? raw)

Static Public Member Functions

static BBPAuthoredPrefab Null (string id)
 Creates an empty authored prefab result.

Public Attributes

readonly string Id
 Stable BBPGlue id used to register this prefab.
readonly? object Raw
 Raw Unity/game object stored by BBPGlue.

Properties

bool Exists [get]
 True if this authored prefab contains a valid raw object.

Detailed Description

Represents a prefab-like object authored or registered through BBPGlue.

Constructor & Destructor Documentation

◆ BBPAuthoredPrefab()

BBPGlue.API.BBPAuthoredPrefab.BBPAuthoredPrefab ( string id,
object? raw )

Member Function Documentation

◆ As< T >()

T? BBPGlue.API.BBPAuthoredPrefab.As< T > ( )

Casts the raw object to a specific type when possible.

Type Constraints
T :class 

◆ AsItemObject()

BBPItemObject BBPGlue.API.BBPAuthoredPrefab.AsItemObject ( )

Wraps this prefab as an item object.

◆ AsNpc()

BBPNpc BBPGlue.API.BBPAuthoredPrefab.AsNpc ( )

Wraps this prefab as an NPC.

◆ AsPickup()

BBPPickup BBPGlue.API.BBPAuthoredPrefab.AsPickup ( )

Wraps this prefab as a pickup.

◆ Null()

BBPAuthoredPrefab BBPGlue.API.BBPAuthoredPrefab.Null ( string id)
static

Creates an empty authored prefab result.

Member Data Documentation

◆ Id

readonly string BBPGlue.API.BBPAuthoredPrefab.Id

Stable BBPGlue id used to register this prefab.

◆ Raw

readonly? object BBPGlue.API.BBPAuthoredPrefab.Raw

Raw Unity/game object stored by BBPGlue.

Property Documentation

◆ Exists

bool BBPGlue.API.BBPAuthoredPrefab.Exists
get

True if this authored prefab contains a valid raw object.


The documentation for this struct was generated from the following file: