Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
Tags

Autonauts

Make and teach robots to automate the world! · By Denki

Autonauts take half an hour to load

A topic by gmrose9 created Jul 27, 2018 Views: 650 Replies: 1
Viewing posts 1 to 2

Does Autonauts take half an hour to load for you?  Do you want to know why?  Do you want to know how to fix it?

Did you start making bots that would cut down trees and bots that would dig tree seed holes and bots that would plant tree seeds in the holes?  Was everything working great for a long time?

Did you decide to build a super-tall pile of something that just got higher and higher?

Did you start growing cereal and then got bots to cut down the cereal, and bots that would put the cereal in threshing machines that made cereal seeds and straw, and bots that hoed the ground and other bots that planted the cereal seeds?  Did all that left-over straw become another super-tall pile?

Then after all of the great work that you did, and after you would save your game at the end of each day, and you would load the game at the start of the next day, did the game start to take longer and longer to load until you just couldn’t wait any longer for the load to finish?  Did you decide that the game must be broken?  Did you decide that your save must be broken, so you gave up on that save and started the game over again from the very beginning?

I can tell you what the problem really was and how you could get your game to load an old save again and how to make your saves take much less time to load.

The problem is the size of your save file.  If your save file has a size of about  2,700 KB or less, the file size is okay and that file will load in a reasonable amount of time.  If your save file instead has a size of about 3,400 KB or more, the file size is too large and that file could take half an hour to load.

But what makes the save files become so large?  The fault is those super-tall piles.  Every item in the game, from the first tool you created to the last piece of straw at the top of one pile to the highest dung in your dung pile, will appear in the save file with a list of information that might look something like {"ID":"Straw","UID":1537101,"TX":185,"TY":74}.  If you have a super-tall pile of straw, each straw object will appear in the save file with a list as long as that one.  I once had a save file that had nearly 20,000 straw objects in its super-tall pile and that file had a size of almost 3,500 KB, which took more than half an hour to load.

What should you do to prevent the save file from becoming so large that you can’t enjoy the game because of its load time?  The answer is one word: Incinerator.  You must forget about building those super-tall piles.  You must instead put all of the straw that you have not put into storage bins (for making hats or making bricks) into the Incinerator.  Any item that is put into the Incinerator will be deleted from the game and so will not take up space in the save file.  You will need to create bots that will take unneeded straw from the pile at the output of every threshing machine and put it into the Incinerator.

What should you do about that save file for your great game that you had before it started to take too much time to load?  If you have another smaller save taken before the one that would not load quickly, load the smaller save file instead.

Use Microsoft File Explorer in Windows to look in the folder that contains your regular save files.  You will see that each file shown has a Name, a Date Modified, a Type, and a Size.  The save files all have a Type of “Text Document” because they all have an extension of “.txt”.  When you look at the save file that takes too long to load and you see that its Size is too large, you should notice its Date Modified. 

For example, as shown below, my large Save file that took too long to load has a Name of “Save112617.txt”.  Its Size is 3,490 KB and its Date Modified is 11/26/2017 7:25 PM.  I have a smaller file that has a Name of “Save112517.txt” with a Size of 2,940 KB and a Date Modified of 11/25/2017 4:25 AM.  I was able to load this smaller file after the large file became a problem to load.  I only lost about a day and a half of time between the two saves.

But what could you do if you don’t have a smaller file that you had saved before the larger save file that was a problem?  The answer is: Autosave files.  As the Autonauts game runs, you see a piggy bank appear in the lower right corner of the game about every 10 minutes.  The piggy bank indicates that an Autosave file is being created at that time automatically.

Use Microsoft File Explorer in Windows to look in the folder named “Autosaves” that appears inside the folder that contains the Autonauts.exe file.  If you click on the column heading Date Modified, the files will be sorted by those dates.  Scroll down to the files that have Dates Modified that are before the Date Modified of the large save file with the problem.  Look for a file with a size that is less than about 3,000 KB.  In my Autosaves folder is a file with the Name of “Autosave_25-11-2017_04-23-49.txt” that has a Date Modified of 11/25/2017 4:23 AM and a Size of 2,938 KB.  Copy your similar Autosave file and paste it into the folder with your regular Save files.  Then in the Autonauts game, Load this file.  The file should load in a reasonable amount of time and you can again play the game. 

Next, be sure to build the Incinerator and get rid of those super-tall piles that caused the problem.

I thought about editing my previous save to do just that, but since I was already starting from a new save anyways for streaming purposes, I decided to keep that in mind for future progress in the game. The Incinerator is useful for getting rid of temporary or already existing stacks of items. I found it is better to not use a runoff (a single large stack of items) which I had in my previous build and instead opt for stopping production when storage is full. In this case, the more storage you add, the larger the buffer. In short, it is better to make items as quickly as possible instead of stockpiling them or risk your save file not loading at all. I think I remember mentioning this in my vid.