mirror of
https://github.com/PodeCaradox/GalaxyQuest-SteamFrame.git
synced 2026-10-18 20:01:20 +02:00
The sources of Petari (https://github.com/SMGCommunity/Petari), the Super Mario Galaxy decompilation by the SMGCommunity, at commit 0a5c6608dc3b4c44a9aa68c2535d1793dc565f02, unchanged but for LF line endings: LICENSE (as LICENSE-Petari.txt; CC0 1.0), include/, libs/ and src/. Left out: the game data Petari keeps from the original executable, the error message archive (include/Game/System/ ErrorArchive.hpp) and two tables (src/Game/System/GalaxyID.bcsv and StoryEvent.bcsv); GalaxyQuest's converter takes them from the player's own disc. The port's changes follow in the next commit, so `git diff petari-base -- decomp` shows them. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
82 lines
2.7 KiB
C++
82 lines
2.7 KiB
C++
#pragma once
|
|
|
|
#include <revolution.h>
|
|
|
|
/// @brief The identifier of a File Selection Screen icon.
|
|
class FileSelectIconID {
|
|
public:
|
|
/// @brief The identifier of a Mario character icon.
|
|
enum EFellowID {
|
|
/// @brief The Mario icon.
|
|
Mario,
|
|
|
|
/// @brief The Luigi icon.
|
|
Luigi,
|
|
|
|
/// @brief The Yoshi icon.
|
|
Yoshi,
|
|
|
|
/// @brief The Toad icon.
|
|
Kinopio,
|
|
|
|
/// @brief The Peach icon.
|
|
Peach,
|
|
};
|
|
|
|
/// @brief Creates a new `FileSelectIconID`.
|
|
FileSelectIconID();
|
|
|
|
/// @brief Creates a new `FileSelectIconID`.
|
|
/// @param rOther The reference to the `FileSelectIconID` to copy from.
|
|
FileSelectIconID(const FileSelectIconID& rOther);
|
|
|
|
/// @brief Determines if `this` is equal to `rOther`.
|
|
/// @param rOther A reference to the `FileSelectIconID` to compare with.
|
|
/// @return `true` if `this` is equal to `other`, `false` otherwise.
|
|
bool operator==(const FileSelectIconID& rOther) const {
|
|
return mIsMii == rOther.mIsMii && mData == rOther.mData;
|
|
}
|
|
|
|
/// @brief Determines if `this` is inequal to `rOther`.
|
|
/// @param rOther A reference to the `FileSelectIconID` to compare with.
|
|
/// @return `true` if `this` is inequal to `other`, `false` otherwise.
|
|
bool operator!=(const FileSelectIconID& rOther) const {
|
|
return !(*this == rOther);
|
|
}
|
|
|
|
/// @brief Updates the value of each member variable.
|
|
/// @param rOther The reference to the `FileSelectIconID` to copy from.
|
|
void set(const FileSelectIconID& rOther);
|
|
|
|
/// @brief Updates the position of the Mii data in the Mii database.
|
|
/// @param miiIndex The new position of the Mii data.
|
|
void setMiiIndex(u16 miiIndex);
|
|
|
|
/// @brief Determines if the icon represents a Mii character.
|
|
/// @return `true` if the icon represents a Mii character, `false` otherwise.
|
|
bool isMii() const;
|
|
|
|
/// @brief Returns the position of the Mii data in the Mii database.
|
|
/// @return The position of the Mii data.
|
|
u16 getMiiIndex() const;
|
|
|
|
/// @brief Updates the identifier of the Mario character.
|
|
/// @param fellowID The new identifier of the Mario character.
|
|
void setFellowID(EFellowID fellowID);
|
|
|
|
/// @brief Determines if the icon represents a Mario character.
|
|
/// @return `true` if the icon represents a Mario character, `false` otherwise.
|
|
bool isFellow() const;
|
|
|
|
/// @brief Returns the identifier of the Mario character.
|
|
/// @return The identifier of the Mario character.
|
|
EFellowID getFellowID() const;
|
|
|
|
private:
|
|
/// @brief Determines if the icon represents a Mii character.
|
|
/* 0x0 */ bool mIsMii;
|
|
|
|
/// @brief The position of the Mii data in the Mii database or the identifier of a Mario character.
|
|
/* 0x2 */ u16 mData;
|
|
};
|