W| Alpha 2 and 3 / Resources being stacked double

Started by Geeves, April 11, 2014, 05:02:04 PM

Previous topic - Next topic

Geeves

Version Found - W| Alpha 2 and 3

Title - Resources being stacked double.

Summary - During the Alpha 2 release I noticed my Phoebe storyteller colony had my colonist stack items twice or thrice on the same spot.
The resource counters in the top left do have accurate numbers, even though some stacks are double or triple.


Steps to Reproduce -
1. I started a Phoebe Friendly game, picked my colonists, and set the map size to maximum.
2. Play the game, have colonists gather resources, build things, ect.

Steps to dodge out of double stacking -
1. I moved stockpiles around, placed launchpads.
2. I changed what the stockpiles where allowed to have.

Expected Results - Expected results where that the resources where no longer being double stacked.
It did not happen, either directly or after a short while (game speed 3 short while) the resources where being double stacked again.

Notes - The debris, corpses and weapons preformed as expected, 1 of them is 1 stack and needs 1 space.
The other resources like metal, stone, potatoes, silver, ect had double stacking problems.

Attachments - I've added 3 saves to this report for others to check view and maybe find what actually causes the double stacking.
Saves 1 and 2 (StoneLog and Alpha 2 PF Stonelog) are from Alpha 2, StoneLog is the earliest version in which I found out that resources where double stacked.
Alpha 2 PF Stonelog is the later in the game version of the same save game.
PF Stands for Phoebe Friendly and Stonelog is the name of the colony.
Save 3 is from Alpha 3. Here too I noticed resources where stacked over and on top of each other.

I wanted to add 3 saves, 1 from Alpha 3 and 2 from Alpha 2 (one advanced and one early on) but the file sizes are about 10 times the allowed size each.
If the files are still wanted, drop me a line at twitter @L_Geeves and we will handle it from there. It will be the quickest way to get a reaction from me.

Best of luck finding the problem, and solving it.

May this game go forward a long, long ways.

- - Geeves

[attachment deleted by admin: too old]
You know it is bedtime when you open a file called GeneralEffecters.xml and the first 2 words you notice are: Butcher and Children.
==============
Learning to program is easy. Learning to put what is in your mind into programming code, now that is the hard part.

Tynan

Can you be any more specific with the repro steps? Savegames would be useful, if they are saved a few seconds before the erroneous double-stacking happens. Got any of those?
Tynan Sylvester - @TynanSylvester - Tynan's Blog

Geeves

On the save games -
I made a new game, saved it from the start. Note the silver stack in the bottom left of the stockpile, Colonist Enid will gather more silver and stack it on top of the current stack. Turning the number from 358 to 200. The counter in the top left tells me that the bottom stack has not been removed but a new stack was made on top of it.
The file was zipped using 7Zip.


On the reproductive steps, I started the game as normal:

  • I selected Phoebe Friendly, for the long game play she offers by not letting your colony be overrun in 20 days.
  • I picked 3 colonists that I liked, though their skills do not seem to make a difference as far as I can tell, I have different colonists in Alpha 3 as to those I had in Alpha 2.
  • Then I selected the largest size world available in the advanced options. Current maximum size: 300 x 300
  • And started the game.
  • I removed the basic stockpiles and set out my own area, no dumping site was made.


This is the Alpha 3 game play version. The screenshot of my last post was of Alpha 2.

[attachment deleted by admin: too old]
You know it is bedtime when you open a file called GeneralEffecters.xml and the first 2 words you notice are: Butcher and Children.
==============
Learning to program is easy. Learning to put what is in your mind into programming code, now that is the hard part.

Tynan

Tynan Sylvester - @TynanSylvester - Tynan's Blog

Peacekeep3r777

#4
Happens to me as well, but only around Drop beacon area.


[attachment deleted by admin: too old]

Dr. Z

Happens to me all the time, e.g. I had a 6-squares emergency stockpile for metal and there where like 700 metal in it so i found out. Can't really tell a specific trigger it just happens :(
Prasie the Squirrel!

Tynan

If anyone can determine a specific trigger that'd be great. Something must cause it. In a simple test, they stack things properly.
Tynan Sylvester - @TynanSylvester - Tynan's Blog

Dr. Z

Could it occur when you have multiple stockpiles which can hold the same.

It's just a guess but in my case, I build a stockpile only allowed to hold metal at the end of my emergency exit, after I already build a stockpile for resources at the beginning, and this was the first time I recognized this.
Prasie the Squirrel!

Pirx Danford

I have that all the time with all resources independent from only one or multiple zones able to receive the resource.
For me it looks like a pawn that searches for a spot to put his freight only checks if the target area is completely full when he picks up his load.
So a spot is being used multiple times if its either not used by a full stack or when multiple pawns select the same empty spot to put stacks.

My approach for this would be to have the pawns approach the best spot with 3 steps:
0) Pick up freight, if carried stack is not full find more of the same stuff close by.
1) Locate closest zone with highest priority and free or not completely full spots.
1a) If carried stack is still not full, check again if more of the same stuff is nearby within the radius of 25% of distance to the found zone (current pawn position as center).
1b) Plot way not to the next free spot on found zone but to closest edge of found zone and move there.
2) On arrival at the edge search for closest not completely full spot and move there.
2a) If no spot is free anymore return to step 1.
3) On arrival at the spot only fill it to maximal allowed stack size.
3a) If there is a stack already fill that one up.
3b) If the current spot could not hold all of the stuff, return to step 2 to find a new spot.

This still leaves a possible situation where 2 pawns might try to interact with the same stack at the same time.
Maybe this could be prevented by a pawn locking the stack while in use.

Geeves

Having played around a bit more it seems to only happen when they are bringing resources to the stockpile and the stack they are holding is more then the stack they are trying to fill.

In numbers:
Stockpile square 1 holds 52 Metal, colonist is hauling 75 metal, fills square 1 to 75, and then dumps the remaining 52 metal on the same square, thinking it is empty.

I have not seen them double stack when what they are holding is less then the stacks maximum (75 for metal in this case).
You know it is bedtime when you open a file called GeneralEffecters.xml and the first 2 words you notice are: Butcher and Children.
==============
Learning to program is easy. Learning to put what is in your mind into programming code, now that is the hard part.

Peacekeep3r777

I see the problem in stacks - if there is not a full stack, they will just bring more resources to it. So there is many layers of resources, which dont have a full stack.

Tynan

Quote from: Geeves on April 13, 2014, 06:18:51 AM
Having played around a bit more it seems to only happen when they are bringing resources to the stockpile and the stack they are holding is more then the stack they are trying to fill.

In numbers:
Stockpile square 1 holds 52 Metal, colonist is hauling 75 metal, fills square 1 to 75, and then dumps the remaining 52 metal on the same square, thinking it is empty.

I have not seen them double stack when what they are holding is less then the stacks maximum (75 for metal in this case).

Thanks, I'll look into this.
Tynan Sylvester - @TynanSylvester - Tynan's Blog