RaptorMaterialTile
A Materials drawer tile as passed to an extension (IRaptorDockExtension).
| Namespace | Assembly | Kind | Stability |
|---|---|---|---|
Raptor.EditorTools | Raptor.Editor | struct | preview, since 0.1.0 |
A default tile has no GUID and refers to no material.
public readonly struct RaptorMaterialTileConstructors
RaptorMaterialTile
public RaptorMaterialTile(string guid, string path, string name, string pack, bool isSpecial, bool isHotspotSheet)Creates a tile with every field set.
| Parameter | Type | Description |
|---|---|---|
guid | string | The material's asset GUID. |
path | string | The material's asset path. |
name | string | The display name. |
pack | string | The pack it belongs to. |
isSpecial | bool | Whether the material is a Special tool material. |
isHotspotSheet | bool | Whether the material is a listed hotspot sheet. |
Fields
guid
public readonly string guid;The material's asset GUID. Null or empty means no material.
isHotspotSheet
public readonly bool isHotspotSheet;Whether the material is a hotspot sheet listed in the drawer's Hotspot section.
isSpecial
public readonly bool isSpecial;Whether the material is one of RAPTOR's Special tool materials, such as Skybox, NoDraw or Block Light. Matched by asset identity.
name
public readonly string name;The tile's display name.
pack
public readonly string pack;The pack (library row) the tile belongs to.
path
public readonly string path;The material's asset path.
Properties
IsValid
public bool IsValid { get; }Whether the tile has a GUID and so refers to a material.
Methods
LoadMaterial
public Material LoadMaterial()Loads the tile's material through the drawer's cache.
Returns: The material, or null when it is gone.
Related types
- IRaptorDockExtension: A per-drawer extension of the Materials drawer (RaptorMaterialsDrawer.RegisterExtension).