The International Simutrans Forum

 

Author Topic: [Bug] The start(slope) of the bridge is considered to have no height.  (Read 288 times)

0 Members and 1 Guest are viewing this topic.

Offline Ranran

  • Devotee
  • *
  • Posts: 1555
  • Languages: ja


Cities surprise us by building bridges that ignore collisions, but it turns out that it's also feasible for players.

« Last Edit: May 26, 2021, 08:18:26 AM by Ranran »

Offline Ranran

  • Devotee
  • *
  • Posts: 1555
  • Languages: ja
Re: [Bug] The start(slope) of the bridge is considered to have no height.
« Reply #1 on: February 05, 2021, 09:35:37 AM »
I've recently made sometimes the code format the same which should be the same as standard in order to prepare the merge work before merging from standard.
At that time I noticed that tool_build_bridge_t::is_valid_pos could have been corrupted for several years.
I'm not sure if this is related to this thread.


https://github.com/jamespetts/simutrans-extended/blob/8877dfde5a431504c1bc433e781c9fa4a31902dc/simtool.cc#L3249

Notice the alignment of the two if statements.
Code: [Select]
if(  gr->ist_karten_boden()  ) {
// first click
ribi_t::ribi rw = ribi_t::none;
if (wt==powerline_wt) {
This part is not the same as standard, but the end position of the statement may be strange when compared to standard.

Offline Ranran

  • Devotee
  • *
  • Posts: 1555
  • Languages: ja
Re: [Bug] The start(slope) of the bridge is considered to have no height.
« Reply #2 on: February 08, 2021, 10:35:25 AM »
After a bit of research into that code, the difference from standard was that some commits hadn't been merged yet. It didn't seem to be a problem that the indentation was broken.
As a result of incorporating r9084, 9085 and 9089, this bug seems to have been fixed.
Check pull request # 356. The branch contains some other fixes and changes.