From 8024aa9acfe5fe620b12e621d3948633d9fd78db Mon Sep 17 00:00:00 2001 From: dymanoid <9433345+dymanoid@users.noreply.github.com> Date: Thu, 25 Oct 2018 22:09:06 +0200 Subject: [PATCH] Add new service types from the Industries DLC --- src/RealTime/CustomAI/WorkBehavior.cs | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/RealTime/CustomAI/WorkBehavior.cs b/src/RealTime/CustomAI/WorkBehavior.cs index 626aeca2..637e69e5 100644 --- a/src/RealTime/CustomAI/WorkBehavior.cs +++ b/src/RealTime/CustomAI/WorkBehavior.cs @@ -63,6 +63,8 @@ public bool IsBuildingWorking(ItemClass.Service service, ItemClass.SubService su case ItemClass.SubService.CommercialLow: case ItemClass.SubService.IndustrialOil: case ItemClass.SubService.IndustrialOre: + case ItemClass.SubService.PlayerIndustryOre: + case ItemClass.SubService.PlayerIndustryOil: return true; } @@ -245,6 +247,7 @@ private static bool IsBuildingActiveOnWeekend(ItemClass.Service service, ItemCla case ItemClass.Service.Commercial when subService != ItemClass.SubService.CommercialHigh && subService != ItemClass.SubService.CommercialEco: case ItemClass.Service.Industrial when subService != ItemClass.SubService.IndustrialGeneric: + case ItemClass.Service.PlayerIndustry: case ItemClass.Service.Tourism: case ItemClass.Service.Electricity: case ItemClass.Service.Water: @@ -270,6 +273,8 @@ private static int GetBuildingWorkShiftCount(ItemClass.Service service, ItemClas { case ItemClass.Service.Office: case ItemClass.Service.Education: + case ItemClass.Service.PlayerIndustry + when subService == ItemClass.SubService.PlayerIndustryForestry || subService == ItemClass.SubService.PlayerIndustryFarming: case ItemClass.Service.Industrial when subService == ItemClass.SubService.IndustrialForestry || subService == ItemClass.SubService.IndustrialFarming: return 1; @@ -292,6 +297,7 @@ private static int GetBuildingWorkShiftCount(ItemClass.Service service, ItemClas case ItemClass.Service.Natural: case ItemClass.Service.Garbage: case ItemClass.Service.Road: + case ItemClass.Service.PlayerIndustry: return 3; default: @@ -306,6 +312,7 @@ private static bool HasExtendedFirstWorkShift(ItemClass.Service service, ItemCla case ItemClass.Service.Commercial when subService == ItemClass.SubService.CommercialLow: case ItemClass.Service.Beautification: case ItemClass.Service.Education: + case ItemClass.Service.PlayerIndustry: case ItemClass.Service.Industrial when subService == ItemClass.SubService.IndustrialFarming || subService == ItemClass.SubService.IndustrialForestry: return true;