mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-02-02 04:13:26 +00:00
(svn r16870) -Codechange: unmagicify road stop/waypoint picker drawing
This commit is contained in:
parent
861a2163f6
commit
2b374824dc
@ -1814,7 +1814,7 @@ struct BuildRailWaypointWindow : PickerWindowBase {
|
||||
if (this->hscroll.pos + i < this->hscroll.count) {
|
||||
const StationSpec *statspec = GetCustomStationSpec(STAT_CLASS_WAYP, this->hscroll.pos + i);
|
||||
|
||||
DrawWaypointSprite(2 + i * 68, 25, this->hscroll.pos + i, _cur_railtype);
|
||||
DrawWaypointSprite(this->widget[BRWW_WAYPOINT_1 + i].left + TILE_PIXELS, this->widget[BRWW_WAYPOINT_1 + i].bottom - TILE_PIXELS, this->hscroll.pos + i, _cur_railtype);
|
||||
|
||||
if (statspec != NULL &&
|
||||
HasBit(statspec->callbackmask, CBM_STATION_AVAIL) &&
|
||||
|
@ -947,13 +947,13 @@ struct BuildRoadStationWindow : public PickerWindowBase {
|
||||
|
||||
StationType st = (this->window_class == WC_BUS_STATION) ? STATION_BUS : STATION_TRUCK;
|
||||
|
||||
StationPickerDrawSprite(103, 35, st, INVALID_RAILTYPE, ROADTYPE_ROAD, 0);
|
||||
StationPickerDrawSprite(103, 85, st, INVALID_RAILTYPE, ROADTYPE_ROAD, 1);
|
||||
StationPickerDrawSprite( 35, 85, st, INVALID_RAILTYPE, ROADTYPE_ROAD, 2);
|
||||
StationPickerDrawSprite( 35, 35, st, INVALID_RAILTYPE, ROADTYPE_ROAD, 3);
|
||||
StationPickerDrawSprite(this->widget[BRSW_STATION_NE].left + TILE_PIXELS, this->widget[BRSW_STATION_NE].bottom - TILE_PIXELS, st, INVALID_RAILTYPE, ROADTYPE_ROAD, DIAGDIR_NE);
|
||||
StationPickerDrawSprite(this->widget[BRSW_STATION_SE].left + TILE_PIXELS, this->widget[BRSW_STATION_SE].bottom - TILE_PIXELS, st, INVALID_RAILTYPE, ROADTYPE_ROAD, DIAGDIR_SE);
|
||||
StationPickerDrawSprite(this->widget[BRSW_STATION_SW].left + TILE_PIXELS, this->widget[BRSW_STATION_SW].bottom - TILE_PIXELS, st, INVALID_RAILTYPE, ROADTYPE_ROAD, DIAGDIR_SW);
|
||||
StationPickerDrawSprite(this->widget[BRSW_STATION_NW].left + TILE_PIXELS, this->widget[BRSW_STATION_NW].bottom - TILE_PIXELS, st, INVALID_RAILTYPE, ROADTYPE_ROAD, DIAGDIR_NW);
|
||||
|
||||
StationPickerDrawSprite(171, 35, st, INVALID_RAILTYPE, _cur_roadtype, 4);
|
||||
StationPickerDrawSprite(171, 85, st, INVALID_RAILTYPE, _cur_roadtype, 5);
|
||||
StationPickerDrawSprite(this->widget[BRSW_STATION_X].left + TILE_PIXELS, this->widget[BRSW_STATION_X].bottom - TILE_PIXELS, st, INVALID_RAILTYPE, _cur_roadtype, DIAGDIR_END + AXIS_X);
|
||||
StationPickerDrawSprite(this->widget[BRSW_STATION_Y].left + TILE_PIXELS, this->widget[BRSW_STATION_Y].bottom - TILE_PIXELS, st, INVALID_RAILTYPE, _cur_roadtype, DIAGDIR_END + AXIS_Y);
|
||||
|
||||
/* strings such as 'Size' and 'Coverage Area' */
|
||||
StationCoverageType sct = (this->window_class == WC_BUS_STATION) ? SCT_PASSENGERS_ONLY : SCT_NON_PASSENGERS_ONLY;
|
||||
|
@ -39,9 +39,6 @@ void WaypointsDailyLoop()
|
||||
*/
|
||||
void DrawWaypointSprite(int x, int y, int stat_id, RailType railtype)
|
||||
{
|
||||
x += 33;
|
||||
y += 17;
|
||||
|
||||
if (!DrawStationTile(x, y, railtype, AXIS_X, STAT_CLASS_WAYP, stat_id)) {
|
||||
StationPickerDrawSprite(x, y, STATION_WAYPOINT, railtype, INVALID_ROADTYPE, AXIS_X);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user