Initial import
This commit is contained in:
45
Assets/Scripts/Components/Aspects.cs
Normal file
45
Assets/Scripts/Components/Aspects.cs
Normal file
@@ -0,0 +1,45 @@
|
||||
using Unity.Entities;
|
||||
using Unity.Transforms;
|
||||
|
||||
namespace EE2Clone.Components
|
||||
{
|
||||
public readonly partial struct UnitAspect : IAspect
|
||||
{
|
||||
public readonly Entity Entity;
|
||||
|
||||
public readonly RefRW<LocalTransform> Transform;
|
||||
public readonly RefRO<Health> Health;
|
||||
public readonly RefRO<OwnerPlayer> Owner;
|
||||
public readonly RefRO<MovementSpeed> Speed;
|
||||
public readonly RefRW<MoveTarget> MoveTarget;
|
||||
public readonly RefRO<AttackData> Attack;
|
||||
public readonly RefRO<ArmorData> Armor;
|
||||
public readonly RefRO<UnitClassComponent> UnitClass;
|
||||
public readonly RefRW<UnitStateComponent> State;
|
||||
public readonly RefRO<LineOfSight> LineOfSight;
|
||||
}
|
||||
|
||||
public readonly partial struct BuildingAspect : IAspect
|
||||
{
|
||||
public readonly Entity Entity;
|
||||
|
||||
public readonly RefRO<LocalTransform> Transform;
|
||||
public readonly RefRW<Health> Health;
|
||||
public readonly RefRO<OwnerPlayer> Owner;
|
||||
public readonly RefRO<BuildingTypeComponent> BuildingType;
|
||||
public readonly RefRO<LineOfSight> LineOfSight;
|
||||
}
|
||||
|
||||
public readonly partial struct GathererAspect : IAspect
|
||||
{
|
||||
public readonly Entity Entity;
|
||||
|
||||
public readonly RefRW<LocalTransform> Transform;
|
||||
public readonly RefRO<OwnerPlayer> Owner;
|
||||
public readonly RefRO<MovementSpeed> Speed;
|
||||
public readonly RefRW<MoveTarget> MoveTarget;
|
||||
public readonly RefRW<CitizenStateComponent> CitizenState;
|
||||
public readonly RefRW<CarriedResource> CarriedResource;
|
||||
public readonly RefRW<GatherTarget> GatherTarget;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user