Git Product home page Git Product logo

timberborn-simplefloodgatetriggers's People

Contributors

aliangliang avatar hytonhan avatar minorunara avatar r-t-b avatar

Stargazers

 avatar

Watchers

 avatar

timberborn-simplefloodgatetriggers's Issues

How do I set the code up for me to modify it

Hi,

I'd like to contribute to the development. The issue is that I cant get rider to find all the dependencies. Even if I add the dlls manually, it cant access stuff like "DayNightCycle" because its flagged as internal

New bug

[Error : Unity Log] NullReferenceException: Object reference not set to an instance of an object
Stack trace:
Hytone.Timberborn.Plugins.Floodgates.EntityAction.StreamGaugeMonoBehaviour.Tick () (at :0)
Timberborn.TickSystem.TickableComponent.StartAndTick () (at <981eb0b1e6b84602b601b80a36ef1ae8>:0)
Frog.PerfFixPlugin.TickableEntityTickTickableComponents (Timberborn.TickSystem.TickableEntity __instance) (at :0)
(wrapper dynamic-method) Timberborn.TickSystem.TickableEntity.DMD<Timberborn.TickSystem.TickableEntity::TickTickableComponents>(Timberborn.TickSystem.TickableEntity)
Frog.PerfFixPlugin.TickableEntityTick (Timberborn.TickSystem.TickableEntity __instance) (at :0)
Rethrow as Exception: Exception thrown while ticking entity 22a19e41-13b3-4cf5-ac7e-63ad27443712 'StreamGauge.Folktails(Clone)'
Frog.PerfFixPlugin.TickableEntityTick (Timberborn.TickSystem.TickableEntity __instance) (at :0)
(wrapper dynamic-method) Timberborn.TickSystem.TickableEntity.DMD<Timberborn.TickSystem.TickableEntity::Tick>(Timberborn.TickSystem.TickableEntity)
Timberborn.TickSystem.TickableEntityBucket.TickAll () (at <981eb0b1e6b84602b601b80a36ef1ae8>:0)
Timberborn.TickSystem.TickableBucketService.TickNextBucket () (at <981eb0b1e6b84602b601b80a36ef1ae8>:0)
Timberborn.TickSystem.TickableBucketService.TickBuckets (System.Int32 numberOfBucketsToTick) (at <981eb0b1e6b84602b601b80a36ef1ae8>:0)
Timberborn.TickSystem.Ticker.Update (System.Single deltaTimeInSeconds) (at <981eb0b1e6b84602b601b80a36ef1ae8>:0)
Timberborn.TickSystem.TickerUpdater.Update () (at <981eb0b1e6b84602b601b80a36ef1ae8>:0)

[Error : Unity Log] NullReferenceException: Object reference not set to an instance of an object
Stack trace:
Hytone.Timberborn.Plugins.Floodgates.EntityAction.StreamGaugeMonoBehaviour.Tick () (at :0)
Timberborn.TickSystem.TickableComponent.StartAndTick () (at <981eb0b1e6b84602b601b80a36ef1ae8>:0)
Frog.PerfFixPlugin.TickableEntityTickTickableComponents (Timberborn.TickSystem.TickableEntity __instance) (at :0)
(wrapper dynamic-method) Timberborn.TickSystem.TickableEntity.DMD<Timberborn.TickSystem.TickableEntity::TickTickableComponents>(Timberborn.TickSystem.TickableEntity)
Frog.PerfFixPlugin.TickableEntityTick (Timberborn.TickSystem.TickableEntity __instance) (at :0)
Rethrow as Exception: Exception thrown while ticking entity 22a19e41-13b3-4cf5-ac7e-63ad27443712 'StreamGauge.Folktails(Clone)'
Frog.PerfFixPlugin.TickableEntityTick (Timberborn.TickSystem.TickableEntity __instance) (at :0)
(wrapper dynamic-method) Timberborn.TickSystem.TickableEntity.DMD<Timberborn.TickSystem.TickableEntity::Tick>(Timberborn.TickSystem.TickableEntity)
Timberborn.TickSystem.TickableEntityBucket.TickAll () (at <981eb0b1e6b84602b601b80a36ef1ae8>:0)
Timberborn.TickSystem.TickableBucketService.TickNextBucket () (at <981eb0b1e6b84602b601b80a36ef1ae8>:0)
Timberborn.TickSystem.TickableBucketService.TickBuckets (System.Int32 numberOfBucketsToTick) (at <981eb0b1e6b84602b601b80a36ef1ae8>:0)
Timberborn.TickSystem.Ticker.Update (System.Single deltaTimeInSeconds) (at <981eb0b1e6b84602b601b80a36ef1ae8>:0)
Timberborn.TickSystem.TickerUpdater.Update () (at <981eb0b1e6b84602b601b80a36ef1ae8>:0)

[Error : Unity Log] NullReferenceException: Object reference not set to an instance of an object
Stack trace:
Timberborn.CoreUI.PanelStack.Awake () (at <77498430b31649a1b27343508f9e2bc3>:0)

Error while loading the mod FloodgateTriggersPlugin

Hi mate, I've seen your mod on Skye YT video https://www.youtube.com/watch?v=PxnLzMp5zU8 and I would like to use on my game save, but I get the following error

[Info   : Unity Log] Modded: true, BepInEx
[Info   :TimberAPI Core] TimberAPI 0.6.2.1 - Timberborn 0.5.2.1, loader: BepInEx
[Info   : TimberAPI] Mod loading started
[Info   : TimberAPI] Found 1 mods
[Info   : TimberAPI] Deserialized 1 mods
[Error  :FloodgateTriggersPlugin] Failed: Could not load type of field 'Hytone.Timberborn.Plugins.Floodgates.EntityAction.FloodgateTriggerMonoBehaviour:_droughtServíce' (15) due to: Could not resolve type with token 01000069 from typeref (expected class 'Timberborn.WeatherSystem.DroughtService' in assembly 'Timberborn.WeatherSystem, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null') assembly:Timberborn.WeatherSystem, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null type:Timberborn.WeatherSystem.DroughtService member:(null)
[Info   : TimberAPI] Mod loading finished in: 148ms, Loaded mods:0
[Info   : TimberAPI] Added 1 prefixes
Setting breakpad minidump AppID = 1062090
SteamInternal_SetMinidumpSteamID:  Caching Steam ID:  76561198011002537 [API loaded no]
[Info   : Unity Log] Successfully connected to the Steam client.
[Info   :Mod Manager UI] Loaded 29 custom labels
[Info   : TimberAPI] Loaded 0 custom labels
[Info   : TimberAPI] Assets loaded for MainMenu, Total prefixes loaded: 1
[Info   : Unity Log] Previous resolution: 1920 x 1200

Crash while auto saving (Experimental branch v0.2.2.1)

As noted in the title, when the game went to auto save, it crashed, spewing the below to the log.

[Error  : Unity Log] ArgumentException: Can't serialize Hytone.Timberborn.Plugins.Floodgates.EntityAction.StreamGaugeFloodgateLink of type Hytone.Timberborn.Plugins.Floodgates.EntityAction.StreamGaugeFloodgateLink
Stack trace:
Timberborn.WorldSerialization.PrimitiveTypeSerialization.Serialize (System.Object value) (at <aee47ec7978a4ebfb965970708fbaa52>:0)
Timberborn.WorldSerialization.ObjectSave.SetArray[T] (System.String name, T[] values) (at <aee47ec7978a4ebfb965970708fbaa52>:0)
Timberborn.Persistence.ObjectSaver.Set[T] (Timberborn.Persistence.ListKey`1[T] key, System.Collections.Generic.IReadOnlyCollection`1[T] values) (at <81093724205945d2bcf38adc918217d8>:0)
Hytone.Timberborn.Plugins.Floodgates.EntityAction.FloodgateTriggerMonoBehaviour.Save (Timberborn.Persistence.IEntitySaver entitySaver) (at <3a11c115c1b642cb8e72e426f63505d6>:0)
Timberborn.Persistence.WorldSaveFactory.SaveEntity (UnityEngine.GameObject gameObject, Timberborn.WorldSerialization.EntitySave output) (at <81093724205945d2bcf38adc918217d8>:0)
Timberborn.Persistence.WorldSaveFactory.SaveEntities (Timberborn.WorldSerialization.WorldSave worldSave) (at <81093724205945d2bcf38adc918217d8>:0)
Timberborn.Persistence.WorldSaveFactory.Create () (at <81093724205945d2bcf38adc918217d8>:0)
Timberborn.GameSaveRuntimeSystem.GameSaver.Save (Timberborn.GameSaveRepositorySystem.SaveReference saveReference, System.Boolean skipNameValidation) (at <fb74d2ff515d408a84b82347789206b3>:0)
Timberborn.GameSaveRuntimeSystem.GameSaver.SaveSkippingNameValidation (Timberborn.GameSaveRepositorySystem.SaveReference saveReference) (at <fb74d2ff515d408a84b82347789206b3>:0)
Timberborn.Autosaving.Autosaver.Save () (at <f8c572698f6a4f4180c2f26eaafcbd64>:0)
Timberborn.Autosaving.Autosaver.Update () (at <f8c572698f6a4f4180c2f26eaafcbd64>:0)

No slider bars for Time/Height

No slider bars are showing for the Time/Height basic options on floodgates, therefore cannot configure anything. All other water-related items that only have checkboxes seem to work as expected.
Floodgates are basegame 'standard' and not custom/extended floodgates. No other flood/water related mods are installed. Have tried uninstalling/reinstalling, and disabling all other mods except for TimberAPI/BepInExPack.

image

Feature Request: Before & After Delay

I had suggested this way back on the mod page, but I guess you don't use the mod page to see comments and such, so I'll re-post it here with additional detail and the new update.

I rather like the basic tab on your mod, its a decent way to have things run on the right schedule. However its too exact. There's no way to tell it to wait a bit, which will waste water or flood your base with poison.

I'd like a delay checkbox on items within the interface. Something that would let me assign how long before and after a drought or bad tide, the setting will activate. Set at every quarter day or so. I made a mockup of the idea. Actually I skipped the checkbox on the delay because if you leave it at default 0, then there'd be no delay anyway.

image

The max delay should be 3 days on either side of a drought/badtide, as thats how long the game gives you in notice of one anyway. Perhaps you could shrink it down to 2 days, to prevent conflicts when using hard difficulty as its droughts and tides start every 3 days.

I don't know if you still want the long text for the checkboxes, but there's plenty of space there.
The delay slider slides in two directions, middle being 0, left being negative (before) and right being positive (after). So a slider set to 0.5 will only activate the chosen height half a day after the event started/ended.

Crashing on game load with this as the only enabled mod other than dependencies with 11/13 Experimental Update

Crashing on game load with this as the only enabled mod other than dependencies with 11/13 Experimental Update

`[Message: BepInEx] BepInEx 5.4.22.0 - Timberborn (11/13/2023 9:14:39 AM)
[Info : BepInEx] Running under Unity v2023.1.18.2843550
[Info : BepInEx] CLR runtime version: 4.0.30319.42000
[Info : BepInEx] Supports SRE: True
[Info : BepInEx] System platform: Bits64, Windows
[Message: BepInEx] Preloader started
[Info : BepInEx] Loaded 1 patcher method from [BepInEx.Preloader 5.4.22.0]
[Info : BepInEx] 1 patcher plugin loaded
[Info : BepInEx] Patching [UnityEngine.CoreModule] with [BepInEx.Chainloader]
[Message: BepInEx] Preloader finished
[Message: BepInEx] Chainloader ready
[Message: BepInEx] Chainloader started
[Info : BepInEx] 2 plugins to load
[Info : BepInEx] Loading [Mod Manager UI 1.2.4]
[Info : BepInEx] Loading [TimberAPI BepInEx Entrypoint 1.0.0]
[Message: BepInEx] Chainloader startup complete
[Info : Unity Log] Starting game version 0.5.3.0-b1d2ff8-xsw
[Info : Unity Log] System info:
System: Windows 10 (10.0.19045) 64bit
CPU: Intel(R) Core(TM) i7-10700K CPU @ 3.80GHz
GPU: NVIDIA GeForce GTX 1060 6GB
GPU memory: 6043MB
RAM: 32658MB
Drives:
C:\ 178.68GB free from 464.68GB
D:\ 1774.50GB free from 1863.00GB
G:\ 12.63GB free from 15.00GB
W:\ 1023.98GB free from 1024.00GB
X:\ 294.66GB free from 931.50GB
Y:\ 20564.17GB free from 21208.26GB

[Info : Unity Log] Modded: true, BepInEx
[Info :TimberAPI Core] TimberAPI 0.6.2.1 - Timberborn 0.5.3.0, loader: BepInEx
[Info : TimberAPI] Mod loading started
[Info : TimberAPI] Found 1 mods
[Info : TimberAPI] Deserialized 1 mods
[Info :FloodgateTriggersPlugin] FloodgateTriggersPlugin is loaded.
[Info :FloodgateTriggersPlugin] Loaded version 4.0.4.0
[Info : TimberAPI] Mod loading finished in: 29ms, Loaded mods:1
[Info : TimberAPI] Added 1 prefixes
Setting breakpad minidump AppID = 1062090
SteamInternal_SetMinidumpSteamID: Caching Steam ID: 76561197998718878 [API loaded no]
[Info : Unity Log] Successfully connected to the Steam client.
[Info :Mod Manager UI] Loaded 29 custom labels
[Info : TimberAPI] Loaded 45 custom labels
[Info : TimberAPI] Assets loaded for MainMenu, Total prefixes loaded: 1
[Info : Unity Log] Previous resolution: 1920 x 1200
New resolution 1920 x 1200
Display resolution: 1920 x 1200
Full screen: True
Graphics quality: Ultra
Resolution scale: 1
[Warning: HarmonyX] AccessTools.Method: Could not find method for type Timberborn.ToolSystem.ToolButton and name OnButtonClicked and parameters
[Error : TimberAPI] Patcher TimberApi.ToolButton failed.
System.NullReferenceException: Null method for TimberApi.ToolButton
at HarmonyLib.PatchProcessor.Patch () [0x0001d] in <474744d65d8e460fa08cd5fd82b5d65f>:0
at HarmonyLib.Harmony.Patch (System.Reflection.MethodBase original, HarmonyLib.HarmonyMethod prefix, HarmonyLib.HarmonyMethod postfix, HarmonyLib.HarmonyMethod transpiler, HarmonyLib.HarmonyMethod finalizer, HarmonyLib.HarmonyMethod ilmanipulator) [0x00031] in <474744d65d8e460fa08cd5fd82b5d65f>:0
at HarmonyLib.Harmony.Patch (System.Reflection.MethodBase original, HarmonyLib.HarmonyMethod prefix, HarmonyLib.HarmonyMethod postfix, HarmonyLib.HarmonyMethod transpiler, HarmonyLib.HarmonyMethod finalizer) [0x00000] in <474744d65d8e460fa08cd5fd82b5d65f>:0
at TimberApi.BottomBarSystem.Patchers.ToolButtonPatcher.Apply (HarmonyLib.Harmony harmony) [0x00019] in <35cb4dad646f4fb4a4151c6d6208b7e3>:0
at TimberApi.HarmonyPatcherSystem.HarmonyPatcherActivator.PatchAll (System.Nullable1[T] scene) [0x0004b] in <35cb4dad646f4fb4a4151c6d6208b7e3>:0 [Warning: HarmonyX] AccessTools.Method: Could not find method for type Timberborn.ToolSystem.ToolGroupButton and name ContainsTool and parameters [Error : TimberAPI] Patcher TimberApi.ToolGroupButton failed. System.NullReferenceException: Null method for TimberApi.ToolGroupButton at HarmonyLib.PatchProcessor.Patch () [0x0001d] in <474744d65d8e460fa08cd5fd82b5d65f>:0 at HarmonyLib.Harmony.Patch (System.Reflection.MethodBase original, HarmonyLib.HarmonyMethod prefix, HarmonyLib.HarmonyMethod postfix, HarmonyLib.HarmonyMethod transpiler, HarmonyLib.HarmonyMethod finalizer, HarmonyLib.HarmonyMethod ilmanipulator) [0x00031] in <474744d65d8e460fa08cd5fd82b5d65f>:0 at HarmonyLib.Harmony.Patch (System.Reflection.MethodBase original, HarmonyLib.HarmonyMethod prefix, HarmonyLib.HarmonyMethod postfix, HarmonyLib.HarmonyMethod transpiler, HarmonyLib.HarmonyMethod finalizer) [0x00000] in <474744d65d8e460fa08cd5fd82b5d65f>:0 at TimberApi.BottomBarSystem.Patchers.ToolGroupButtonPatcher.Apply (HarmonyLib.Harmony harmony) [0x00019] in <35cb4dad646f4fb4a4151c6d6208b7e3>:0 at TimberApi.HarmonyPatcherSystem.HarmonyPatcherActivator.PatchAll (System.Nullable1[T] scene) [0x0004b] in <35cb4dad646f4fb4a4151c6d6208b7e3>:0
[Info : Console] Day in secs: 460
[Info : TimberAPI] Assets unloaded for MainMenu
[Info : TimberAPI] Assets loaded for InGame, Total prefixes loaded: 1
[Info : Unity Log] Loading saved game New Paddleby - 2023-11-13 01h07m, Day 13-12.autosave at 2023-11-13 09:24:33Z
[Info : Unity Log] Opening file: C:\Users\brian\Documents\Timberborn\ExperimentalSaves\New Paddleby\2023-11-13 01h07m, Day 13-12.autosave.timber
[Info : Unity Log] Previous resolution: 1920 x 1200
New resolution 1920 x 1200
Display resolution: 1920 x 1200
Full screen: True
Graphics quality: Ultra
Resolution scale: 1
[Error : Unity Log] MissingMethodException: Method not found: void Timberborn.ToolSystem.ToolGroupButton..ctor(Timberborn.Localization.ILoc,Timberborn.ToolSystem.ToolGroup,UnityEngine.UIElements.VisualElement,UnityEngine.UIElements.VisualElement,UnityEngine.UIElements.VisualElement)
Stack trace:
TimberApi.ToolGroupUISystem.ToolGroupButtonFactory.Create (Timberborn.ToolSystem.ToolGroup toolGroup, UnityEngine.Sprite toolGroupImage, System.String backgroundImage) (at <35cb4dad646f4fb4a4151c6d6208b7e3>:0)
TimberApi.ToolGroupUISystem.Factories.ToolGroupButtonGreenFactory.Create (TimberApi.ToolGroupSystem.IToolGroup toolGroup, Timberborn.ToolSystem.ToolGroupSpecification toolGroupSpecification) (at <35cb4dad646f4fb4a4151c6d6208b7e3>:0)
TimberApi.ToolGroupSystem.ToolGroupService.LateLoad () (at <35cb4dad646f4fb4a4151c6d6208b7e3>:0)
TimberApi.Core.SingletonSystem.SingletonSystemPatcher+<>c.b__5_0 (TimberApi.Common.SingletonSystem.ILateLoadableSingleton singleton) (at :0)
TimberApi.Core.SingletonSystem.SingletonSystemPatcher.LoadSingleton[T] (System.Collections.Generic.IEnumerable1[T] singletons, System.Action1[T] action) (at :0)
TimberApi.Core.SingletonSystem.SingletonSystemPatcher.LoadSingletonsPostfix (Timberborn.SingletonSystem.ISingletonRepository ____singletonRepository) (at :0)
(wrapper dynamic-method) Timberborn.SingletonSystem.SingletonLifecycleService.DMD<Timberborn.SingletonSystem.SingletonLifecycleService::LoadSingletons>(Timberborn.SingletonSystem.SingletonLifecycleService)
(wrapper dynamic-method) Timberborn.SingletonSystem.SingletonLifecycleService.DMD<Timberborn.SingletonSystem.SingletonLifecycleService::LoadAll>(Timberborn.SingletonSystem.SingletonLifecycleService)
Timberborn.SingletonSystem.SingletonLifecycleAdapter.Start () (at :0)

[Error : Unity Log] NullReferenceException: Object reference not set to an instance of an object
Stack trace:
Timberborn.CoreUI.PanelStack.Awake () (at <57dbc42f8805424f9f1e4467b243c7ae>:0)

[Info :Mod Manager UI] Loaded 29 custom labels
[Info : TimberAPI] Loaded 45 custom labels
[Info : Unity Log] Creating an error report: C:\Users\brian\Documents\Timberborn\Error reports\error-report-2023-11-13-09h24m37s.zip
[Info : Unity Log] Load time: 8187ms
[Error : Unity Log] NullReferenceException: Object reference not set to an instance of an object.
Stack trace:
UnityEngine.Component.get_gameObject () (at :0)
Timberborn.GameSound.GameMusicPlayer.PlaySound (System.String soundName, System.Action callback, System.Nullable`1[T] delay) (at <0906f1f79b2944b29d6626ba0d08a7da>:0)
Timberborn.GameSound.GameMusicPlayer.StartStandardMusic () (at <0906f1f79b2944b29d6626ba0d08a7da>:0)
Timberborn.GameSound.GameMusicPlayer.OnSceneLoaded (System.Object sender, System.EventArgs e) (at <0906f1f79b2944b29d6626ba0d08a7da>:0)
Timberborn.SceneLoading.SceneLoader+d__15.MoveNext () (at <26d28db235864b7184fa2cb9e07290d5>:0)
UnityEngine.SetupCoroutine.InvokeMoveNext (System.Collections.IEnumerator enumerator, System.IntPtr returnValueAddress) (at :0)

`

Crash in most recent experimental version

Mods used:
BepInExPack, TimberAPI, Simple Floodgate Triggers, Tiny Warehouse, More Platforms, Ladder

Recreation of the bug:
Playing without setting any triggers will not yield a crash. Setting a floodgate to trigger based on water level marker causes my game to crash within a few in-game days. Not entirely sure, but it also only crashed during a drought, this may be due to when I set the trigger or part of the bug.

Additional Information:
Possibly related, the floodgate I tried to set up does not affect adjacent floodgates regardless of whether sync was turned on. I tried turning sync off to see if it would no longer crash, this did not help. Also, I did not try any other trigger settings, as this is the one trigger I desire, although the bug may also be present with other trigger options

Stream Gauge level threshold can override contamination set points

For the floodgate in attached screenshot, I have set the gate to change it's state based on contamination of a gauge upstream, and only on contamination. However, If the below low contamination is set to 0, then the level seems to take over
Screenshot 2023-12-21 at 2 43 50 AM
What I want to happen:

set contamination = 0%
if contamination >= 1%
    set gate to height = 3%
else if contaminations <= 0
    set gate to height = 1

What appears to be happening using 0 for the low threshold and using the values I have set in the screenshot:

set contamination = 0%
if contamination >= 1% /// Evaluates false
    set gate to height = 3
if contamination is <= 0% /// Evaluates true, sets height to 1
    set gate to height = 1
if stream gauge >= high threshold /// Evaluates to true, sets height to 0
    set gate to 0
/// everything after this point sets height to 0

I think the quickest fix for this is the low and high thresholds should have their own on/off boxes.

Crash on Experimental Branch

Running the 21-07-2022 version of the experimental branch, and game crashes with the error below. Running normal mode, lightly modded. One stream gauge attached to 3 flood gates next to each other, but set to shut off at various lengths. Attaching a copy of the save file as well.

v0.2.2.1-b44bdea-xsw
ArgumentException: Can't serialize Hytone.Timberborn.Plugins.Floodgates.EntityAction.StreamGaugeFloodgateLink of type Hytone.Timberborn.Plugins.Floodgates.EntityAction.StreamGaugeFloodgateLink
Timberborn.WorldSerialization.PrimitiveTypeSerialization.Serialize (System.Object value) (at <aee47ec7978a4ebfb965970708fbaa52>:0)
Timberborn.WorldSerialization.ObjectSave.SetArray[T] (System.String name, T[] values) (at <aee47ec7978a4ebfb965970708fbaa52>:0)
Timberborn.Persistence.ObjectSaver.Set[T] (Timberborn.Persistence.ListKey`1[T] key, System.Collections.Generic.IReadOnlyCollection`1[T] values) (at <81093724205945d2bcf38adc918217d8>:0)
Hytone.Timberborn.Plugins.Floodgates.EntityAction.FloodgateTriggerMonoBehaviour.Save (Timberborn.Persistence.IEntitySaver entitySaver) (at <3a11c115c1b642cb8e72e426f63505d6>:0)
Timberborn.Persistence.WorldSaveFactory.SaveEntity (UnityEngine.GameObject gameObject, Timberborn.WorldSerialization.EntitySave output) (at <81093724205945d2bcf38adc918217d8>:0)
Timberborn.Persistence.WorldSaveFactory.SaveEntities (Timberborn.WorldSerialization.WorldSave worldSave) (at <81093724205945d2bcf38adc918217d8>:0)
Timberborn.Persistence.WorldSaveFactory.Create () (at <81093724205945d2bcf38adc918217d8>:0)
Timberborn.GameSaveRuntimeSystem.GameSaver.Save (Timberborn.GameSaveRepositorySystem.SaveReference saveReference, System.Boolean skipNameValidation) (at <fb74d2ff515d408a84b82347789206b3>:0)
Timberborn.GameSaveRuntimeSystem.GameSaver.SaveSkippingNameValidation (Timberborn.GameSaveRepositorySystem.SaveReference saveReference) (at <fb74d2ff515d408a84b82347789206b3>:0)
Timberborn.Autosaving.Autosaver.Save () (at <f8c572698f6a4f4180c2f26eaafcbd64>:0)
Timberborn.Autosaving.Autosaver.Update () (at <f8c572698f6a4f4180c2f26eaafcbd64>:0)

Timberborn_ExperimentalSaves_Alhambra_2022-08-01 11h49m, Day 26-4.autosave.zip

Automation for water pumps and other stuff for v2

Issue to keep track of ideas of what automation settings to add for water pumps and dumps

  • Pause/Unpause when drought starts/ends
  • Pause/Unpause based on height on a stream gauge
  • Pause/Unpause on a schedule
  • Pause/Unpause based on district or water storage water count? (Have to think about this)

other stuff:

  • Add separate streamgauge settings for both drought and temperate (maybe not)
  • Add little delay to height change of floodgate (so it looks better going from 0 to 100)

Optimization?

I'm not sure about how your code works, but the freezing issue between start and end events is really annoying. I'm not sure exactly how your mod checks through objects in the lists for these triggers. So I wanted to offer up some thoughts I had just in case it hadn't been considered.

A friend of mine checked and said you've already optimized, but it feels like whenever a drought ends or begins, a check is being run on every single building that has the ability to set a trigger in it. The more buildings I have that have trigger capabilities, the more lag I get on these events.

If the above is whats going on, I'd like to suggest creating separate lists. Only a building that has any option checked in it that would indicate its for the start of a drought, would be added to the list "startdrought", and similar lists for all the other events. So if my pumps are all unconfigured, no options checked, there's no reason for the mod to run a check on them at the start of a drought or end of a drought, right?

I'm somewhere around cycle 56, and building more floodgates, trying to use them to make the flow more dynamic and automated, having lots of difficulties due to certain limitations of the mod. However the more I build, even when not using drought start or tide start triggers, the more lag I get wen these events happen.

If you've already considered this or done this type of optimization, then great. I just wish to try and solve the lag spikes once and for all because they are causing me a lot of difficulty when I'm working on things around the start or end of a cycle.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.