Class PlaceableResourceLoader
- Namespace
- MoonBark.GridPlacement.Core.Types
- Assembly
- MoonBark.GridPlacement.Core.dll
Handles loading and validation of placeable resource metadata. Pure C# implementation without engine dependencies.
public static class PlaceableResourceLoader
- Inheritance
-
PlaceableResourceLoader
- Inherited Members
Methods
CreateFromFile(string, string, string)
Creates a placeable with a file path reference.
public static Placeable CreateFromFile(string id, string name, string filePath)
Parameters
idstringUnique identifier
namestringDisplay name
filePathstringPath to the engine resource file.
Returns
- Placeable
Configured placeable
CreateFromUid(string, string, string)
Creates a placeable with an external ID reference.
public static Placeable CreateFromUid(string id, string name, string resourceUid)
Parameters
Returns
- Placeable
Configured placeable
GetResourceIdentifier(Placeable)
Gets the resource identifier (path or engine-specific external ID) for a placeable.
public static string GetResourceIdentifier(Placeable placeable)
Parameters
placeablePlaceableThe placeable
Returns
- string
Resource identifier or empty string if invalid
HasValidResourceReference(Placeable)
Validates that a placeable has a resource reference.
public static bool HasValidResourceReference(Placeable placeable)
Parameters
placeablePlaceableThe placeable to validate
Returns
- bool
True if the placeable has valid resource reference
UsesFilePath(Placeable)
Determines if the resource identifier is a file path or external ID.
public static bool UsesFilePath(Placeable placeable)
Parameters
placeablePlaceableThe placeable
Returns
- bool
True if using file path, false if using UID