The International Simutrans Forum

 

Author Topic: r6585 nightly linux 64 -- land sinking into the water / eathquakes?  (Read 5610 times)

0 Members and 1 Guest are viewing this topic.

Offline richardk

  • *
  • Posts: 10
  • Languages: en
r6585 linux 64.
When I started a saved game I found that some land had sunk into the water. There was a road on that square and therefore vehicles could not find a route. This has happened near water and at the edge of the map, and I think that the sunk squares might have been flat artificial slopes, but I'm not too sure. The edge of the map has lost quite a large area into the sea.
 
I've had this happen in both pak128.open.r1199 & pak128.Britain.

This has only started recently, sorry but I don't know exactly which version this started at, but it just happen in the latest nightly.
Any ideas what's going wrong?

Richard

Offline kierongreen

  • Dev Team, Coder/patcher
  • Devotee
  • *
  • Posts: 2269
Re: r6585 nightly linux 64 -- land sinking into the water / eathquakes?
« Reply #1 on: July 15, 2013, 01:01:15 PM »
Would it be possible to show a screenshot or provide a saved game?

Offline richardk

  • *
  • Posts: 10
  • Languages: en
Re: r6585 nightly linux 64 -- land sinking into the water / eathquakes?
« Reply #2 on: July 15, 2013, 01:51:08 PM »
Sure -- No problem. Shall I post them here? they are a bit big.

Offline richardk

  • *
  • Posts: 10
  • Languages: en
Re: r6585 nightly linux 64 -- land sinking into the water / eathquakes?
« Reply #3 on: July 15, 2013, 02:13:13 PM »
OK -I've copied the relevant bit of the screen shot to a png , which should now be small enough

Offline kierongreen

  • Dev Team, Coder/patcher
  • Devotee
  • *
  • Posts: 2269
Re: r6585 nightly linux 64 -- land sinking into the water / eathquakes?
« Reply #4 on: July 16, 2013, 03:42:48 PM »
Very strange....

Offline Ters

  • Coder/patcher
  • Devotee
  • *
  • Posts: 5543
  • Languages: EN, NO
Re: r6585 nightly linux 64 -- land sinking into the water / eathquakes?
« Reply #5 on: July 16, 2013, 05:50:59 PM »
Do you have any idea of which revision(s) of Simutrans you used before this? Even a rough estimate?

Offline IgorEliezer br

  • Devotee
  • Administrator
  • *
  • Posts: 4087
  • Cake recipes are cool... REALLY!
    • Igor Eliezer Architect and Urban Planner/Arquiteto e Urbanista
  • Languages: PT, EN, AutoLISP, Python
Re: r6585 nightly linux 64 -- land sinking into the water / eathquakes?
« Reply #6 on: July 16, 2013, 05:52:41 PM »
People from PT-Portuguese board would rejoice on seeing these screens. They asked for quakes, accidents and all kind of simcity stuff to be put in Simutrans a ton of times.

Offline kierongreen

  • Dev Team, Coder/patcher
  • Devotee
  • *
  • Posts: 2269
Re: r6585 nightly linux 64 -- land sinking into the water / eathquakes?
« Reply #7 on: July 16, 2013, 06:18:38 PM »
Could conceivably be incompatibility between nightly versions to do with double height code.

Offline Ters

  • Coder/patcher
  • Devotee
  • *
  • Posts: 5543
  • Languages: EN, NO
Re: r6585 nightly linux 64 -- land sinking into the water / eathquakes?
« Reply #8 on: July 16, 2013, 07:49:26 PM »
But why just those tiles? Were they something else than plain grund_t, like fundament_t? Is it even possible to fill such an area with that?

Offline Dwachs

  • DevTeam, Coder/patcher
  • Administrator
  • *
  • Posts: 4601
  • Languages: EN, DE, AT
Re: r6585 nightly linux 64 -- land sinking into the water / eathquakes?
« Reply #9 on: July 17, 2013, 05:58:03 AM »
A savegame before this happened would be very helpful to find to actual cause.

Offline Tazze

  • *
  • Posts: 84
  • Languages: Jp En De Fr
Re: r6585 nightly linux 64 -- land sinking into the water / eathquakes?
« Reply #10 on: July 18, 2013, 10:03:17 AM »
I'm sorry not to report that: Although I'm windows user, I had faced this disaster in about a month ago.
I post save data for pak128 Britain.
http://simutrans-germany.com/files/upload/britain_6.17-6.28.sve

my  log
6/17       I had downloaded nightly " simwingdi_2013-06-17_v112.4_r6553 " with pak britain-1208 to make road vehicle list for Pak Britain and made save data.

6/24       I had upload to "r6555" (I upload the latest version frequently..)  but world limits in this save data had be broken a bit.

7/3         I upload to "r5676" but the bug had not fixed.

7/4 or 5  I had used this save data made road vehicle list for Pak Britain. Suddenly, Problem window turned up,the ground was broken down when I looked there.

I made the list from this save data but I stoped using this.

sorry to be late to report because I checked my log and I'm carefully against bug report.

Offline kierongreen

  • Dev Team, Coder/patcher
  • Devotee
  • *
  • Posts: 2269
Re: r6585 nightly linux 64 -- land sinking into the water / eathquakes?
« Reply #11 on: July 18, 2013, 11:18:34 AM »
Has anyone encountered this issue when loading a release saved game as opposed to one from a nightly?

Offline captain crunch

  • *
  • Posts: 116
Re: r6585 nightly linux 64 -- land sinking into the water / eathquakes?
« Reply #12 on: August 01, 2013, 02:26:43 PM »
Some observations:
* It does not only happen with save games from earlier (nightly) version
* It does not only happen on shore lines: The the lowered tile in the saved game Lengerich sunken land was a train tunnel.
* It is possible to gain land by lowering the flat land tiles on the shore, see screen shots from the saved game Lengerich - Landgewinnung

Versions:
* simutrans 112.4 current trunk from github
* pak64.german 110-0c

Offline kierongreen

  • Dev Team, Coder/patcher
  • Devotee
  • *
  • Posts: 2269
Re: r6585 nightly linux 64 -- land sinking into the water / eathquakes?
« Reply #13 on: August 01, 2013, 02:58:59 PM »
Quote
It is possible to gain land by lowering the flat land tiles on the shore, see screen shots from the saved game Lengerich - Landgewinnung
This is intended.

Offline captain crunch

  • *
  • Posts: 116
Re: r6585 nightly linux 64 -- land sinking into the water / eathquakes?
« Reply #14 on: August 10, 2013, 06:03:33 PM »
Probably related, when lowering the marked tile in the attached save game, it digs a very deep shaft, which cannot get undone.

Offline Ters

  • Coder/patcher
  • Devotee
  • *
  • Posts: 5543
  • Languages: EN, NO
Re: r6585 nightly linux 64 -- land sinking into the water / eathquakes?
« Reply #15 on: August 10, 2013, 07:19:12 PM »
Probably related, when lowering the marked tile in the attached save game, it digs a very deep shaft, which cannot get undone.
This is a relatively new bug. Unfortunately, I'm not sure which revision I built the last time (only enabled WITH_REVISION now), but it did already contain some theme stuff, yet I did not get any deep shafts with that.

Offline z9999+

  • Coder/patcher
  • *
  • Posts: 377
Re: r6585 nightly linux 64 -- land sinking into the water / eathquakes?
« Reply #16 on: August 15, 2013, 07:26:52 AM »
I'm not sure this is related or not. Tested with r6646.

Can build way on water.


Cannot dig correctly.


Offline kierongreen

  • Dev Team, Coder/patcher
  • Devotee
  • *
  • Posts: 2269
Re: r6585 nightly linux 64 -- land sinking into the water / eathquakes?
« Reply #17 on: August 15, 2013, 07:41:23 AM »
Both bugs shown by z9999+ confirmed on 6646. Will work on later after work if someone doesn't get there first...

Offline captain crunch

  • *
  • Posts: 116
Re: r6585 nightly linux 64 -- land sinking into the water / eathquakes?
« Reply #18 on: August 15, 2013, 11:28:56 AM »
Perhaps introduced with this commit in simwerkz.cc line 1273?

Offline kierongreen

  • Dev Team, Coder/patcher
  • Devotee
  • *
  • Posts: 2269
Re: r6585 nightly linux 64 -- land sinking into the water / eathquakes?
« Reply #19 on: August 15, 2013, 05:19:27 PM »
That bit of the commit you refer to has following changes:
Code: [Select]
+  const sint8 water_hgt = welt->get_water_hgt( pos.get_2d() );
....
-      if(  !gr1->ist_wasser()  &&  new_slope == 0  &&  new_pos.z == welt->get_water_hgt( pos.get_2d() )  &&  gr1->get_typ() != grund_t::tunnelboden  ) {
+      if(  !gr1->ist_wasser()  &&  new_slope == 0  &&  new_pos.z == water_hgt  &&  gr1->get_typ() != grund_t::tunnelboden  ) {
which should be the same before...

Offline Ters

  • Coder/patcher
  • Devotee
  • *
  • Posts: 5543
  • Languages: EN, NO
Re: r6585 nightly linux 64 -- land sinking into the water / eathquakes?
« Reply #20 on: August 15, 2013, 05:49:18 PM »
The maximum height error isn't a bug, in case anyone thinks that. The bug is the overly deep shaft created just before.

Offline captain crunch

  • *
  • Posts: 116
Re: r6585 nightly linux 64 -- land sinking into the water / eathquakes?
« Reply #21 on: August 15, 2013, 07:22:14 PM »
That bit of the commit you refer to has following changes:
Code: [Select]
+  const sint8 water_hgt = welt->get_water_hgt( pos.get_2d() );
....
-      if(  !gr1->ist_wasser()  &&  new_slope == 0  &&  new_pos.z == welt->get_water_hgt( pos.get_2d() )  &&  gr1->get_typ() != grund_t::tunnelboden  ) {
+      if(  !gr1->ist_wasser()  &&  new_slope == 0  &&  new_pos.z == water_hgt  &&  gr1->get_typ() != grund_t::tunnelboden  ) {
which should be the same before...
Sadly, I do not know enough about C++ to be able to affirm that, but reverting the changed source line fixes the problem of creation of the erroneous deep shafts.
Quote from: Ters
The bug is the overly deep shaft created just before.
Exactly. And also building land on water as z9999+ noted.


Offline kierongreen

  • Dev Team, Coder/patcher
  • Devotee
  • *
  • Posts: 2269
Re: r6585 nightly linux 64 -- land sinking into the water / eathquakes?
« Reply #22 on: August 15, 2013, 07:27:53 PM »
I think I've fixed both.... and it was water_hgt not being updated when water height was changed, then code after relying on old value. Committed in 6649.

Offline kierongreen

  • Dev Team, Coder/patcher
  • Devotee
  • *
  • Posts: 2269
Re: r6585 nightly linux 64 -- land sinking into the water / eathquakes?
« Reply #23 on: August 18, 2013, 12:26:59 AM »
Incidentally, while the bugs described by z9999+ have been fixed, can anyone confirm whether the original bugs at the top of this thread are still present?

Offline captain crunch

  • *
  • Posts: 116
Re: r6585 nightly linux 64 -- land sinking into the water / eathquakes?
« Reply #24 on: August 18, 2013, 11:01:19 AM »
Yes, the original bug is still not fixed:
* OK
* Rotated map twice, land sunk

Offline kierongreen

  • Dev Team, Coder/patcher
  • Devotee
  • *
  • Posts: 2269
Re: r6585 nightly linux 64 -- land sinking into the water / eathquakes?
« Reply #25 on: August 18, 2013, 11:50:29 AM »
Ok thanks - bug is linked to http://forum.simutrans.com/index.php?topic=12000.0 I'm trying to find out a solution that works for all tiles. Sometimes I wish that someone hadn't made the decision not to save the height grid with saved games...

Offline Ters

  • Coder/patcher
  • Devotee
  • *
  • Posts: 5543
  • Languages: EN, NO
Re: r6585 nightly linux 64 -- land sinking into the water / eathquakes?
« Reply #26 on: August 18, 2013, 11:56:53 AM »
Yes, the original bug is still not fixed:

I'm not 100 % sure this is the same as the bug reported in the first post since we have no information about how the landscape looked before. But it is certainly no impossibility. In any case, they are both related to what kierongreen links to.

Offline kierongreen

  • Dev Team, Coder/patcher
  • Devotee
  • *
  • Posts: 2269
Re: r6585 nightly linux 64 -- land sinking into the water / eathquakes?
« Reply #27 on: August 18, 2013, 06:18:26 PM »
Ok, I think that should be bug fixed in 6655. Can people please particularly check for any more slope errors. I think I've got them all now but you never know where more will be lurking!