[A 0.15.16] Terrible Multiplayer FPS for no apparent reason?

Bugs that are actually features.
GenBOOM
Long Handed Inserter
Long Handed Inserter
Posts: 95
Joined: Tue May 16, 2017 11:39 pm
Contact:

[A 0.15.16] Terrible Multiplayer FPS for no apparent reason?

Post by GenBOOM »

So I've tried everything I can think of and this is always the result on servers that have a lot going on
Multiplayer lowest settings zoomed in with and without vsync fullscreen or not doesnt matter the result is the same
Interesting thing I noticed looking at this is that the fps from steam does not match the in game fps counter at all, though this may just be because steams fps only updates 1/s?
Single player max settings zoomed out with fast vsync
Need any other info let me know.

Interesting screenshot I managed to capture, first time seeing this
although this may be the result of me trying to troubleshoot this problem. I deleted the "blueprint-storage.dat" in the "%appdata%/Factorio" folder but replaced it again before getting this screenshot
the idea I had was to somehow clear the cache of my blueprints so that I do not have the window pop up due to it remember the last time I was on the server I had it open. having hte window open means I am pre-rendered into the game at 6fps and inputs do not go through properly so it becomes impossible to get out of the blueprint window. additionally when pressing B to close the blueprint window, if you are lagging the game seems to duplicate this command and send press B down the nB up then B down again, so the window continually flashes open and closed. if the time it is closed is great enough your fps will increase and the commands will be receive properly again, only sending B down B up once and getting you out of this never ending loop of frustration.
duplicated blueprints
Attachments
testing fps.zip
(38.19 MiB) Downloaded 109 times
DxDiag.txt
(42.76 KiB) Downloaded 80 times
factorio-current.log
(964.51 KiB) Downloaded 106 times

User avatar
Distelzombie
Filter Inserter
Filter Inserter
Posts: 336
Joined: Tue May 02, 2017 4:27 pm
Contact:

Re: [A 0.15.16] Terrible Multiplayer FPS for no apparent reason?

Post by Distelzombie »

I guess you've lowered the graphics detail already so I just suggest you to remove all biter and see where thats going. :)

Also maybe try to completely ditch all belts forever and use bots instead. Should give huge bonus in big bases.
Complete 2-Lane system as a Blueprint-Book! The perfect OCD reactor? Testing chained science lab efficiency Please use real prefixes and proper rounding!

JadeSpider
Burner Inserter
Burner Inserter
Posts: 17
Joined: Mon Sep 26, 2016 7:04 pm
Contact:

Re: [A 0.15.16] Terrible Multiplayer FPS for no apparent reason?

Post by JadeSpider »

Having played in a large MP game recently on 0.15.16, I can verify that many people (myself included) are having FPS issues in large MP games. Early in the game, we were over 100 people and were not experiencing the issue. Later in the game, we were down to around 60 people but had a lot more of the base built up. At that point many of us were down to 5 FPS. After the game, some people loaded up the map in single player and were getting a full 60 FPS, so something weird going on in MP games only.

I have also been playing a separate MP game with only myself and one other person for a while. That game is not experiencing any issues despite have a fairly large base. It seems to be some combination of having a large number of players and a large base at the same time.

Over 100 players, very small base: 60 FPS
2 players, large base: 60 FPS
60 players, large base: 5 FPS

In the 5 FPS case, I had one single CPU core (out of 16) maxed out at 100% usage. So, there must be a single thread that is getting overloaded in that case.

GenBOOM
Long Handed Inserter
Long Handed Inserter
Posts: 95
Joined: Tue May 16, 2017 11:39 pm
Contact:

Re: [A 0.15.16] Terrible Multiplayer FPS for no apparent reason?

Post by GenBOOM »

In my experience over 2000 robots laggs the multiplayer pretty badly.
This is on a server that is less than 40 hours old and only like 6 people on it and the ping is good. Something is going wrong with the multiplayer to client handling and is hanging up he entity update / rendering process lowering fps.

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

Re: [A 0.15.16] Terrible Multiplayer FPS for no apparent reason?

Post by Rseding91 »

That's working as expected. Your save file has so much going on that it's running almost at 100% of 60 UPS. In multiplayer the server ends up running faster than you can and your game falls behind. The game goes into catch-up mode to keep up with the server and drops FPS to do so resulting in 60 UPS but < 60 FPS.
If you want to get ahold of me I'm almost always on Discord.

User avatar
Distelzombie
Filter Inserter
Filter Inserter
Posts: 336
Joined: Tue May 02, 2017 4:27 pm
Contact:

Re: [A 0.15.16] Terrible Multiplayer FPS for no apparent reason?

Post by Distelzombie »

Rseding91 wrote:That's working as expected. Your save file has so much going on that it's running almost at 100% of 60 UPS. In multiplayer the server ends up running faster than you can and your game falls behind. The game goes into catch-up mode to keep up with the server and drops FPS to do so resulting in 60 UPS but < 60 FPS.
Even if it is working as expected, the way everything is implemented is quite bad.
If you know 60 players wouldnt be able to have fun playing on a multiplayer server for as long as the game takes to play, WHY ALLOW IT in the first place? This just results in unhappy players. Some may have been there from the beginning but are now unable to play the game anymore.

I know other games are doing it right: Lets look at Starcraft 2 or similar games. They dont allow much more than 4 or 8 players because they know it will decrease player experience. (Ok I never played much StarCraft 2, but you get what I mean.)

Also the decision to have the whole multiplayer game rendered/calculated on the client alone might be a mistake. It is easier to rent better servers, but most of the time impossible to improve the performance of ones own computer. Just look at the incedibly powered CS:GO servers available for nothing everywhere for example.

I think you're a great developer, Rseding! I know because I see your responses here which are mostly just "Fixed for the next release, thanks." :D
I know it would be hard to rewrite the whole netcode. But apparently it has many flaws. I know you see them too. :)
(Since you're hiring right now - better hire a guy for the netcode next)

I think you're all like lying on the floor of the past, trying to write a code that fills the cracks of the pavement or something...
Complete 2-Lane system as a Blueprint-Book! The perfect OCD reactor? Testing chained science lab efficiency Please use real prefixes and proper rounding!

JadeSpider
Burner Inserter
Burner Inserter
Posts: 17
Joined: Mon Sep 26, 2016 7:04 pm
Contact:

Re: [A 0.15.16] Terrible Multiplayer FPS for no apparent reason?

Post by JadeSpider »

Rseding91 wrote:That's working as expected. Your save file has so much going on that it's running almost at 100% of 60 UPS. In multiplayer the server ends up running faster than you can and your game falls behind. The game goes into catch-up mode to keep up with the server and drops FPS to do so resulting in 60 UPS but < 60 FPS.
I never experienced this issue in 0.14, even in much larger games with more people and bigger bases. When you say "working as expected", are you suggesting that something was intentionally changed in 0.15 to cause this issue? I would like to understand this better.

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

Re: [A 0.15.16] Terrible Multiplayer FPS for no apparent reason?

Post by Rseding91 »

JadeSpider wrote:
Rseding91 wrote:That's working as expected. Your save file has so much going on that it's running almost at 100% of 60 UPS. In multiplayer the server ends up running faster than you can and your game falls behind. The game goes into catch-up mode to keep up with the server and drops FPS to do so resulting in 60 UPS but < 60 FPS.
I never experienced this issue in 0.14, even in much larger games with more people and bigger bases. When you say "working as expected", are you suggesting that something was intentionally changed in 0.15 to cause this issue? I would like to understand this better.
It has worked the way it does since 0.14.0. Simply you're running a different map now compared to when you did in 0.14. If you look at the debug times you can see that you're at the very limit of maintaining 60 UPS and in multiplayer there's additional overhead which pushes you past the limit and the game starts dropping FPS to keep UPS matching the server.
If you want to get ahold of me I'm almost always on Discord.

GenBOOM
Long Handed Inserter
Long Handed Inserter
Posts: 95
Joined: Tue May 16, 2017 11:39 pm
Contact:

Re: [A 0.15.16] Terrible Multiplayer FPS for no apparent reason?

Post by GenBOOM »

Okay this was not hosted on someones pc this was hosted on a dedicated server so that explanation makes no sense. The point remains that the handling is lowering performance by like 15 fps for no reason. This does not happen in single player and the excuse that the server can't handle it when it can handle it in single player makes no sense at all to me. Especially when neither the server or the client at being maxed out for cpu or gpu usage. Its clearly something that needs to be improved.
Rseding91 wrote:That's working as expected. Your save file has so much going on that it's running almost at 100% of 60 UPS. In multiplayer the server ends up running faster than you can and your game falls behind. The game goes into catch-up mode to keep up with the server and drops FPS to do so resulting in 60 UPS but < 60 FPS.
this makes no sense at all. are you saying the server is over-riding the client rendering process and because its feeding it more information? although its feeding just as much information as you would have in single player? this is exaclty my point that the handling is artificially lowering performance.

single player = higher fps with more cpu usage
multiplayer = lower fps with less cpu usage

blaming the client for not handling the information the server provides does not makes sense when there is not a bottleneck on the ability to compute information to begin with, single player or multiplayer

User avatar
DaveMcW
Smart Inserter
Smart Inserter
Posts: 3700
Joined: Tue May 13, 2014 11:06 am
Contact:

Re: [A 0.15.16] Terrible Multiplayer FPS for no apparent reason?

Post by DaveMcW »

The real problem is the server can't detect clients are struggling, and happily runs full speed until they are forced to drop out.

GenBOOM
Long Handed Inserter
Long Handed Inserter
Posts: 95
Joined: Tue May 16, 2017 11:39 pm
Contact:

Re: [A 0.15.16] Terrible Multiplayer FPS for no apparent reason?

Post by GenBOOM »

DaveMcW wrote:The real problem is the server can't detect clients are struggling, and happily runs full speed until they are forced to drop out.
no you are still missing the point. the game is running at the same speed in real time in single player and multiplayer so why is single player faster when the server should actually be offloading the work and the client should have increased fps rather than lowered fps? its the opposite of the entire point of creating a server to host a game in the first place

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

Re: [A 0.15.16] Terrible Multiplayer FPS for no apparent reason?

Post by Rseding91 »

GenBOOM wrote:
DaveMcW wrote:The real problem is the server can't detect clients are struggling, and happily runs full speed until they are forced to drop out.
no you are still missing the point. the game is running at the same speed in real time in single player and multiplayer so why is single player faster when the server should actually be offloading the work and the client should have increased fps rather than lowered fps? its the opposite of the entire point of creating a server to host a game in the first place
Factorio multiplayer doesn't work like that. Running multiplayer actually increases the load as you've now got to process network traffic + CRC data that you otherwise wouldn't in single player.

Additionally you still have to run the entire game simulation regardless of being in multiplayer because that's how Factorio multiplayer works.
If you want to get ahold of me I'm almost always on Discord.

GenBOOM
Long Handed Inserter
Long Handed Inserter
Posts: 95
Joined: Tue May 16, 2017 11:39 pm
Contact:

Re: [A 0.15.16] Terrible Multiplayer FPS for no apparent reason?

Post by GenBOOM »

Rseding91 wrote:Factorio multiplayer doesn't work like that. Running multiplayer actually increases the load as you've now got to process network traffic + CRC data that you otherwise wouldn't in single player.

Additionally you still have to run the entire game simulation regardless of being in multiplayer because that's how Factorio multiplayer works.
okay fine, but you still aren't maximizing the use of my cpu or gpu. the fps drop shouldn't be happening.

also that still doesn't make sense because in multiplayer I'm using less cpu, if you looked at the screenshots I provided earlier. so something is not adding up here.
cpu and gpu usage

GenBOOM
Long Handed Inserter
Long Handed Inserter
Posts: 95
Joined: Tue May 16, 2017 11:39 pm
Contact:

Re: [A 0.15.16] Terrible Multiplayer FPS for no apparent reason?

Post by GenBOOM »

Alright after a ton of testing what I have found is that the games fps is basically limited by the speed and efficiency of 2 of the cores you have available.

Going from 1 to 2 cores will increase fps and maximize both cores, but going from 2 to 3 does not although there is slightly more workload on the 3rd core.
The workload seems to be a little over 2 cores but there are no fps gains from allowing the game to have more than 2 cores. I had someone else try this as well, and we both had the same result.
Once you allow the game to use more than 2 cores its just spreading the same workload across more cores to keep core utilization low on any one of the single cores from the total number of cores available.
So unless some coding magic is done to improve the efficiency of the actual calculations the game performs, the only way to improve performance would be for me to upgrade to a cpu that has better efficiency per core.

Here are things that don't make any noticeable difference to fps if it is already maxed out so don't waste your time testing them out like I did
graphics drivers
graphics settings
ram timing
cpu speed
gpu speed
hard drive or ssd
steam or standalone version of the game

I can host a map that I have 20-40 fps on and someone with a better machine than me can catch up and play on my server. However, if I try to connect to the same map in multiplayer that is hosted by that better machine, I will never catch up even though I can host it just fine. This is why its so frustrating. The catching up process is more performance hungry than playing the game while hosting from the same machine. The server can be a potato, but the players are required to have a better machine than the host in order to catch up. I think the catching up system probably needs to be done differently.

Some kind of tech would be nice to reduce the number of things happening in the game so that its not possible to degrade performance to this extent.
Last edited by GenBOOM on Sat Jun 03, 2017 3:31 pm, edited 1 time in total.

User avatar
Klonan
Factorio Staff
Factorio Staff
Posts: 5151
Joined: Sun Jan 11, 2015 2:09 pm
Contact:

Re: [A 0.15.16] Terrible Multiplayer FPS for no apparent reason?

Post by Klonan »

GenBOOM wrote:Some kind of tech would be nice to reduce the number of things happening in the game so that its not possible to degrade performance to this extent.
If you'd like we can limit the map sizes and restrict the number of entities you can place

GenBOOM
Long Handed Inserter
Long Handed Inserter
Posts: 95
Joined: Tue May 16, 2017 11:39 pm
Contact:

Re: [A 0.15.16] Terrible Multiplayer FPS for no apparent reason?

Post by GenBOOM »

Klonan wrote:If you'd like we can limit the map sizes and restrict the number of entities you can place
I was thinking more like that compress plates mod
GenBOOM wrote:well then we need to have an atom compressor that condenses items and is an infiinite research tech.
could also add some other machine that takes base elements from materials that are of similar make-up and restructures them into the desired item. basically a 3d printer that uses alchemy. why smelt iron ore when its already iron? alchemy! no transport needed. iron ore + copper ore = anything that requires those 2 base items to craft
add a third machine that allows you to combine things and create new elements for sci-fi tech
this would eliminate the need for smelters and assembly machines crafting basic items that require 2nd tier items like plates and gears. by combining them into one thing you remove the need to deliver 2nd tier items completely and can skip 2 levels of logistics. obviously the footprint of the amount of space required to do the same amount of work would decrease, as would the number of items and machine animations the game has to render, that is the idea anyway.
Last edited by GenBOOM on Sat Jun 03, 2017 3:45 pm, edited 1 time in total.

User avatar
Klonan
Factorio Staff
Factorio Staff
Posts: 5151
Joined: Sun Jan 11, 2015 2:09 pm
Contact:

Re: [A 0.15.16] Terrible Multiplayer FPS for no apparent reason?

Post by Klonan »

GenBOOM wrote:
Klonan wrote:If you'd like we can limit the map sizes and restrict the number of entities you can place
I was thinking more like that compress plates mod
I think you can imagine that this exact problem would reoccur even with compressing of items,
There is no perfect solution,
But we are optimizing and refining the game so that huge satisfying factories will run efficiently on any PC

There are always going to be the people who make extreme factories,
In these cases we are open to you sending us your save games,
So we can see specifically what is using all the CPU,
And we can try and optimize based on what we find

GenBOOM
Long Handed Inserter
Long Handed Inserter
Posts: 95
Joined: Tue May 16, 2017 11:39 pm
Contact:

Re: [A 0.15.16] Terrible Multiplayer FPS for no apparent reason?

Post by GenBOOM »

Klonan wrote:I think you can imagine that this exact problem would reoccur even with compressing of items
Yeah, its only pushing the problem back, thats why I suggested some really slow infinite research tech, that would only help slightly over a really long game.
The real thing tho is bypassing the need for all these systems that are in the game and combining 2 systems into 1 so that less logistics are required to do the same amount of work. That is in essence my idea.
Attachments
[DIST9][0.15 Railworld-4] (JUN2-2017).zip
save I used to test multiplayer vs single player vs hosting fps
(45.94 MiB) Downloaded 70 times

GenBOOM
Long Handed Inserter
Long Handed Inserter
Posts: 95
Joined: Tue May 16, 2017 11:39 pm
Contact:

Re: [A 0.15.16] Terrible Multiplayer FPS for no apparent reason?

Post by GenBOOM »

GenBOOM wrote:well then we need to have an atom compressor that condenses items and is an infiinite research tech.
Let me explain because this probably isn't as clear...
Instead of ore patch density this would be a single ore density value increase. so 1 copper ore would eventually, hopefully very slowly, double and triple in value so that less miners are necessary and less delivery is necessary. this is an efficiency boost that will permeate the entire game. this would also drastically change the amount of things required to generate in a world for it to be viable to play for a long period of time. to me it seems like a win no matter what. there could be a machine that does this for other things in the game as well besides just base materials like ores, so the longer you play the less machines you need to maintain production. eventually you would be left wit ha factory that had 1 machine for each things that you need and no more, except for the highest tier of item.

GenBOOM
Long Handed Inserter
Long Handed Inserter
Posts: 95
Joined: Tue May 16, 2017 11:39 pm
Contact:

Re: [A 0.15.16] Terrible Multiplayer FPS for no apparent reason?

Post by GenBOOM »

the 3d printer idea seems the most realistc thing tho and it would solve a lot of the same problems.

feed the printer the base materials in liquid form, so it takes a lot of electricity and heat to keep things prepared but allow it to do multiple things
feed it iron plates, copper plates, plastic, and sulfuric acid
give it a queue of orders, a list, that runs on a loop so it will craft 24 green circuits, put them in temporary storage, 2 red circuits and 1 blue circuit and repeat.

3d printer that replaces an entire line of assemblers

Post Reply

Return to “Not a bug”