Skip to content

Commit 401c0b9

Browse files
authored
Merge pull request aburch#9 from jamespetts/master
get the lates bugfixes
2 parents c317b97 + 8300462 commit 401c0b9

2 files changed

Lines changed: 6 additions & 6 deletions

File tree

simtool.cc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2736,7 +2736,7 @@ const char* tool_build_bridge_t::get_tooltip(const player_t *) const
27362736
}
27372737
any_prohibitive = true;
27382738
char tmpbuf[30];
2739-
sprintf(tmpbuf, "Prohibitive %i", i);
2739+
sprintf(tmpbuf, "Prohibitive %i-%i", desc->get_wtyp(), i);
27402740
n += sprintf(toolstr + n, " ");
27412741
n += sprintf(toolstr + n, translator::translate(tmpbuf));
27422742
}
@@ -3056,7 +3056,7 @@ const char* tool_build_tunnel_t::get_tooltip(const player_t *) const
30563056
}
30573057
any_prohibitive = true;
30583058
char tmpbuf[30];
3059-
sprintf(tmpbuf, "Prohibitive %i", i);
3059+
sprintf(tmpbuf, "Prohibitive %i-%i", desc->get_wtyp(), i);
30603060
n += sprintf(toolstr + n, " ");
30613061
n += sprintf(toolstr + n, translator::translate(tmpbuf));
30623062
}

vehicle/simvehicle.cc

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4443,7 +4443,7 @@ bool rail_vehicle_t::can_enter_tile(const grund_t *gr, sint32 &restart_speed, ui
44434443
}
44444444
}
44454445

4446-
if(signal_current && (working_method == time_interval || working_method == time_interval_with_telegraph) && signal_current->get_state() == roadsign_t::danger && signal_current->get_no_junctions_to_next_signal() && (signal_current->get_desc()->get_working_method() != one_train_staff || !starting_from_stand))
4446+
if(signal_current && (working_method == time_interval || working_method == time_interval_with_telegraph) && signal_current->get_state() == roadsign_t::danger && !signal_current->get_desc()->is_choose_sign() && signal_current->get_no_junctions_to_next_signal() && (signal_current->get_desc()->get_working_method() != one_train_staff || !starting_from_stand))
44474447
{
44484448
restart_speed = 0;
44494449
return false;
@@ -4492,7 +4492,7 @@ bool rail_vehicle_t::can_enter_tile(const grund_t *gr, sint32 &restart_speed, ui
44924492

44934493
if (sig)
44944494
{
4495-
if ((sig->get_desc()->get_working_method() == working_method_t::time_interval || sig->get_desc()->get_working_method() == working_method_t::time_interval_with_telegraph) && sig->get_no_junctions_to_next_signal())
4495+
if ((sig->get_desc()->get_working_method() == working_method_t::time_interval || sig->get_desc()->get_working_method() == working_method_t::time_interval_with_telegraph) && sig->get_no_junctions_to_next_signal() && !sig->get_desc()->is_choose_sign())
44964496
{
44974497
// A time interval signal on plain track - do not engage the block reserver
44984498
allow_block_reserver = false;
@@ -4959,7 +4959,7 @@ bool rail_vehicle_t::can_enter_tile(const grund_t *gr, sint32 &restart_speed, ui
49594959
|| working_method == one_train_staff && shortest_distance(get_pos().get_2d(), signal->get_pos().get_2d()) < 2)
49604960
{
49614961
// Brake for the signal unless we can see it somehow. -1 because this is checked on entering the tile.
4962-
const bool allow_block_reserver = ((working_method != time_interval && working_method != time_interval_with_telegraph) || !signal->get_no_junctions_to_next_signal() || signal->get_state() != roadsign_t::danger) && ((signal->get_desc()->get_working_method() != one_train_staff && signal->get_desc()->get_working_method() != token_block) || route_index == next_block);
4962+
const bool allow_block_reserver = ((working_method != time_interval && working_method != time_interval_with_telegraph) || !signal->get_no_junctions_to_next_signal() || signal->get_desc()->is_choose_sign() || signal->get_state() != roadsign_t::danger) && ((signal->get_desc()->get_working_method() != one_train_staff && signal->get_desc()->get_working_method() != token_block) || route_index == next_block);
49634963
if(allow_block_reserver && !block_reserver(cnv->get_route(), next_block, modified_sighting_distance_tiles, next_signal, 0, true, false, cnv->get_is_choosing()))
49644964
{
49654965
restart_speed = 0;
@@ -6557,7 +6557,7 @@ sint32 rail_vehicle_t::block_reserver(route_t *route, uint16 start_index, uint16
65576557

65586558
bool last_signal_was_track_circuit_block = false;
65596559

6560-
if (no_junctions_to_last_signal && reached_end_of_loop && success && last_stop_signal_index < INVALID_INDEX)
6560+
if (no_junctions_to_last_signal && no_junctions_to_next_signal && reached_end_of_loop && success && last_stop_signal_index < INVALID_INDEX)
65616561
{
65626562
const grund_t* gr_signal = welt->lookup(route->at(last_stop_signal_index));
65636563
signal_t* signal = gr_signal->find<signal_t>();

0 commit comments

Comments
 (0)