News:

Simutrans Wiki Manual
The official on-line manual for Simutrans. Read and contribute.

city bridges to be created as unowned

Started by asaphxiix, January 20, 2013, 02:31:04 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

asaphxiix

Hello,

Currently, while city roads are unowned, bridges within the city are created as public property and cannot be modified in multiplayer etc.

Assuming this isn't intentional, might it be changed so they are created as unowned?

Thanks!

prissi

No bridges need a owner (at least it was such still the last time I tested). This is intentional.

asaphxiix

thank prissi, i'm not sure I understand - currently the bridges in the cities have an owner - the public player - so they cannot be modified by another player. Is this what you meant to say?

I wonder what is the logic behind this.

Ters

I think he meant that they must have an owner and thus can't be unowned like city roads. (Bridges are conceptually more than just road.) There are no tools in Simutrans to change the owner of something that I'm aware of, except to public player.


Dwachs

here is a patch. It is mostly trivial: removing some checks, which imho are unnecessary. I could not find anything wrong with ownerless city bridges.
Parsley, sage, rosemary, and maggikraut.

prissi

I really wonder why the patch works. add_maintenance called with sp=NULL (of the way) will lead to sp->maintenae+= with sp =NULL while the current code check for no owner and just does nothing.

Dwachs

add_maintenance itself checks for valid pointer ;)
Parsley, sage, rosemary, and maggikraut.

Dwachs

this is now changed in r6312: cities will create bridges without owner, so players can delete them
Parsley, sage, rosemary, and maggikraut.