mirror of
https://github.com/huderlem/porymap.git
synced 2026-08-19 23:25:09 -05:00
Add Import Map from Advance Map 1.92 feature.
This commit is contained in:
16
include/core/mapparser.h
Normal file
16
include/core/mapparser.h
Normal file
@@ -0,0 +1,16 @@
|
||||
#ifndef MAPPARSER_H
|
||||
#define MAPPARSER_H
|
||||
|
||||
#include "maplayout.h"
|
||||
#include "project.h"
|
||||
#include <QList>
|
||||
#include <QString>
|
||||
|
||||
class MapParser
|
||||
{
|
||||
public:
|
||||
MapParser();
|
||||
MapLayout *parse(QString filepath, bool *error, Project *project);
|
||||
};
|
||||
|
||||
#endif // MAPPARSER_H
|
||||
@@ -131,8 +131,10 @@ private slots:
|
||||
void onTilesetsSaved(QString, QString);
|
||||
void onWildMonDataChanged();
|
||||
void openNewMapPopupWindow(int, QVariant);
|
||||
void openNewMapPopupWindowImportMap(MapLayout *);
|
||||
void onNewMapCreated();
|
||||
void onMapCacheCleared();
|
||||
void importMapFromAdvanceMap1_92();
|
||||
|
||||
void on_action_NewMap_triggered();
|
||||
void on_actionNew_Tileset_triggered();
|
||||
@@ -189,6 +191,7 @@ private slots:
|
||||
|
||||
void on_action_Export_Map_Image_triggered();
|
||||
void on_actionExport_Stitched_Map_Image_triggered();
|
||||
void on_actionImport_Map_from_Advance_Map_1_92_triggered();
|
||||
|
||||
void on_comboBox_ConnectionDirection_currentIndexChanged(const QString &arg1);
|
||||
void on_spinBox_ConnectionOffset_valueChanged(int offset);
|
||||
|
||||
@@ -89,6 +89,7 @@ public:
|
||||
Tileset* loadTileset(QString, Tileset *tileset = nullptr);
|
||||
Tileset* getTileset(QString, bool forceLoad = false);
|
||||
QMap<QString, QStringList> tilesetLabels;
|
||||
QList<QString> tilesetLabelsOrdered;
|
||||
|
||||
Blockdata* readBlockdata(QString);
|
||||
bool loadBlockdata(Map*);
|
||||
@@ -99,7 +100,7 @@ public:
|
||||
|
||||
bool readMapGroups();
|
||||
Map* addNewMapToGroup(QString mapName, int groupNum);
|
||||
Map* addNewMapToGroup(QString, int, Map*, bool);
|
||||
Map* addNewMapToGroup(QString, int, Map*, bool, bool);
|
||||
QString getNewMapName();
|
||||
QString getProjectTitle();
|
||||
|
||||
|
||||
@@ -20,8 +20,10 @@ public:
|
||||
Map *map;
|
||||
int group;
|
||||
bool existingLayout;
|
||||
bool importedMap;
|
||||
QString layoutId;
|
||||
void init(int, int, QString, QString);
|
||||
void initImportMap(MapLayout *);
|
||||
void useLayout(QString);
|
||||
void connectSignals();
|
||||
|
||||
@@ -32,6 +34,7 @@ private:
|
||||
Ui::NewMapPopup *ui;
|
||||
Project *project;
|
||||
void setDefaultValues(int, QString);
|
||||
void setDefaultValuesImportMap(MapLayout *);
|
||||
bool checkNewMapDimensions();
|
||||
|
||||
private slots:
|
||||
|
||||
Reference in New Issue
Block a user