News:

Simutrans.com Portal
Our Simutrans site. You can find everything about Simutrans from here.

[r6980] Lake-elevated-way-station bug

Started by Spacethingy, December 14, 2013, 09:04:16 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Spacethingy

Also present in r6943 (both with latest pak64), this is weird, and at one point gave a CTD (unfortunately this CTD occurred while spamming various combinations of things, I can't reproduce it):





Elevated ways can only be built one tile into a lake - but only sometimes (and I can't work out the rules governing when I can/can't do so).


When a station tile is built on such a elevated way tile, the station appears, but somehow isn't registered with route finding as a station - convoys treat it merely as a waypoint (it's called Waypoint in the convoy info box, not the station name), and clicking on it with the inspect tool can only invoke the way's info box [see the External station in the screenshot].


Worse, when deleted, the station leaves a ghost marker behind [see Branch station in pic]. These ghosts stay in the station list menu, even if another station (which is generated with a different name) is built on top.


Hope that helps!  :thumbsup:
Life is like a Simutrans transformer:

You only get one of them, and you can't have it on a slope.

kierongreen

QuoteElevated ways can only be built one tile into a lake - but only sometimes (and I can't work out the rules governing when I can/can't do so).
They can only be built on shallow water.

prissi


Spacethingy

Quote from: kierongreen on December 14, 2013, 09:28:58 PM
They can only be built on shallow water.

Ah, that makes sense. Didn't realise lakes had varying depth, although that explains why pak96 has different coloured lake tiles. Maybe the difference in colour could be exagerated in pak64 too?

Doesn't explain the station bugs though.
Life is like a Simutrans transformer:

You only get one of them, and you can't have it on a slope.

Ters

I find the color difference in pak64 good enough. I'm not sure why there isn't any in your screenshot. It doesn't work for lakes?

Spacethingy

Quote from: Ters on December 15, 2013, 01:36:00 PM
I find the color difference in pak64 good enough. I'm not sure why there isn't any in your screenshot. It doesn't work for lakes?

Apparently not in pak64. Others paks do though:

(...and also have the station bug)
Life is like a Simutrans transformer:

You only get one of them, and you can't have it on a slope.

Ters

Looks like pak64 doesn't change color until depth changes from 2 to 3. But the color difference is great enough.

prissi

I will change pak64 to change the color more early then.

Spacethingy

#8
The station bug is still present in r7001. (Thanks for changing pak64, the difference is noticeable now!)
Life is like a Simutrans transformer:

You only get one of them, and you can't have it on a slope.

Dwachs

here is a small patch:

Index: boden/grund.cc
===================================================================
--- boden/grund.cc      (revision 7002)
+++ boden/grund.cc      (working copy)
@@ -647,7 +647,7 @@
        bool add = halt.is_bound();
        if(  add  ) {
                // ok, we want to add a stop: first check if it can apply to water
-               if(  get_weg_ribi(water_wt)  ||  ist_wasser()  ||  (welt->get_climate(pos.get_2d())==water_climate  &&  !ist_im_tunnel()  &&  get_typ()!=brueckenboden)  ) {
+               if(  get_weg_ribi(water_wt)  ||  ist_wasser()  ||  (ist_karten_boden()  &&  welt->get_climate(pos.get_2d())==water_climate)  ) {
                        add = (halt->get_station_type() & haltestelle_t::dock) > 0;
                }
        }

I do not know whether the check for climate == water does make sense. Are there tiles with climate == water that are not water tiles??
Parsley, sage, rosemary, and maggikraut.

Fabio

Yes, sloped shores used to have climate=water (at least for buildings)


Sent from my iPhone using Tapatalk

Dwachs

Parsley, sage, rosemary, and maggikraut.