[Rseding91] Research progress >100% issue

This subforum contains all the issues which we already resolved.
Post Reply
User avatar
bobingabout
Smart Inserter
Smart Inserter
Posts: 7352
Joined: Fri May 09, 2014 1:01 pm
Contact:

[Rseding91] Research progress >100% issue

Post by bobingabout »

I got this report.
viewtopic.php?f=51&t=31718&start=30#p201886

I don't know how it happened... I listed my code a couple posts later, all it does is store the progress reported by the LUA script, and restore it if you change back. So the game itself had to have research going past 100% in the first place for my mod to attempt to restore it. Someone theorises a mod changing the cost of a technology down while it is already in progress in a save file...

Anyway, Wouldn't it be a relatively simple fix to change your game code to use a >= check for this?
Creator of Bob's mods. Expanding your gameplay since version 0.9.8.
I also have a Patreon.

Rseding91
Factorio Staff
Factorio Staff
Posts: 13204
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: Research progress >100% issue

Post by Rseding91 »

bobingabout wrote:Anyway, Wouldn't it be a relatively simple fix to change your game code to use a >= check for this?
I'm not sure what you mean. There's already a > check in place - that's why you get the error when attempting to set the research to > 1.

As for why you got a value > 1 - it's probably as you said: someone changed the technology prototype while it was in progress. I'll add a check during loading that correct the research progress if someone changes the research prototype while research is in progress so it shouldn't ever give a value > 1.
If you want to get ahold of me I'm almost always on Discord.

Rseding91
Factorio Staff
Factorio Staff
Posts: 13204
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: [Rseding91] Research progress >100% issue

Post by Rseding91 »

Fixed for 0.14.4.
If you want to get ahold of me I'm almost always on Discord.

Digital_Cake_
Inserter
Inserter
Posts: 22
Joined: Thu Aug 04, 2016 4:33 am
Contact:

Re: [Rseding91] Research progress >100% issue

Post by Digital_Cake_ »

Super glad this was fixed, I've suffered the same problem for quite some time and I'm glad to see it finally getting fixed..
-Cake

User avatar
bobingabout
Smart Inserter
Smart Inserter
Posts: 7352
Joined: Fri May 09, 2014 1:01 pm
Contact:

Re: [Rseding91] Research progress >100% issue

Post by bobingabout »

Wonderful.

I've written a fix for my mod as well, so it should never attempt to write >1 too.
Creator of Bob's mods. Expanding your gameplay since version 0.9.8.
I also have a Patreon.

Post Reply

Return to “Resolved Problems and Bugs”