mirror of
https://github.com/MaSzyna-EU07/maszyna.git
synced 2026-07-21 00:09:19 +02:00
cross event detection also without :, bring highlight on map to front
This commit is contained in:
@@ -59,6 +59,8 @@ bool node_groups::assign_cross_switch(map::track_switch& sw, TTrack* track, std:
|
||||
sw_name.pop_back();
|
||||
|
||||
sw.action[idx] = simulation::Events.FindEvent(sw_name + ":" + id);
|
||||
if (!sw.action[idx])
|
||||
sw.action[idx] = simulation::Events.FindEvent(sw_name + id);
|
||||
|
||||
if (!sw.action[idx])
|
||||
return false;
|
||||
@@ -161,7 +163,7 @@ node_groups::update_map()
|
||||
char lastc = sw_name.back();
|
||||
sw_name.pop_back();
|
||||
|
||||
if (!simulation::Events.FindEvent(sw_name + ":ac"))
|
||||
if (!(simulation::Events.FindEvent(sw_name + ":ac") || simulation::Events.FindEvent(sw_name + "ac")))
|
||||
continue;
|
||||
|
||||
if (!last_switch || last_switch->name != sw_name) {
|
||||
|
||||
Reference in New Issue
Block a user