|
|
|
@ -21,10 +21,17 @@ public unsafe class IdentifierRef |
|
|
|
|
|
|
|
|
|
public static IdentifierRef Combine(IdentifierFlags flags, IdentifierRef id) |
|
|
|
|
=> new(id.World, Identifier.Combine(flags, id)); |
|
|
|
|
|
|
|
|
|
public static IdentifierRef Pair(World world, Entity relation, Entity target) |
|
|
|
|
=> new(world, Identifier.Pair(relation, target)); |
|
|
|
|
public static IdentifierRef Pair(EntityRef relation, EntityRef target) |
|
|
|
|
=> Pair(relation.World, relation, target); |
|
|
|
|
public static IdentifierRef Pair(EntityRef relation, Entity target) |
|
|
|
|
=> new(relation.World, Identifier.Pair(relation, target)); |
|
|
|
|
=> Pair(relation.World, relation, target); |
|
|
|
|
public static IdentifierRef Pair(Entity relation, EntityRef target) |
|
|
|
|
=> new(target.World, Identifier.Pair(relation, target)); |
|
|
|
|
=> Pair(target.World, relation, target); |
|
|
|
|
public static IdentifierRef Pair<TRelation>(EntityRef target) |
|
|
|
|
=> Pair(target.World.LookupByTypeOrThrow<TRelation>(), target); |
|
|
|
|
|
|
|
|
|
public EntityRef? AsEntity() |
|
|
|
|
=> (Flags == default) ? World.LookupAlive(new Entity(new() { Data = Id })) : null; |
|
|
|
|