View Issue Details

IDProjectCategoryView StatusLast Update
0005452Spring engineGeneralpublic2017-06-01 17:36
Reporterjamerlan Assigned To 
PriorityurgentSeveritycrashReproducibilityalways
Status resolvedResolutionsuspended 
Product Version103.0 
Summary0005452: building spam creates a HUGE lag in network game
DescriptionPlease take a look at this screenshot: http://i.imgur.com/vT3KXpG.jpg
one "troll" player spammed "Dragon's eye"(armeyes, small building) on the enemy side of the map. Game lagged and freezed. UI crashed too.

Steps To ReproduceReplay is attached. Take a look at [SAAD]Mando's kbot cons at 06:10
Additional InformationMaybe engine devs can improve perfomance based on this scenario?
TagsNo tags attached.
Attached Files
Checked infolog.txt for Errors

Activities

jamerlan

2017-02-04 20:45

reporter   ~0017204

oops I attached wrong replay.
Correct one: 20170204_220106_DeltaSiegeDry_103.sdfz
20170204_220106_DeltaSiegeDry_103.sdfz (Attachment missing)

jamerlan

2017-02-04 20:46

reporter   ~0017205

please remove this file. Attached by mistake: ? 20170204_222254_DeltaSiegeDry_103.sdfz (21,046 bytes) 2017-02-04 20:42

jamerlan

2017-02-04 20:50

reporter   ~0017206

Let's imagine you will say that bug should be fixed on the game side. For example: do not allow to queue more then 50 buildings with cons. Then people will build 20 - 300 cons and lag the game.. If you say: do not allow to queue more then 50 buildings in total.. then game will be (probably) not playable

Kloot

2017-02-04 21:01

developer   ~0017207

Last edited: 2017-02-04 21:04

the solution is to send such huge orders in chunks, and for server admins to kick/ban players who abuse the engine until that is implemented.

jamerlan

2017-02-04 21:40

reporter   ~0017208

It looks like it is already applied in chunks. At least it appears in chunks.
Also even in singleplayer performance is going down very fast when you queue such buildings.

Kloot

2017-02-04 21:47

developer   ~0017209

Last edited: 2017-02-04 22:14

things that are slow here:

* engine drawing of massive build queues, mostly DrawMapStuff/ShowUnitBuildSquare
* widgets processing massive build queues, easily avoided by a /luaui disable
* handling masses of individual build orders

killing just the first two keeps framerate well within the playable range, and fixing the widget-side means trolls will only lag themselves (and maybe some unfortunate spectators with alwaysDrawQueue=1) out of the game.

nixtux

2017-02-06 08:26

reporter   ~0017223

It's game issue, run demo with commands Fx widget disabled and bingo no crash. It produces too large a table in widget:unitcommand.

nixtux

2017-02-06 09:17

reporter   ~0017224

Well the running out of memory is game side, in the replay I found commands Fx crashed at around 14k+ units in widget:unitcommand to due to no limits for table size creation.

Floris

2017-02-06 17:01

reporter   ~0017230

I applied cleaning of some tables in command fx widget ,hope this fixes it

https://github.com/Balanced-Annihilation/Balanced-Annihilation/commit/bcc9a0f7bf71e8a6fe1b569720e3dd84e43d68ba

Floris

2017-02-06 17:13

reporter   ~0017231

seems not

Floris

2017-02-06 18:26

reporter   ~0017232

Fixed the crashing (by periodically instead of directly updating newly given commands)

https://github.com/Balanced-Annihilation/Balanced-Annihilation/commit/fa81f7c56dcd7a211b19df86d84c43cd3b3ca00e

sprung

2017-06-01 17:09

reporter   ~0017759

-> resolved?

Kloot

2017-06-01 17:36

developer   ~0017760

"engine drawing of massive build queues" is still a perf-killer, but can't be sped up much without a GL4 rewrite which is at least one major release in the future.

Issue History

Date Modified Username Field Change
2017-02-04 20:42 jamerlan New Issue
2017-02-04 20:42 jamerlan File Added: 20170204_222254_DeltaSiegeDry_103.sdfz
2017-02-04 20:45 jamerlan File Added: 20170204_220106_DeltaSiegeDry_103.sdfz
2017-02-04 20:45 jamerlan Note Added: 0017204
2017-02-04 20:46 jamerlan Note Added: 0017205
2017-02-04 20:50 jamerlan Note Added: 0017206
2017-02-04 21:01 Kloot Note Added: 0017207
2017-02-04 21:04 Kloot Note Edited: 0017207
2017-02-04 21:04 Kloot File Deleted: 20170204_222254_DeltaSiegeDry_103.sdfz
2017-02-04 21:40 jamerlan Note Added: 0017208
2017-02-04 21:47 Kloot Note Added: 0017209
2017-02-04 22:09 Kloot Note Edited: 0017209
2017-02-04 22:14 Kloot Note Edited: 0017209
2017-02-06 08:26 nixtux Note Added: 0017223
2017-02-06 09:17 nixtux Note Added: 0017224
2017-02-06 17:01 Floris Note Added: 0017230
2017-02-06 17:13 Floris Note Added: 0017231
2017-02-06 18:26 Floris Note Added: 0017232
2017-06-01 17:09 sprung Note Added: 0017759
2017-06-01 17:36 Kloot Status new => resolved
2017-06-01 17:36 Kloot Resolution open => suspended
2017-06-01 17:36 Kloot Note Added: 0017760