equal
deleted
inserted
replaced
9 { |
9 { |
10 protected: |
10 protected: |
11 RailTypes m_compatible_railtypes; |
11 RailTypes m_compatible_railtypes; |
12 |
12 |
13 public: |
13 public: |
14 void SetDestination(Vehicle* v) |
14 void SetDestination(const Vehicle* v) |
15 { |
15 { |
16 m_compatible_railtypes = v->u.rail.compatible_railtypes; |
16 m_compatible_railtypes = v->u.rail.compatible_railtypes; |
17 } |
17 } |
18 |
18 |
19 bool IsCompatibleRailType(RailType rt) |
19 bool IsCompatibleRailType(RailType rt) |
82 // return the tile of our target coordinates |
82 // return the tile of our target coordinates |
83 return TileXY(x, y); |
83 return TileXY(x, y); |
84 } |
84 } |
85 |
85 |
86 public: |
86 public: |
87 void SetDestination(Vehicle* v) |
87 void SetDestination(const Vehicle* v) |
88 { |
88 { |
89 switch (v->current_order.GetType()) { |
89 switch (v->current_order.GetType()) { |
90 case OT_GOTO_STATION: |
90 case OT_GOTO_STATION: |
91 m_destTile = CalcStationCenterTile(v->current_order.GetDestination()); |
91 m_destTile = CalcStationCenterTile(v->current_order.GetDestination()); |
92 m_dest_station_id = v->current_order.GetDestination(); |
92 m_dest_station_id = v->current_order.GetDestination(); |