The International Simutrans Forum

 

Author Topic: [patch] bug fix code clean up in wegbauer  (Read 1296 times)

0 Members and 1 Guest are viewing this topic.

Offline Dwachs

  • DevTeam, Coder/patcher
  • Administrator
  • *
  • Posts: 4899
  • Languages: EN, DE, AT
[patch] bug fix code clean up in wegbauer
« on: July 30, 2010, 04:37:46 PM »
This patch should fix the bug reported here:

http://forum.simutrans.com/index.php?topic=5352.0

Moreover, it removes a lot of code duplication from wegbauer_t::is_allowed_step.

And it fixes a bug for building canals: there the check for right owner was never executed, which means one could build over other players canals (similar to roads).

Should this behavior be kept? Or fixed?

Please test and comment.

Offline prissi

  • Developer
  • Administrator
  • *
  • Posts: 10822
  • Languages: De,EN,JP
Re: [patch] bug fix code clean up in wegbauer
« Reply #1 on: July 30, 2010, 07:49:43 PM »
Player only seems a very good idea. However usually such changes have lots of subtle bugs, so maybe just include it and wait for bug reports?

EDIT: I can lay tram tracks into a road depot. That needs to be forbidden (and vice versa) otherwise I can move trams to road depots where they are lost forever.

Road vehicle in tram depot will crash simutrans even ...
« Last Edit: July 30, 2010, 08:01:23 PM by prissi »

Offline Dwachs

  • DevTeam, Coder/patcher
  • Administrator
  • *
  • Posts: 4899
  • Languages: EN, DE, AT
Re: [patch] bug fix code clean up in wegbauer
« Reply #2 on: August 03, 2010, 07:15:52 PM »
in rev 3608. longest log message ever :P