Skip to content

Commit 003bac2

Browse files
WIP: NDS Painting class for the C++ Core.
Also some style fixes as well.
1 parent 8bd9fe5 commit 003bac2

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

45 files changed

+314
-31
lines changed

include/Strings.hpp

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,16 +30,20 @@
3030
#include <string>
3131
#include <vector>
3232

33+
3334
namespace S2Editor {
3435
namespace Strings {
36+
/* GBA Strings. */
3537
extern const std::vector<std::string> GBACastNames_DE, GBACastNames_EN; // GBA Casts.
3638
extern const std::vector<std::string> GBASocialMoveNames_DE, GBASocialMoveNames_EN; // GBA Social Moves.
3739
extern const std::vector<std::string> GBAEpisodeNames_DE, GBAEpisodeNames_EN; // GBA Episodes.
3840
extern const std::vector<std::string> GBASkillPointNames_DE, GBASkillPointNames_EN; // GBA Skill Points.
39-
extern const std::vector<std::string> GBAItemNames_EN; // GBA Item Names.
41+
extern const std::vector<std::string> GBAItemNames_EN; // GBA Items.
4042
extern const std::vector<std::string> GBAMinigameNames_DE, GBAMinigameNames_EN; // GBA Minigames.
4143

42-
extern const std::vector<std::string> NDSSkillPointNames_DE, NDSSkillPointNames_EN;
44+
/* NDS Strings. */
45+
extern const std::vector<std::string> NDSPaintingRankNames_EN; // NDS Painting Ranks.
46+
extern const std::vector<std::string> NDSSkillPointNames_DE, NDSSkillPointNames_EN; // NDS Skill Points.
4347
};
4448
};
4549

include/gba/GBACast.hpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,12 +29,14 @@
2929

3030
#include "../shared/CoreCommon.hpp"
3131

32+
3233
namespace S2Editor {
3334
enum class GBACastFeeling : uint8_t { Neutral, Friendly, Angry, Love, Invalid };
3435

3536
class GBACast {
3637
public:
37-
GBACast(const uint32_t Offs, const uint8_t Cast) : Cast(Cast), Offs(Offs) { };
38+
GBACast(const uint32_t Offs, const uint8_t Cast)
39+
: Cast(Cast), Offs(Offs) { };
3840
uint8_t Index() const { return this->Cast; };
3941

4042
/* Conversation Levels. */

include/gba/GBAEpisode.hpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,10 +29,12 @@
2929

3030
#include "../shared/CoreCommon.hpp"
3131

32+
3233
namespace S2Editor {
3334
class GBAEpisode {
3435
public:
35-
GBAEpisode(const uint8_t Slot, const uint8_t Episode, const uint8_t Move = 0x0) : Episode(Episode), Offs((Slot * 0x1000) + this->SetOffset(std::min<uint8_t>(Move, 10))) { };
36+
GBAEpisode(const uint8_t Slot, const uint8_t Episode, const uint8_t Move = 0x0)
37+
: Episode(Episode), Offs((Slot * 0x1000) + this->SetOffset(std::min<uint8_t>(Move, 10))) { };
3638
uint8_t Index() const { return this->Episode; };
3739

3840
uint8_t Rating(const uint8_t Category) const;

include/gba/GBAHouse.hpp

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,13 +27,15 @@
2727
#ifndef _SIM2EDITOR_CPP_CORE_GBA_HOUSE_HPP
2828
#define _SIM2EDITOR_CPP_CORE_GBA_HOUSE_HPP
2929

30-
#include "CoreCommon.hpp"
3130
#include "GBAHouseItem.hpp"
31+
#include "../shared/CoreCommon.hpp"
32+
3233

3334
namespace S2Editor {
3435
class GBAHouse {
3536
public:
36-
GBAHouse(const uint32_t Offset) : Offs(Offset) { };
37+
GBAHouse(const uint32_t Offset)
38+
: Offs(Offset) { };
3739

3840
uint8_t Roomdesign() const;
3941
void Roomdesign(const uint8_t V);

include/gba/GBAHouseItem.hpp

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,8 @@
2727
#ifndef _SIM2EDITOR_CPP_CORE_GBA_HOUSE_ITEM_HPP
2828
#define _SIM2EDITOR_CPP_CORE_GBA_HOUSE_ITEM_HPP
2929

30-
#include "CoreCommon.hpp"
30+
#include "../shared/CoreCommon.hpp"
31+
3132

3233
/*
3334
NOTE:
@@ -36,13 +37,12 @@
3637
Each item of the room changes the offsets to + 0x6 for data after 0xD6 of the SAVSlot.
3738
*/
3839
namespace S2Editor {
39-
enum class GBAHouseItemDirection : uint8_t {
40-
Right = 0x1, Down = 0x3, Left = 0x5, Up = 0x7, Invalid = 0xFF
41-
};
40+
enum class GBAHouseItemDirection : uint8_t { Right = 0x1, Down = 0x3, Left = 0x5, Up = 0x7, Invalid = 0xFF };
4241

4342
class GBAHouseItem {
4443
public:
45-
GBAHouseItem(const uint32_t Offset) : Offs(Offset) { };
44+
GBAHouseItem(const uint32_t Offset)
45+
: Offs(Offset) { };
4646

4747
uint8_t Count() const;
4848
void Count(const uint8_t V);

include/gba/GBAItem.hpp

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,8 @@
2727
#ifndef _SIM2EDITOR_CPP_CORE_GBA_ITEM_HPP
2828
#define _SIM2EDITOR_CPP_CORE_GBA_ITEM_HPP
2929

30-
#include "CoreCommon.hpp"
30+
#include "../shared/CoreCommon.hpp"
31+
3132

3233
/*
3334
NOTE:
@@ -42,7 +43,8 @@
4243
namespace S2Editor {
4344
class GBAItem {
4445
public:
45-
GBAItem(const uint32_t Offset) : Offs(Offset) { };
46+
GBAItem(const uint32_t Offset)
47+
: Offs(Offset) { };
4648

4749
uint8_t Count() const;
4850
void Count(const uint8_t V);

include/gba/GBAMinigame.hpp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,11 +29,12 @@
2929

3030
#include "../shared/CoreCommon.hpp"
3131

32+
3233
namespace S2Editor {
3334
class GBAMinigame {
3435
public:
35-
GBAMinigame(const uint32_t Offs, const uint8_t Game) : Game(std::min<uint8_t>(6, Game)), Offs(Offs) { };
36-
36+
GBAMinigame(const uint32_t Offs, const uint8_t Game)
37+
: Game(std::min<uint8_t>(6, Game)), Offs(Offs) { };
3738
uint8_t Index() const { return this->Game; };
3839

3940
bool Played() const;

include/gba/GBASav.hpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@
3030
#include "GBASettings.hpp"
3131
#include "GBASlot.hpp"
3232

33+
3334
namespace S2Editor {
3435
class GBASAV {
3536
public:

include/gba/GBASettings.hpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@
2929

3030
#include "../shared/CoreCommon.hpp"
3131

32+
3233
namespace S2Editor {
3334
/* GBA Languages. */
3435
enum class GBALanguage : uint8_t {

include/gba/GBASlot.hpp

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,18 +27,20 @@
2727
#ifndef _SIM2EDITOR_CPP_CORE_GBA_SLOT_HPP
2828
#define _SIM2EDITOR_CPP_CORE_GBA_SLOT_HPP
2929

30-
#include "CoreCommon.hpp"
3130
#include "GBACast.hpp"
3231
#include "GBAEpisode.hpp"
3332
#include "GBAHouse.hpp"
3433
#include "GBAItem.hpp"
3534
#include "GBAMinigame.hpp"
3635
#include "GBASocialMove.hpp"
36+
#include "../shared/CoreCommon.hpp"
37+
3738

3839
namespace S2Editor {
3940
class GBASlot {
4041
public:
41-
GBASlot(const uint8_t Slot) : Slot(Slot), Offs(Slot * 0x1000) { };
42+
GBASlot(const uint8_t Slot)
43+
: Slot(Slot), Offs(Slot * 0x1000) { };
4244

4345
/* Main things. */
4446
uint16_t Time() const;

0 commit comments

Comments
 (0)