steadygreenhouses compat
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"total": 591213,
|
||||
"total": 592730,
|
||||
"sessions": [
|
||||
{
|
||||
"begin": "2026-01-09T17:26:02+01:00",
|
||||
@@ -1350,6 +1350,11 @@
|
||||
"begin": "2026-03-09T03:21:11+01:00",
|
||||
"end": "2026-03-09T03:57:24+01:00",
|
||||
"duration": 2173
|
||||
},
|
||||
{
|
||||
"begin": "2026-03-21T01:18:07+01:00",
|
||||
"end": "2026-03-21T01:43:24+01:00",
|
||||
"duration": 1517
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -99,6 +99,10 @@ public readonly record struct BeehiveStats
|
||||
float currentTemperature = climate?.Temperature ?? 20f;
|
||||
if (isGreenhouse)
|
||||
currentTemperature += 5;
|
||||
|
||||
if (OrekiWoofsBeehivesModSystem.IsSteadyGreenhousesLoaded)
|
||||
return Math.Max(currentTemperature, Config.Instance.MaxTemperatureGrowth);
|
||||
|
||||
return currentTemperature;
|
||||
}
|
||||
|
||||
|
||||
@@ -15,6 +15,9 @@ public partial class OrekiWoofsBeehivesModSystem : ModSystem
|
||||
private Harmony? _harmony;
|
||||
private ICoreServerAPI? serverApi;
|
||||
private ICoreAPI? api;
|
||||
|
||||
public static bool IsSteadyGreenhousesLoaded { get; private set; }
|
||||
|
||||
private MetaConfig metaConfig = new();
|
||||
|
||||
public BeehiveRegistry BeehiveRegistry { get; } = new();
|
||||
@@ -25,6 +28,9 @@ public partial class OrekiWoofsBeehivesModSystem : ModSystem
|
||||
public override void Start(ICoreAPI api)
|
||||
{
|
||||
this.api = api;
|
||||
|
||||
IsSteadyGreenhousesLoaded = api.ModLoader.IsModEnabled("steadygreenhouses");
|
||||
|
||||
api.RegisterBlockBehaviorClass(nameof(BlockBehaviorBeehiveAffected), typeof(BlockBehaviorBeehiveAffected));
|
||||
api.RegisterBlockEntityBehaviorClass(nameof(BlockEntityBehaviorBeehiveYieldMultiplier), typeof(BlockEntityBehaviorBeehiveYieldMultiplier));
|
||||
api.RegisterBlockEntityBehaviorClass(nameof(BlockEntityBehaviorVanillaSkepSwarmTarget), typeof(BlockEntityBehaviorVanillaSkepSwarmTarget));
|
||||
|
||||
Reference in New Issue
Block a user