Feature #652

HandleSharingChange and its children

Added by Hirundo almost 11 years ago. Updated over 10 years ago.

Status:NewStart date:2009-11-26
Priority:NormalDue date:
Assignee:-% Done:

50%

Category:-
Target version:IS2.3

Description

Currently HandleSharingChange and the functions it calls are a little ugly to say the least. The main cause for this is that sharing changes make reserved paths etc invalid. This means that we e.g. don't know which tiles to unreserve when a train is deleted, so we have to check all tiles which is very expensive.

If we call this function while everything is still valid (reading the new settings in sharing_future), this could be done in a much nicer way.

Small code snippet as reminder to self:
CompanySharingSettingsEntry *settings_to_use = c->sharing_delay == 0 ? &c->sharing_future : &c->sharing_currrent;

History

#1 Updated by Hirundo almost 11 years ago

  • % Done changed from 0 to 50

The code restructuring is done, now it needs to be tested and debugged. This is (obviously and unfortunately) the hard part.

#2 Updated by Hirundo almost 11 years ago

Reminder to self: Bankruptcy / takeover needs a lot of fixing too.

#3 Updated by Ammler almost 11 years ago

  • Target version deleted (62)

#4 Updated by Hirundo over 10 years ago

  • Target version set to IS2.3

Also available in: Atom PDF