Topic: Build plots calculations change
Nordfriese![]() Topic Opener |
Posted at:
2020-08-04, 22:41 UTC+2.0
There is currently a bug where placing more lava or similar bad terrains enables building spaces: In order to fix this, we want to always disable the building space in the situation illustrated in the image. This might cause bottlenecks or similar bad side-effects on some official maps (e.g. Sun of Fire, Long Long Way, Fjords) so we'd appreciate it if people who know the maps well could give their thoughts on which maps may need some editing to make them balanced again after this change
Edited:
2020-08-04, 22:43 UTC+2.0
![]() ![]() |
||||||||||||||||||||||||||||||||||||||||||||||||||||
kaputtnik![]() |
Posted at:
2020-08-05, 08:45 UTC+2.0
I have tried to write a small lua script which count all building plots for a map loaded in editor:
If this script can be run over all maps automatically it should be possible to estimate the result of the proposed change. But the result is surprising... for a map with 1 big plot, 4 medium plots, 2 mine plots and no immovables the result is:
![]() ![]() |
||||||||||||||||||||||||||||||||||||||||||||||||||||
JanO![]() |
Posted at:
2020-08-05, 08:57 UTC+2.0
Does the result change if you switch the order into first count big, then medium and small in the end? ![]() ![]() |
||||||||||||||||||||||||||||||||||||||||||||||||||||
einstein13![]() |
Posted at:
2020-08-05, 11:05 UTC+2.0
Is there any possibility to estimate how many building spots would be removed / added after the change? I am the "inventor" of Long Long Way and it should not be affected by that, but I would like to know how much it CAN be affected (by numbers of spots). Unfortunately it can be affected by the fact that port spaces calculation changed since map creation. einstein13 ![]() ![]() |
||||||||||||||||||||||||||||||||||||||||||||||||||||
GunChleoc![]() |
Posted at:
2020-08-05, 11:44 UTC+2.0
You could try something like this (not tested by me): I have tried to write a small lua script which count all building plots for a map loaded in editor:
This will count the port spaces simply as big plots, but that should be fine for this purpose. Busy indexing nil values ![]() ![]() |
||||||||||||||||||||||||||||||||||||||||||||||||||||
einstein13![]() |
Posted at:
2020-08-05, 13:41 UTC+2.0
Yes, but it will not show how many plots will be missing with proposed change. Is there any possibility to check nearby nodes if they contain any lava / ice? einstein13 ![]() ![]() |
||||||||||||||||||||||||||||||||||||||||||||||||||||
GunChleoc![]() |
Posted at:
2020-08-05, 16:11 UTC+2.0
In order to show what's missing, you'd have to run this both with the master branch and the feature branch and then compare the results. Busy indexing nil values ![]() ![]() |
||||||||||||||||||||||||||||||||||||||||||||||||||||
kaputtnik![]() |
Posted at:
2020-08-05, 19:10 UTC+2.0
Yes, this can be done by checking the neighbores of a field
This was my idea... although it's a bit boring to open the debug console and type dofile('path/to/file.lua') each time a new map was loaded This script seems to work properly now:
I am compiling the nodacapsmath-branch now and will provide some comparisons later. Any special maps to compare? ![]() ![]() |
||||||||||||||||||||||||||||||||||||||||||||||||||||
kaputtnik![]() |
Posted at:
2020-08-05, 20:02 UTC+2.0
Here are the results of the maps mentioned in the first post:
![]() ![]() |
||||||||||||||||||||||||||||||||||||||||||||||||||||
einstein13![]() |
Posted at:
2020-08-06, 01:08 UTC+2.0
A bit strange: more big places than before? einstein13 ![]() ![]() |