AI shutdown issues

I wana say off the bat, This doesnt seem like the same issue as we’ve seen in previous builds (Named the Campfire idle bug)

i find myself in my current game playing happily along and occasionaly, jobs will stop being done, Hauling will not happen anymore (eventhough there’s plenty of storage options for them to deposit items in the world) etc.

a quick save -> Reload will fix this issue, but it’s not been rooted out for sure.

i’m Currently at 26 hearthlings on the latest unstable build (R866)
with the following mods (Brace yourself)
TMD Templates
Archipelago biome
Autoharvest
Better Storage (maybe needs to become not a mod at some point)
Crafter Queues
Footman Power Strike Rebalance
Green mesa biome
Sacred Grove Biome
Hearthlings of many faces
Important mood
Stonehearth Doorways
Locks of many hair (no colors)
Mina’s Architecture Templates
Miner Profession
Poulty farm template
Rivers
Settlement Decor
Smart Crafter
World map size 160

The save is here if you want to see if there’s a root problem that just shapes itself like a timebomb to make such issues happen. i do not play with 3speed 95% of the time), i actually play on 1 speed most of the time to give the game time to cope and decide AI actions
1530293454673.rar (6.5 MB)

Please ask me any questions you think are usefull for your investigations into these issues!
(i think i played about 3-4 hours today, with 6-7 reloads~ total)

1 Like

Thanks for reporting this and offering to help! The file in your post appears to be corrupted. Can you reupload it please? I’ve tried to reproduce the issue on a number of savefiles with no luck. If you encounter it again, the following would help us debug it:

  • Pause the game, ensure that the performance indicator in the bottom right turns mostly light green (idle), then set it to speed 1.
  • If that doesn’t fix it, select any hearthling and run the following commands in the Lua console (the blue > debug tool), then post the results here.
    • stonehearth.inventory:get_inventory(e:get_player_id()):get_restock_director('restock')._errands
    • stonehearth.inventory:get_inventory(e:get_player_id()):get_restock_director('restock')._failed_items
    • stonehearth.inventory:get_inventory(e:get_player_id()):get_restock_director('restock')._restockable_items_queue:get_size()
    • stonehearth.inventory:get_inventory(e:get_player_id()):get_restock_director('input_bin')._errands
  • Select a hearthling who you think should be restocking but isn’t. Click on the AI debug tool (this may take a while to load). In the top right search box, type execute_restock_errand, and scroll to the line highlighted in light purple (see example below). Take a screenshot and post it here.
    image
1 Like

I inted to play today for a while, so ill let you know when it happens, execute the instructions and share the results.

Here’s the reupload (cuz you said the uploaded file was corrupt?)1530612976011.rar (6.3 MB)

@max99x

So i’m having trouble following your instructions i think, So i selected Lorn Wester, a proud Happy-villian.
(you can see alot of hearthlings have decided to follow suit in his behavior)

When i type Execute_restock_errand in the searchbox of the ai debugger, alot of diffrent sections light up purple (Including the chilling around the hearth one at the very top that is also in green = Running)

this is about an hour or 2 into playing today.
if you need me to find specific lines or something ill do my best, but i’ve not used your guys’ debugging tools be4 ^^

Here’s the save again, at the time im making these readings
Saved paused at the debugging time.rar (6.8 MB)

1 Like

From the console on the left, can you select all the text and post it here? For the AI inspector on the right, some sections will be highlighted in light purple instead of dark purple - those are the ones that matter.

i might’ve beansed it, cuz i reloaded cuz i wanted to continue on the save, i already notice 2 diffrences

The left console (The first command last time yielded no result at all ( { } ) ) and now it does.

And from memory ( i’m very sorry) there was no light purple sections in the right hand console, only dark purple, and non-tinted lines.

also, i can’t copy anything from the left hand console, Ctrl + C opens up the command thing at the top.
scratch that, it does copy, but it only copies the last command you told me to put in there without any result in the copy mind you.

1 Like

THIS IS FROM IMMEDIATLY AFTER THE RELOAD AFTER HAVING IT ON 1 SPEED 5 SECONDS~

i’m sorry for replying so much, i panicked a little cuz i think i fucked up the debugging process for you

Thanks for the help! That first screenshot did give me a lead, so see if this still happens in the next release.

1 Like

Okay, Last reply i promise @max99x

after my last post i continued play. i noticed stuff was lieng around and people were partying at the campfire during the day again.

The left console:
i cant copy paste all of it, cuz it doesn’t copy all of it.
-Command 1 (stonehearth.inventory:get_inventory(e:get_player_id()):get_restock_director(‘restock’)._errands)



(Does this like 4 times)

-Command 2
a list of hundreds of thousands of items listed here under diffrent numbers.

-Command 3 & 4

RIGHT HAND CONSOLE:
i found 2 light purple highlighted areas.


This is about half an hour since i reloaded, and posted here. i hope this was more along the lines of what you were looking for.

identical events since both reloads.
I’ve rallied the town every time invaders appeared, and i’ve capped on town items and sold off a bunch of items to make room (at the time of these readings i’m at 3.6k out of 3.9k

I’m leaving my game paused in it’s current state without reloading incase you got more instructions for me

Yeah, based on that info I think this should be fixed in the next version. I want to test it out on one of your savefiles, but unfortunately, all the ones in this thread fail to open in WinRAR. Can you try compressing them into a ZIP instead?

1 Like

a zip of the save at the current time as requested.zip (9.6 MB)

let me know if i can continue play, or if you’d like me to leave it paused for a little bit incase you need me to do something else.

1 Like

Yup, that worked. Thanks! I’ll look into it.

1 Like

After validation, please confirm if this is indeed fixed for next build. :slight_smile:

I’ve added a bunch more robustness improvements to the system for the next release, but in the case of your savegame, after running it for a day, there’s simply no more storage that accepts wheat/silkweed, so your fields are still filled with those. If you add a stockpile, they immediately get to hauling.

thats fine, i just mass sold those every trader that came by.

and everytime i recorded the error, i checked wether towninventory was full or not, and if it was, sold off a bunch of stuff mainly silkweed and wheat, cuz i accumulated those the quickest. and i didnt report times where my town inventory was obviously full with 500 things lieng on the floor.