* OpenTTD is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, version 2.
* OpenTTD is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
* See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with OpenTTD. If not, see <http://www.gnu.org/licenses/>.
*/
/** @file toolbar_gui.h Stuff related to the (main) toolbar. */
#ifndef TOOLBAR_GUI_H
#define TOOLBAR_GUI_H
void AllocateToolbar();
void ToggleBoundingBoxes();
void ToggleDirtyBlocks();
extern int16 *_preferred_toolbar_size;
#endif /* TOOLBAR_GUI_H */
src/viewport.cpp
➞
Show inline comments
@@ -38,24 +38,25 @@
#include "vehicle_gui.h"
#include "blitter/factory.hpp"
#include "strings_func.h"
#include "zoom_func.h"
#include "vehicle_func.h"
#include "company_func.h"
#include "waypoint_func.h"
#include "window_func.h"
#include "tilehighlight_func.h"
#include "window_gui.h"
#include "table/strings.h"
#include "table/palettes.h"
Point _tile_fract_coords;
struct StringSpriteToDraw {
StringID string;
Colours colour;
int32 x;
int32 y;
uint64 params[2];
uint16 width;
};
@@ -139,24 +140,26 @@ struct ViewportDrawer {
int foundation[FOUNDATION_PART_END]; ///< Foundation sprites (index into parent_sprites_to_draw).
FoundationPart foundation_part; ///< Currently active foundation for ground sprite drawing.
int *last_foundation_child[FOUNDATION_PART_END]; ///< Tail of ChildSprite list of the foundations. (index into child_screen_sprites_to_draw)
Point foundation_offset[FOUNDATION_PART_END]; ///< Pixel offset for ground sprites on the foundations.
};
static ViewportDrawer _vd;
TileHighlightData _thd;
static TileInfo *_cur_ti;
bool _draw_bounding_boxes = false;
bool _draw_dirty_blocks = false;
uint _dirty_block_colour = 0;
static Point MapXYZToViewport(const ViewPort *vp, int x, int y, int z)