Overworld Tile32 save improvements
This commit is contained in:
@@ -372,7 +372,7 @@ void Canvas::DrawOutline(int x, int y, int w, int h) {
|
||||
canvas_p0_.y + scrolling_.y + y);
|
||||
ImVec2 size(canvas_p0_.x + scrolling_.x + x + w,
|
||||
canvas_p0_.y + scrolling_.y + y + h);
|
||||
draw_list_->AddRect(origin, size, IM_COL32(255, 255, 255, 255));
|
||||
draw_list_->AddRect(origin, size, IM_COL32(255, 255, 255, 200), 0, 0, 1.5f);
|
||||
}
|
||||
|
||||
void Canvas::DrawOutlineWithColor(int x, int y, int w, int h, ImVec4 color) {
|
||||
@@ -384,6 +384,15 @@ void Canvas::DrawOutlineWithColor(int x, int y, int w, int h, ImVec4 color) {
|
||||
IM_COL32(color.x, color.y, color.z, color.w));
|
||||
}
|
||||
|
||||
|
||||
void Canvas::DrawOutlineWithColor(int x, int y, int w, int h, uint32_t color) {
|
||||
ImVec2 origin(canvas_p0_.x + scrolling_.x + x,
|
||||
canvas_p0_.y + scrolling_.y + y);
|
||||
ImVec2 size(canvas_p0_.x + scrolling_.x + x + w,
|
||||
canvas_p0_.y + scrolling_.y + y + h);
|
||||
draw_list_->AddRect(origin, size, color);
|
||||
}
|
||||
|
||||
namespace {
|
||||
std::vector<int> GetTileIDsInGrid(int start_x, int start_y, int width,
|
||||
int height, int tile_size) {
|
||||
@@ -404,14 +413,6 @@ std::vector<int> GetTileIDsInGrid(int start_x, int start_y, int width,
|
||||
}
|
||||
} // namespace
|
||||
|
||||
void Canvas::DrawOutlineWithColor(int x, int y, int w, int h, uint32_t color) {
|
||||
ImVec2 origin(canvas_p0_.x + scrolling_.x + x,
|
||||
canvas_p0_.y + scrolling_.y + y);
|
||||
ImVec2 size(canvas_p0_.x + scrolling_.x + x + w,
|
||||
canvas_p0_.y + scrolling_.y + y + h);
|
||||
draw_list_->AddRect(origin, size, color);
|
||||
}
|
||||
|
||||
void Canvas::DrawSelectRect(int tile_size, float scale) {
|
||||
const ImGuiIO &io = ImGui::GetIO();
|
||||
static ImVec2 drag_start_pos;
|
||||
|
||||
Reference in New Issue
Block a user