diff --git a/include/core/heallocation.h b/include/core/heallocation.h index 8867b100..fd00a22b 100644 --- a/include/core/heallocation.h +++ b/include/core/heallocation.h @@ -9,8 +9,7 @@ class HealLocation { public: HealLocation()=default; - HealLocation(QString, QString, int, uint16_t, uint16_t); - HealLocation(QString, QString, int, uint16_t, uint16_t, QString, uint16_t); + HealLocation(QString, QString, int, uint16_t, uint16_t, QString = "", uint16_t = 0); friend QDebug operator<<(QDebug debug, const HealLocation &hl); public: diff --git a/src/core/heallocation.cpp b/src/core/heallocation.cpp index 3653443d..e88d99e6 100644 --- a/src/core/heallocation.cpp +++ b/src/core/heallocation.cpp @@ -2,17 +2,6 @@ #include "config.h" #include "map.h" -HealLocation::HealLocation(QString id, QString map, int i, uint16_t x, uint16_t y) -{ - this->idName = id; - this->mapName = map; - this->index = i; - this->x = x; - this->y = y; - this->respawnMap = ""; - this->respawnNPC = 0; -} - HealLocation::HealLocation(QString id, QString map, int i, uint16_t x, uint16_t y, QString respawnMap, uint16_t respawnNPC) { this->idName = id; diff --git a/src/editor.cpp b/src/editor.cpp index aac160a3..2f8e38da 100644 --- a/src/editor.cpp +++ b/src/editor.cpp @@ -1137,11 +1137,13 @@ void Editor::displayMapMetatiles() { map_item->draw(true); scene->addItem(map_item); + int tw = 16; + int th = 16; scene->setSceneRect( - -BORDER_DISTANCE * 16, - -BORDER_DISTANCE * 16, - map_item->pixmap().width() + (BORDER_DISTANCE * 16) * 2, - map_item->pixmap().height() + (BORDER_DISTANCE * 16) * 2 + -BORDER_DISTANCE * tw, + -BORDER_DISTANCE * th, + map_item->pixmap().width() + BORDER_DISTANCE * 2 * tw, + map_item->pixmap().height() + BORDER_DISTANCE * 2 * th ); } diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index a0fcd6d0..e0e64da0 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -2203,7 +2203,7 @@ void MainWindow::on_pushButton_ChangeDimensions_clicked() QDialogButtonBox buttonBox(QDialogButtonBox::Ok | QDialogButtonBox::Cancel, Qt::Horizontal, &dialog); form.addRow(&buttonBox); - connect(&buttonBox, &QDialogButtonBox::accepted, [&dialog, &widthSpinBox, &heightSpinBox, &bwidthSpinBox, &bheightSpinBox, &errorLabel](){ + connect(&buttonBox, &QDialogButtonBox::accepted, [&dialog, &widthSpinBox, &heightSpinBox, &errorLabel](){ // Ensure width and height are an acceptable size. // The maximum number of metatiles in a map is the following: // max = (width + 15) * (height + 14)