|
|
@@ -32,10 +32,25 @@ namespace GamecraftModdingAPI.Blocks |
|
|
|
} |
|
|
|
|
|
|
|
/// <summary> |
|
|
|
/// Finds the identfier blocks with the given ID. |
|
|
|
/// Simulation-time ID. Assigned by the game starting from 0. |
|
|
|
/// </summary> |
|
|
|
public byte SimID |
|
|
|
{ |
|
|
|
get => BlockEngine.GetBlockInfo<ObjectIdEntityStruct>(Id).simObjectId; |
|
|
|
} |
|
|
|
|
|
|
|
/// <summary> |
|
|
|
/// Finds the identifier blocks with the given ID. |
|
|
|
/// </summary> |
|
|
|
/// <param name="id">The ID to look for</param> |
|
|
|
/// <returns>An array that may be empty</returns> |
|
|
|
public static ObjectIdentifier[] GetByID(char id) => BlockEngine.GetObjectIDsFromID((byte) (id - 'A')); |
|
|
|
public static ObjectIdentifier[] GetByID(char id) => BlockEngine.GetObjectIDsFromID((byte) (id - 'A'), false); |
|
|
|
|
|
|
|
/// <summary> |
|
|
|
/// Finds the identifier blocks with the given simulation-time ID. This ID is assigned by the game starting from 0. |
|
|
|
/// </summary> |
|
|
|
/// <param name="id"></param> |
|
|
|
/// <returns></returns> |
|
|
|
public static ObjectIdentifier[] GetBySimID(byte id) => BlockEngine.GetObjectIDsFromID(id, true); |
|
|
|
} |
|
|
|
} |