Skip to content

Commit 50277e3

Browse files
committed
add log to NextBuildingTask
1 parent 35abff3 commit 50277e3

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

TbsCore/Helpers/UpgradeBuildingHelper.cs

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,12 +49,17 @@ public static BuildingTask NextBuildingTask(Account acc, Village vill)
4949

5050
if (numRes > numInfra)
5151
{
52-
if (vill.Res.FreeCrop <= 5) return null;
52+
if (vill.Res.FreeCrop <= 5)
53+
{
54+
acc.Logger.Information("Don't have enough slot building because of freecrop ");
55+
return null;
56+
}
5357
return GetFirstInfrastructureTask(acc, vill);
5458
}
5559
else if (numInfra > numRes)
5660
{
5761
// no need check free crop, there is magic make sure this always choose crop
62+
// just kidding, because of how we check free crop later, first res task is always crop
5863
return GetFirstResTask(acc, vill);
5964
}
6065
// if same means 1 R and 1 I already, 1 ANY will be choose below

0 commit comments

Comments
 (0)