mirror of
https://github.com/TES3MP/openmw-tes3mp.git
synced 2025-01-28 21:15:34 +00:00
60bc7447d9
The usage of const_cast has been replaced with usage of MWWorld::getModifiableStore() and ESMStore::overrideRecord() Methods whose names started with "update" now start with "override", for consistency with ESMStore's overrideRecord() New methods have been added for "overriding" enchantment, potion and spell records, which actually leads to them being created with their already set refIds if they haven't been created yet, as per the description of ESMStore::overrideRecord(): "Insert a record with set ID, and allow it to override a pre-existing static record." Usage of RecordHelper methods has been updated in DedicatedPlayer.
24 lines
735 B
C++
24 lines
735 B
C++
#ifndef OPENMW_RECORDHELPER_HPP
|
|
#define OPENMW_RECORDHELPER_HPP
|
|
|
|
#include <components/esm/loadcrea.hpp>
|
|
#include <components/esm/loadnpc.hpp>
|
|
|
|
namespace RecordHelper
|
|
{
|
|
bool doesCreatureExist(const std::string& refId);
|
|
bool doesRaceExist(const std::string& raceId);
|
|
|
|
std::string createCreatureRecord(const ESM::Creature& creature);
|
|
std::string createNpcRecord(const ESM::NPC& npc);
|
|
|
|
void overrideCreatureRecord(const ESM::Creature& creature);
|
|
void overrideNpcRecord(const ESM::NPC& npc);
|
|
|
|
void overrideEnchantmentRecord(const ESM::Enchantment& enchantment);
|
|
void overridePotionRecord(const ESM::Potion& potion);
|
|
void overrideSpellRecord(const ESM::Spell& spell);
|
|
}
|
|
|
|
|
|
#endif //OPENMW_RECORDHELPER_HPP
|