mirror of
https://github.com/huderlem/porymap.git
synced 2026-09-13 19:35:40 -05:00
Populate scripts comboboxes with scripts found in map.json
This commit is contained in:
@@ -31,10 +31,10 @@ public:
|
||||
Event(const Event&);
|
||||
Event(QJsonObject, QString);
|
||||
public:
|
||||
int x() {
|
||||
int x() const {
|
||||
return getInt("x");
|
||||
}
|
||||
int y() {
|
||||
int y() const {
|
||||
return getInt("y");
|
||||
}
|
||||
int elevation() {
|
||||
@@ -46,16 +46,16 @@ public:
|
||||
void setY(int y) {
|
||||
put("y", y);
|
||||
}
|
||||
QString get(QString key) {
|
||||
QString get(const QString &key) const {
|
||||
return values.value(key);
|
||||
}
|
||||
int getInt(QString key) {
|
||||
int getInt(const QString &key) const {
|
||||
return values.value(key).toInt(nullptr, 0);
|
||||
}
|
||||
uint16_t getU16(QString key) {
|
||||
uint16_t getU16(const QString &key) const {
|
||||
return values.value(key).toUShort(nullptr, 0);
|
||||
}
|
||||
int16_t getS16(QString key) {
|
||||
int16_t getS16(const QString &key) const {
|
||||
return values.value(key).toShort(nullptr, 0);
|
||||
}
|
||||
void put(QString key, int value) {
|
||||
|
||||
@@ -83,7 +83,8 @@ public:
|
||||
void floodFillCollisionElevation(int x, int y, uint16_t collision, uint16_t elevation);
|
||||
void _floodFillCollisionElevation(int x, int y, uint16_t collision, uint16_t elevation);
|
||||
void magicFillCollisionElevation(int x, int y, uint16_t collision, uint16_t elevation);
|
||||
QList<Event*> getAllEvents();
|
||||
QList<Event*> getAllEvents() const;
|
||||
QStringList eventScriptLabels(const QString &event_group_type = QString()) const;
|
||||
void removeEvent(Event*);
|
||||
void addEvent(Event*);
|
||||
QPixmap renderConnection(MapConnection, MapLayout *);
|
||||
|
||||
Reference in New Issue
Block a user