Friday Facts #82 - Optimisations

Regular reports on Factorio development.
kovarex
Factorio Staff
Factorio Staff
Posts: 8078
Joined: Wed Feb 06, 2013 12:00 am
Contact:

Friday Facts #82 - Optimisations

Post by kovarex »

Did you ever wonder what optimisations are we working on? No? I will tell you anyway :) https://www.factorio.com/blog/post/fff-82

User avatar
Smarty
Global Moderator
Global Moderator
Posts: 816
Joined: Sat Oct 04, 2014 5:00 pm
Contact:

Re: Friday Facts #82 Optimisations

Post by Smarty »

Looks like there is a solid plan for 0.12

cant wait

vegeta897
Burner Inserter
Burner Inserter
Posts: 7
Joined: Sat May 10, 2014 4:01 am
Contact:

Re: Friday Facts #82 Optimisations

Post by vegeta897 »

Tomas is working on the lag hiding and it seems to have nice results, you can expect detailed description of it in the next fff.
Does this mean things like movement will be rendered client-side instantly before actually being simulated? Thus making playing with 200ms ping not feel so delayed?

Yaua
Long Handed Inserter
Long Handed Inserter
Posts: 63
Joined: Thu Jan 22, 2015 4:26 pm
Contact:

Re: Friday Facts #82 Optimisations

Post by Yaua »

Congratulation for the stable version :D Kudos to all the team who is doing a great job ! I'm waiting so much to see the 0.12 branch !
And I'm really happy to see that you're working on more optimization and planning to do even more.

Now, I have some small questions :
1) When you talk about "Steam integration", what kind of things will this be ? I assume it won't affect in any way people who don't use steam at all ?
2) About optimization, I don't understand the "time reduction" thing : "The overall optimization of this change was roughly 20% time reduction on the testing factory.". Can I have a very short explanation ?

FishSandwich
Smart Inserter
Smart Inserter
Posts: 1847
Joined: Sun Feb 23, 2014 3:37 pm
Contact:

Re: Friday Facts #82 Optimisations

Post by FishSandwich »

Yaua wrote:1) When you talk about "Steam integration", what kind of things will this be ? I assume it won't affect in any way people who don't use steam at all ?
Going to steam has always been the plan afaik. It just means anyone that already owns the game will get a steam code for it, and steam users can buy the code there. If you don't want to use the steam code that's your choice, the installer will still be available on their site.

Yaua
Long Handed Inserter
Long Handed Inserter
Posts: 63
Joined: Thu Jan 22, 2015 4:26 pm
Contact:

Re: Friday Facts #82 Optimisations

Post by Yaua »

FishSandwich wrote:
Yaua wrote:1) When you talk about "Steam integration", what kind of things will this be ? I assume it won't affect in any way people who don't use steam at all ?
Going to steam has always been the plan afaik. It just means anyone that already owns the game will get a steam code for it, and steam users can buy the code there. If you don't want to use the steam code that's your choice, the installer will still be available on their site.
Oh, I understood it was about "Steam integration" inside the game XD So sorry for the unrelevant question :P

But thanks for your answer ;) (and for developing team for giving us the choice)
Last edited by Yaua on Fri Apr 17, 2015 9:34 pm, edited 1 time in total.

kovarex
Factorio Staff
Factorio Staff
Posts: 8078
Joined: Wed Feb 06, 2013 12:00 am
Contact:

Re: Friday Facts #82 Optimisations

Post by kovarex »

vegeta897 wrote:
Tomas is working on the lag hiding and it seems to have nice results, you can expect detailed description of it in the next fff.
Does this mean things like movement will be rendered client-side instantly before actually being simulated? Thus making playing with 200ms ping not feel so delayed?
Exactly. Most of the time, your actions don't conflict with others so they will match with the simulation so you don't feel delayed.
Yaua wrote: Now, I have some small questions :
1) When you talk about "Steam integration", what kind of things will this be ? I assume it won't affect in any way people who don't use steam at all ?
It basically means getting to steam. We will always keep the independence, so you can download the client without steam if you want.
Yaua wrote: 2) About optimization, I don't understand the "time reduction" thing : "The overall optimization of this change was roughly 20% time reduction on the testing factory.". Can I have a very short explanation ?
When the simulation of the factory and one tick took 10ms, it will be 8ms after the optimisations took place.

vegeta897
Burner Inserter
Burner Inserter
Posts: 7
Joined: Sat May 10, 2014 4:01 am
Contact:

Re: Friday Facts #82 Optimisations

Post by vegeta897 »

kovarex wrote:actions don't conflict with others so they will match with the simulation so you don't feel delayed.
That's awesome news! I really did not have any hope that this would be addressed, since most RTS-style games do not bother (age of empires, rise of nations... and those are big budget titles and the problem persists in the HD remasters!)
Yaua wrote: 2) About optimization, I don't understand the "time reduction" thing : "The overall optimization of this change was roughly 20% time reduction on the testing factory.". Can I have a very short explanation ?
Games are simulated in a series of "steps", usually dozens per second. In each step (or "update") the necessary calculations are run to advance time in the game. The more calculations that need to be done, the longer it takes to simulate each step, thus reducing performance and making your game choppy. Their optimization caused the time it takes to run a single step of the simulation to reduce by 20%. That means the game can simulate 25% more steps every second.
Last edited by vegeta897 on Fri Apr 17, 2015 9:35 pm, edited 1 time in total.

kovarex
Factorio Staff
Factorio Staff
Posts: 8078
Joined: Wed Feb 06, 2013 12:00 am
Contact:

Re: Friday Facts #82 Optimisations

Post by kovarex »

vegeta897 wrote:
Yaua wrote: 2) About optimization, I don't understand the "time reduction" thing : "The overall optimization of this change was roughly 20% time reduction on the testing factory.". Can I have a very short explanation ?
Games are simulated in a series of "steps", usually dozens per second. In each step (or "update") the necessary calculations are run to advance time in the game. The more calculations that need to be done, the longer it takes to simulate each step, thus reducing performance and making your game choppy. Their optimization caused the time it takes to run a single step of the simulation to reduce by 20%. That means the game can simulate 20% more steps every second.
That is right, but just small correction: When the time is reduced to 80%, you can actually run 25% more steps every second :) (When the time is reduced by 50%, you have 200% more steps).

vegeta897
Burner Inserter
Burner Inserter
Posts: 7
Joined: Sat May 10, 2014 4:01 am
Contact:

Re: Friday Facts #82 Optimisations

Post by vegeta897 »

kovarex wrote: That is right, but just small correction: When the time is reduced to 80%, you can actually run 25% more steps every second :) (When the time is reduced by 50%, you have 200% more steps).
Haha, just noticed that myself and fixed it, then saw your post :P

Flandere
Manual Inserter
Manual Inserter
Posts: 1
Joined: Sat Dec 13, 2014 3:13 pm
Contact:

Re: Friday Facts #82 Optimisations

Post by Flandere »

Stable \o/
Last edited by Flandere on Sun Aug 02, 2015 9:44 am, edited 1 time in total.

Yaua
Long Handed Inserter
Long Handed Inserter
Posts: 63
Joined: Thu Jan 22, 2015 4:26 pm
Contact:

Re: Friday Facts #82 Optimisations

Post by Yaua »

vegeta897 wrote:
Yaua wrote: 2) About optimization, I don't understand the "time reduction" thing : "The overall optimization of this change was roughly 20% time reduction on the testing factory.". Can I have a very short explanation ?
Games are simulated in a series of "steps", usually dozens per second. In each step (or "update") the necessary calculations are run to advance time in the game. The more calculations that need to be done, the longer it takes to simulate each step, thus reducing performance and making your game choppy. Their optimization caused the time it takes to run a single step of the simulation to reduce by 20%. That means the game can simulate 25% more steps every second.
Ok ! I fully understand now :) Thank you for the explanation !
kovarex wrote:
Yaua wrote: Now, I have some small questions :
1) When you talk about "Steam integration", what kind of things will this be ? I assume it won't affect in any way people who don't use steam at all ?
It basically means getting to steam. We will always keep the independence, so you can download the client without steam if you want.
Yaua wrote: 2) About optimization, I don't understand the "time reduction" thing : "The overall optimization of this change was roughly 20% time reduction on the testing factory.". Can I have a very short explanation ?
When the simulation of the factory and one tick took 10ms, it will be 8ms after the optimisations took place.
It's great to have the choice of not using steam, thanks a lot for this.
Thanks for your answers :)

But I have another "technical" question : with your new way to consider objects on transport belt, won't this be problematic when another belt adds objects in it for example ? How does it work ? (if it's too long to explain, don't waste your time, it's only for my curiosity ;))
Last edited by Yaua on Fri Apr 17, 2015 9:45 pm, edited 3 times in total.

Shaymes
Fast Inserter
Fast Inserter
Posts: 215
Joined: Thu May 22, 2014 8:06 am
Contact:

Re: Friday Facts #82 Optimisations

Post by Shaymes »

we still need a color select in options to chance player color for silngle/multiplayer
Mining Drill Operator

Albert
Factorio Staff
Factorio Staff
Posts: 55
Joined: Tue Apr 09, 2013 5:35 pm
Contact:

Re: Friday Facts #82 Optimisations

Post by Albert »

Shaymes wrote:we still need a color select in options to chance player color for silngle/multiplayer
Yesss!,
I use to dream with a color picker wheel with a real-time render preview of the chosen color on the player rotating in a turntable style.
EDIT: only in my most wet Factorio dreams

dee-
Filter Inserter
Filter Inserter
Posts: 414
Joined: Mon Jan 19, 2015 9:21 am
Contact:

Re: Friday Facts #82 Optimisations

Post by dee- »

Still looking forward for the new belt logic.
There sure will be funny corner cases like dropped items that get a belt build under them (has to be removed from the map, virtualized and allocated to a lane), etc. I suppose three items parallel on a belt belt aren't possible anymore then? Are inner and outer lanes still at different speeds? I still wonder why this only yields a meager 20% gain as the complete collision box logic was trashed and replaced by a 1-dimensional distance field, which is also constant as items in relation to each other won't accelerate or decellerate (minus disturbations like adding/removing items from the belt, belt operations, etc.) So I think there's still potential left after the belt logic has been simplificied.
I'm curious how the multiplayer not-sync-locked-mode will work out...

keyboardhack
Filter Inserter
Filter Inserter
Posts: 478
Joined: Sat Aug 23, 2014 11:43 pm
Contact:

Re: Friday Facts #82 Optimisations

Post by keyboardhack »

That's some awesome optimizations you got there. Optimizations will always be my favorite kind of updates so i am really looking forward to these awesome changes :D Especially the one with the solar panels!
Waste of bytes : P

Artman40
Fast Inserter
Fast Inserter
Posts: 168
Joined: Sun May 25, 2014 4:44 am
Contact:

Re: Friday Facts #82 Optimisations

Post by Artman40 »

Would it be possible for storage tanks to be at least partly transparent so you could see how filled they are without hovering a mouse over them?

User avatar
bigyihsuan
Filter Inserter
Filter Inserter
Posts: 299
Joined: Thu Jan 01, 2015 12:57 pm
Contact:

Re: Friday Facts #82 Optimisations

Post by bigyihsuan »

Artman40 wrote:Would it be possible for storage tanks to be at least partly transparent so you could see how filled they are without hovering a mouse over them?
Yes! Maybe a glass window in the side that fills with the liquid level.

User avatar
Ohz
Fast Inserter
Fast Inserter
Posts: 187
Joined: Tue Feb 03, 2015 11:40 am
Contact:

Re: Friday Facts #82 Optimisations

Post by Ohz »

Update time
Yep, basically if I want reduce lag pics when my factory is getting big, I remove smoke.
I'm not english, sorry for my mistakes

immibis
Filter Inserter
Filter Inserter
Posts: 303
Joined: Sun Mar 24, 2013 2:25 am
Contact:

Re: Friday Facts #82 Optimisations

Post by immibis »

Could the "middle lane" be re-added with the new belt system? It seems a lot more natural than having all the items move to one side for no reason.

Post Reply

Return to “News”