Add backend projects with core models and tests, setup Godot frontend

This commit is contained in:
sokol
2026-02-20 21:01:09 +03:00
parent fc3ad9f6db
commit f320aa50ed
14 changed files with 518 additions and 0 deletions

View File

@@ -0,0 +1,47 @@
namespace MyBiz.Core;
/// <summary>
/// Размер города
/// </summary>
public enum CitySize
{
Small, // Малый
Medium, // Средний
Large // Крупный
}
/// <summary>
/// Город
/// </summary>
public class City
{
public string Id { get; set; } = Guid.NewGuid().ToString();
public string Name { get; set; } = string.Empty;
public string Country { get; set; } = string.Empty;
public CitySize Size { get; set; }
/// <summary>
/// Население
/// </summary>
public int Population { get; set; }
/// <summary>
/// Доступные здания
/// </summary>
public List<Building> Buildings { get; set; } = new();
/// <summary>
/// Рынок города (спрос на продукты)
/// </summary>
public Dictionary<ProductType, int> MarketDemand { get; set; } = new();
/// <summary>
/// Предложение на рынке
/// </summary>
public Dictionary<ProductType, int> MarketSupply { get; set; } = new();
/// <summary>
/// Текущие цены
/// </summary>
public Dictionary<ProductType, decimal> Prices { get; set; } = new();
}