Files
territory-autobattler/microservices/LocationsApi/Models/UnitInstance.cs
T
2026-05-20 04:25:24 -05:00

28 lines
999 B
C#

using MongoDB.Bson;
using MongoDB.Bson.Serialization.Attributes;
namespace LocationsApi.Models;
public class UnitInstance
{
[BsonId]
[BsonRepresentation(BsonType.ObjectId)]
public string Id { get; set; } = "";
public string Username { get; set; } = "";
public string UnitType { get; set; } = "Archer";
public int Q { get; set; }
public int R { get; set; }
public string Status { get; set; } = "Idle";
public int MovementPerTick { get; set; } = 1;
public int MovementRemaining { get; set; } = 1;
public DateTime LastMovementRefillAtUtc { get; set; } = DateTime.UtcNow;
public int? DestinationQ { get; set; }
public int? DestinationR { get; set; }
public DateTime? MovementStartedAtUtc { get; set; }
public DateTime? MovementCompletesAtUtc { get; set; }
public string? SourceTrainingId { get; set; }
public DateTime CreatedAtUtc { get; set; } = DateTime.UtcNow;
public DateTime UpdatedAtUtc { get; set; } = DateTime.UtcNow;
}