diff options
| author | SulfurNitride <SulfurNitride@users.noreply.github.com> | 2026-02-11 02:37:39 -0600 |
|---|---|---|
| committer | SulfurNitride <SulfurNitride@users.noreply.github.com> | 2026-02-11 02:37:39 -0600 |
| commit | 7ee008e150bc5bcf76082d726f719ee0fdfda982 (patch) | |
| tree | 27fb39be241fdb5ac2734c574de678977d1856d0 /libs/game_bethesda/src/games/morrowind/morrowindsavegame.h | |
Fluorine Manager: full Linux port of Mod Organizer 2
Complete native Linux port with FUSE-based virtual filesystem,
Proton/umu-run integration, and Flatpak packaging.
Key features:
- FUSE VFS replacing Windows USVFS (in-process + standalone helper for Flatpak)
- Proton/GE-Proton/umu-run launcher with env var forwarding
- Flatpak support (sandbox-aware VFS, NXM handler, umu-run)
- Wine prefix management UI
- Case-insensitive path resolution for Linux filesystems
- QSettings-safe INI handling (avoids Bethesda INI corruption)
- Portable instance support with auto-generated launcher scripts
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Diffstat (limited to 'libs/game_bethesda/src/games/morrowind/morrowindsavegame.h')
| -rw-r--r-- | libs/game_bethesda/src/games/morrowind/morrowindsavegame.h | 57 |
1 files changed, 57 insertions, 0 deletions
diff --git a/libs/game_bethesda/src/games/morrowind/morrowindsavegame.h b/libs/game_bethesda/src/games/morrowind/morrowindsavegame.h new file mode 100644 index 0000000..b4ea960 --- /dev/null +++ b/libs/game_bethesda/src/games/morrowind/morrowindsavegame.h @@ -0,0 +1,57 @@ +#ifndef MORROWINDSAVEGAME_H +#define MORROWINDSAVEGAME_H + +#include "gamebryosavegame.h" +#include "gamemorrowind.h" + +namespace MOBase +{ +class IPluginGame; +} + +class MorrowindSaveGame : public GamebryoSaveGame +{ +public: + MorrowindSaveGame(QString const& fileName, GameMorrowind const* game); + +public: // ISaveGame interface + // We need to override getName() because we do not read the level at + // the beginning. + virtual QString getName() const override; + + // The PC level is not pre-fetch for morrowind. + unsigned short getPCLevel() const override; + +public: + // Simple getters + QString getSaveName() const { return m_SaveName; } + float getPCCurrentHealth() const { return m_PCCurrentHealth; } + float getPCMaxHealth() const { return m_PCCMaxHealth; } + float getGameDays() const { return m_GameDays; } + +protected: + QString m_SaveName; + float m_PCCurrentHealth; + float m_PCCMaxHealth; + float m_GameDays; + +protected: + QImage readImageBGRA(GamebryoSaveGame::FileWrapper& file, unsigned long width, + unsigned long height, int scale, bool alpha) const; + + // We need to add the PC level here. + struct MorrowindDataFields : public DataFields + { + unsigned short PCLevel = 0; + }; + + // Fetch easy-to-access information. + void fetchInformationFields(FileWrapper& file, QString& saveName, + QStringList& plugins, float& playerCurrentHealth, + float& playerMaxHealth, QString& playerLocation, + float& gameDays, QString& playerName) const; + + std::unique_ptr<DataFields> fetchDataFields() const override; +}; + +#endif // MORROWINDSAVEGAME_H |
