Table of Contents

Class Building

Namespace
S1API.Map
Assembly
S1API.dll

Modder-facing wrapper for an enterable building in the world. Provides name-based lookup and basic metadata without exposing game types.

public sealed class Building
Inheritance
Building
Inherited Members
Extension Methods

Fields

All

public static readonly List<Building> All

Field Value

List<Building>

Properties

Name

Display name of the building.

public string Name { get; }

Property Value

string

Methods

GetAll()

Returns all known buildings (sorted by name).

public static Building[] GetAll()

Returns

Building[]

GetByName(string)

Returns the first building with the provided display name, or null.

public static Building GetByName(string name)

Parameters

name string

Returns

Building

Get<T>()

Resolves a building using a typed identifier T. Declare an identifier class annotated with [Buildings.BuildingName("...")].

public static Building Get<T>() where T : IBuildingIdentifier

Returns

Building

Type Parameters

T