Class NPCImpostorCatalog
Provides access to avatar impostors discovered from the game's runtime character settings resources.
public static class NPCImpostorCatalog
- Inheritance
-
NPCImpostorCatalog
- Inherited Members
Methods
Find(string)
Finds an impostor by character settings name or resource path.
public static AvatarImpostorDefinition? Find(string name)
Parameters
namestringName such as
Kyle, or path such ascharactersettings/Kyle.
Returns
- AvatarImpostorDefinition
The matched impostor definition, or
nullif no match was found.
GetAll()
Gets all currently discoverable game-owned NPC impostors.
public static IReadOnlyList<AvatarImpostorDefinition> GetAll()
Returns
- IReadOnlyList<AvatarImpostorDefinition>
Definitions for character settings that contain an impostor texture.
GetRandom(int)
Selects a deterministic random impostor from all currently discoverable impostors.
public static AvatarImpostorDefinition? GetRandom(int seed)
Parameters
seedintSeed used to choose the impostor.
Returns
- AvatarImpostorDefinition
A discovered impostor definition, or
nullwhen none are available.
TryFind(string, out AvatarImpostorDefinition?)
Finds an impostor by character settings name or resource path.
public static bool TryFind(string name, out AvatarImpostorDefinition? impostor)
Parameters
namestringName such as
Kyle, or path such ascharactersettings/Kyle.impostorAvatarImpostorDefinitionThe matched impostor definition, if found.
Returns
- bool
truewhen a matching impostor was found.