using Unity.Entities; using Unity.Mathematics; using Unity.NetCode; using EE2Clone.Core; namespace EE2Clone.NetCode { /// /// Client requests to move selected units to a position. /// public struct MoveCommandRpc : IRpcCommand { public Entity UnitEntity; public float3 TargetPosition; } /// /// Client requests to attack a target with selected units. /// public struct AttackCommandRpc : IRpcCommand { public Entity AttackerEntity; public Entity TargetEntity; } /// /// Client requests to place a building. /// public struct PlaceBuildingRpc : IRpcCommand { public BuildingType Type; public float3 Position; public quaternion Rotation; } /// /// Client requests to set a rally point on a building. /// public struct SetRallyPointRpc : IRpcCommand { public Entity BuildingEntity; public float3 Position; } /// /// Client requests to queue unit production in a building. /// public struct QueueUnitProductionRpc : IRpcCommand { public Entity BuildingEntity; public int UnitDataId; } /// /// Client requests to gather from a resource node. /// public struct GatherCommandRpc : IRpcCommand { public Entity CitizenEntity; public Entity ResourceNodeEntity; } /// /// Client requests to assign citizens to build/repair a building. /// public struct BuildRepairCommandRpc : IRpcCommand { public Entity CitizenEntity; public Entity BuildingEntity; } /// /// Client requests to research a technology. /// public struct ResearchTechRpc : IRpcCommand { public Entity BuildingEntity; public int TechId; } /// /// Client requests to advance to the next epoch. /// public struct EpochAdvanceRpc : IRpcCommand { } /// /// Client requests to stop selected units. /// public struct StopCommandRpc : IRpcCommand { public Entity UnitEntity; } }