Skip to content

Commit

Permalink
Updated how yaml-cpp works with the project
Browse files Browse the repository at this point in the history
Also changed how hex textboxes work again.
  • Loading branch information
Sierraffinity committed Feb 5, 2017
1 parent d2b1466 commit f23f8db
Show file tree
Hide file tree
Showing 6 changed files with 398 additions and 144 deletions.
4 changes: 2 additions & 2 deletions AwesomeMapEditor.pro
Expand Up @@ -50,12 +50,12 @@ QMAKE_LFLAGS += -static-libgcc -static-libstdc++
#
CONFIG(debug, debug|release) {
unix|win32: LIBS += -L$$PWD/../QBoy/bin/debug/ -lQBoy
unix|win32: LIBS += -L$$PWD/../yaml-cpp/bin/debug/ -lyaml-cpp
} else {
unix|win32: LIBS += -L$$PWD/../QBoy/bin/release/ -lQBoy
unix|win32: LIBS += -L$$PWD/../yaml-cpp/bin/release/ -lyaml-cpp
}

unix|win32: LIBS += -L$$PWD/../yaml-cpp/bin/ -lyaml-cpp


#
# Source Files
Expand Down
10 changes: 5 additions & 5 deletions README.md
Expand Up @@ -6,17 +6,17 @@ Awesome Map Editor (AME) is a map editor for 3rd generation Pokémon games: Ruby
[yaml-cpp](https://github.com/jbeder/yaml-cpp)

## Getting Started
1. Place the dependencies in the same directory as the AME root.
1. Place the dependencies in the same directory as the AME root.

2. Copy `yaml-cpp.pro` from `deps` and paste it into the `yaml-cpp` root.
2. Open all the projects in Qt and set their build directories to `bin`. For yaml-cpp, open the `CMakeLists.txt` file and ensure BUILD_SHARED_LIBS is enabled in its project settings.

3. Open all the projects in Qt and set the dependencies' build directories to `bin` (relative to their individual roots). Build them!
3. Build them all, working forwards from yaml-cpp to QBoy to AME itself.

4. Copy the `resources/config` folder into the AME executable directory.

Now you can help us develop the future of Pokémon ROM hacking!

## Credits
**Pokedude** - Developer

**Diegoisawesome** - Developer

**Pokedude** - Developer
86 changes: 0 additions & 86 deletions deps/yaml-cpp.pro

This file was deleted.

25 changes: 19 additions & 6 deletions include/AME/Widgets/QHexSpinBox.h
Expand Up @@ -7,17 +7,30 @@ class QHexSpinBox: public QSpinBox
{
Q_OBJECT

Q_PROPERTY(int byteLength READ byteLength WRITE setByteLength)
Q_PROPERTY(bool upperCase READ upperCase WRITE setUpperCase)

public:
QHexSpinBox( QWidget * parent = 0) :
QSpinBox(parent)
QSpinBox(parent),
m_byteLength(0),
m_upperCase(false)
{
}

virtual QString textFromValue ( int value ) const
{
/* 4 - number of digits, 10 - base of number, '0' - pad character*/
return QString("%1").arg(value, 2 , 16, QChar('0')).toUpper();
}
virtual QString textFromValue (int value) const;
virtual StepEnabled stepEnabled() const;

int byteLength() const;
void setByteLength(int length);

bool upperCase() const;
void setUpperCase(bool ucase);

private:
int m_byteLength;
bool m_upperCase;

};

#endif // QHEXSPINBOX_H

0 comments on commit f23f8db

Please sign in to comment.