The International Simutrans Forum

Development => Patches & Projects => Incorporated Patches and Solved Bug Reports => Topic started by: PkK on August 06, 2008, 08:28:01 AM

Title: Can't upgrade tram track
Post by: PkK on August 06, 2008, 08:28:01 AM
I can't upgrade the 50 km/h tram tracks to the 80 km/h ones by building over the old ones. This is very annoying since to upgrade I have to destroy all tram tracks including stations and electrification, then build the new track and rebuild all stations and electrification.

However I noticed it is possible to upgrade the 65 km/h rail track to 80 km/h tram track by building over it.

Philipp
Title: Re: Can't upgrade tram track
Post by: whoami on August 31, 2008, 03:54:28 AM
Still present with ST r1953 (can't test a newer revision).

The tram tracks cannot be upgraded if they are placed on a road. Both tracks can be built on a road. (This doesn't show up with Pak64, because it has only one type of tram track.)

I think this is rather a bug in ST (=> moved to bug reports), and it was reported much earlier in the previous forum, but thanks for the reminder.
Attached: the .dat file for Pak128 tram tracks.
Title: Re: Can't upgrade tram track
Post by: DirrrtyDirk on August 31, 2008, 10:42:10 AM
@PkK:

Generally a bug report should contain information about the version of Simutrans (and the pak, in some cases also operating system) in which the bug appears. Please try to remember that. Thank you.
Title: Re: Can't upgrade tram track
Post by: Antarctica on May 16, 2009, 06:51:04 PM
I just wanted to remind that this bug is still existent. (Linux binary, 102 Nightly Mar 2 2009, PAK128 1.4.5)
Title: Re: Can't upgrade tram track
Post by: Dwachs on May 16, 2009, 07:11:02 PM
Please try a recent version. I could not reproduce the bug.

you can find newer executables here:
http://simutrans-germany.com/~nightly/simutrans/index.php
Title: Re: Can't upgrade tram track
Post by: z9999 on May 16, 2009, 07:24:51 PM
Quote from: Dwachs on May 16, 2009, 07:11:02 PM
I could not reproduce the bug.

I could.
Did you test on road ?
Title: Re: Can't upgrade tram track
Post by: Dwachs on May 16, 2009, 07:36:20 PM
yes, now i tested with roads, and everything works fine even with public owned road ???
Title: Re: Can't upgrade tram track
Post by: z9999 on May 16, 2009, 08:06:03 PM
Strange enough. Why it doesn't work for me.
Title: Re: Can't upgrade tram track
Post by: Dwachs on May 16, 2009, 08:13:46 PM
it happens only if there is a road and a tram track

here is a patch:

Index: wegbauer.cc
===================================================================
--- wegbauer.cc (revision 2466)
+++ wegbauer.cc (working copy)
@@ -1890,7 +1890,7 @@
weg_t * weg = gr->get_weg((waytype_t)besch->get_wtyp());

// keep faster ways or if it is the same way ... (@author prissi)
- if(weg->get_besch()==besch  ||  (weg->get_besch()->get_styp()==7  &&  gr->get_weg_nr(0)!=weg)  ||  keep_existing_ways  ||  (keep_existing_faster_ways  &&  weg->get_besch()->get_topspeed()>besch->get_topspeed()) || (gr->get_typ()==grund_t::monorailboden && (bautyp&elevated_flag)==0) ) {
+ if(weg->get_besch()==besch  ||  keep_existing_ways  ||  (keep_existing_faster_ways  &&  weg->get_besch()->get_topspeed()>besch->get_topspeed()) || (gr->get_typ()==grund_t::monorailboden && (bautyp&elevated_flag)==0) ) {
//nothing to be done
cost = 0;
}


As it is implemented this bug must be intended behavior. Maybe prissi can tell more?
Title: Re: Can't upgrade tram track
Post by: z9999 on May 16, 2009, 08:27:17 PM
Quote from: Dwachs on May 16, 2009, 08:13:46 PM
it happens only if there is a road and a tram track

That is this bug report.  ;D
Title: Re: Can't upgrade tram track
Post by: prissi on May 16, 2009, 08:49:46 PM
I think this was needed at some point, because otherwise tramway were built on tracks. But I think this can now savely go.
Title: Re: Can't upgrade tram track
Post by: Dwachs on May 16, 2009, 08:57:24 PM
gone in rev 2469 :)

@z9999: thank you for testing and your precise bug reports!