mirror of
https://github.com/huderlem/porymap.git
synced 2026-08-19 23:25:09 -05:00
begin work on wild pokemon editor
This commit is contained in:
31
include/core/wildmoninfo.h
Normal file
31
include/core/wildmoninfo.h
Normal file
@@ -0,0 +1,31 @@
|
||||
#ifndef GUARD_WILDMONINFO_H
|
||||
#define GUARD_WILDMONINFO_H
|
||||
|
||||
#include <QtWidgets>
|
||||
|
||||
struct WildPokemon {
|
||||
int minLevel;
|
||||
int maxLevel;
|
||||
QString species;
|
||||
};
|
||||
|
||||
struct WildMonInfo {
|
||||
//
|
||||
bool active = false;
|
||||
int encounterRate;
|
||||
QVector<WildPokemon> wildPokemon;
|
||||
};
|
||||
|
||||
struct WildPokemonHeader {
|
||||
WildMonInfo landMons;
|
||||
WildMonInfo waterMons;
|
||||
WildMonInfo rockSmashMons;
|
||||
WildMonInfo fishingMons;
|
||||
};
|
||||
|
||||
class Project;
|
||||
QWidget *newSpeciesTableEntry(Project *project, WildPokemon mon, int index);
|
||||
void createSpeciesTableRow(Project *, QTableWidget *, WildPokemon, int);
|
||||
void clearTabWidget(QLayout *tab);
|
||||
|
||||
#endif // GUARD_WILDMONINFO_H
|
||||
@@ -61,6 +61,8 @@ public:
|
||||
void setEditingCollision();
|
||||
void setEditingObjects();
|
||||
void setEditingConnections();
|
||||
void setEditingWildMons();
|
||||
void clearWildMonTabWidgets();
|
||||
void setCurrentConnectionDirection(QString curDirection);
|
||||
void updateCurrentConnectionDirection(QString curDirection);
|
||||
void setConnectionsVisibility(bool visible);
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
#include "blockdata.h"
|
||||
#include "heallocation.h"
|
||||
#include "event.h"
|
||||
#include "wildmoninfo.h"
|
||||
#include "parseutil.h"
|
||||
|
||||
#include <QStringList>
|
||||
@@ -83,6 +84,12 @@ public:
|
||||
QString readMapLayoutId(QString map_name);
|
||||
QString readMapLocation(QString map_name);
|
||||
|
||||
void readWildMonData();
|
||||
QMap<QString, WildPokemonHeader> wildMonData;// "MAP_CONSTANT": wild_encounter_json
|
||||
// when saving, preserve the extra fields for gBattlePyramidWildMonHeaders, gBattlePikeWildMonHeaders
|
||||
void readSpeciesIconPaths();
|
||||
QMap<QString, QString> speciesToIconPath;
|
||||
|
||||
QMap<QString, bool> getTopLevelMapFields();
|
||||
bool loadMapData(Map*);
|
||||
void readMapLayouts();
|
||||
|
||||
Reference in New Issue
Block a user