feat(Documents) Notes/Docs page improvements and warning cleanup
This commit is contained in:
@@ -1,18 +1,21 @@
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using Model.Immortal.Entity;
|
||||
using Model.Immortal.Entity.Data;
|
||||
using Model.Entity;
|
||||
using Model.Entity.Data;
|
||||
|
||||
namespace Model.Immortal.BuildOrders;
|
||||
namespace Model.BuildOrders;
|
||||
|
||||
public class BuildOrderModel {
|
||||
public class BuildOrderModel
|
||||
{
|
||||
public string Name { get; set; } = "";
|
||||
public string Color { get; set; } = "red";
|
||||
|
||||
public Dictionary<int, List<EntityModel>> Orders { get; set; } = new() {
|
||||
public Dictionary<int, List<EntityModel>> Orders { get; set; } = new()
|
||||
{
|
||||
{
|
||||
0,
|
||||
new List<EntityModel> {
|
||||
new List<EntityModel>
|
||||
{
|
||||
EntityModel.Get(DataType.STARTING_Bastion),
|
||||
EntityModel.Get(DataType.STARTING_TownHall_Aru)
|
||||
}
|
||||
@@ -24,28 +27,32 @@ public class BuildOrderModel {
|
||||
public List<string> BuildTypes { get; set; } = new();
|
||||
|
||||
|
||||
public List<EntityModel> GetOrdersAt(int interval) {
|
||||
public List<EntityModel> GetOrdersAt(int interval)
|
||||
{
|
||||
return (from ordersAtTime in Orders
|
||||
from orders in ordersAtTime.Value
|
||||
where ordersAtTime.Key == interval
|
||||
select orders).ToList();
|
||||
}
|
||||
|
||||
public List<EntityModel> GetCompletedAt(int interval) {
|
||||
public List<EntityModel> GetCompletedAt(int interval)
|
||||
{
|
||||
return (from ordersAtTime in Orders
|
||||
from orders in ordersAtTime.Value
|
||||
where ordersAtTime.Key + (orders.Production() == null ? 0 : orders.Production().BuildTime) == interval
|
||||
select orders).ToList();
|
||||
}
|
||||
|
||||
public List<EntityModel> GetCompletedBefore(int interval) {
|
||||
public List<EntityModel> GetCompletedBefore(int interval)
|
||||
{
|
||||
return (from ordersAtTime in Orders
|
||||
from orders in ordersAtTime.Value
|
||||
where ordersAtTime.Key + (orders.Production() == null ? 0 : orders.Production().BuildTime) <= interval
|
||||
select orders).ToList();
|
||||
}
|
||||
|
||||
public List<EntityModel> GetHarvestersCompletedBefore(int interval) {
|
||||
public List<EntityModel> GetHarvestersCompletedBefore(int interval)
|
||||
{
|
||||
return (from ordersAtTime in Orders
|
||||
from orders in ordersAtTime.Value
|
||||
where ordersAtTime.Key + (orders.Production() == null ? 0 : orders.Production().BuildTime) <= interval
|
||||
|
||||
Reference in New Issue
Block a user