# HG changeset patch # User terkhen # Date 2010-07-09 16:43:00 # Node ID 95dabb8cf50dd201160b61a3c101c7c977cc6f95 # Parent 46e2c17b11f161b7a3ca99a1846ab7ef3e359c38 (svn r20100) -Fix: Give priority to ownership errors while removing rails. diff --git a/src/rail_cmd.cpp b/src/rail_cmd.cpp --- a/src/rail_cmd.cpp +++ b/src/rail_cmd.cpp @@ -770,6 +770,9 @@ static CommandCost CmdRailTrackHelper(Ti if (HasBit(p2, 8)) return last_error; break; } + + /* Ownership errors are more important. */ + if (last_error.GetErrorMessage() == STR_ERROR_OWNED_BY && remove) break; } else { had_success = true; total_cost.AddCost(ret);