CommonLibSSE (Parapets fork)
MergeMapper.h
Go to the documentation of this file.
1 // SPDX-License-Identifier: Apache-2.0
2 #pragma once
3 
4 #include "RE/B/BSCoreTypes.h"
5 
6 namespace SKSE
7 {
8  constexpr const auto MergeMapperPluginName = "MergeMapper";
9  // A message used to fetch MergeMapper's interface
11  {
12  enum : uint32_t
13  {
14  kMessage_GetInterface = 0xe6cb8b59
15  }; // Randomly generated
16  void* (*GetApiFunction)(unsigned int revisionNumber) = nullptr;
17  };
18 
19  // Returns an IMergeMapperInterface001 object compatible with the API shown below
20  // This should only be called after SKSE sends kMessage_PostLoad to your plugin
23 
24  // This object provides access to MergeMapper's mod support API
26  {
27  // Gets the MergeMapper build number
28  virtual unsigned int GetBuildNumber() = 0;
29 
35  virtual std::pair<const char*, RE::FormID> GetNewFormID(const char* oldName, const RE::FormID oldFormID) = 0;
36 
42  virtual std::pair<const char*, RE::FormID> GetOriginalFormID(const char* newName, const RE::FormID newFormID) = 0;
43 
47  virtual bool isMerge(const char* modName) = 0;
48 
52  virtual bool wasMerged(const char* modName) = 0;
53  };
54 }
std::uint32_t FormID
Definition: BSCoreTypes.h:5
Definition: API.h:14
constexpr const auto MergeMapperPluginName
Definition: MergeMapper.h:8
IMergeMapperInterface001 * GetMergeMapperInterface() noexcept
Definition: MergeMapper.h:26
virtual bool isMerge(const char *modName)=0
Whether modName is a zmerge output file. To find old file use GetOldFormID(modName,...
virtual unsigned int GetBuildNumber()=0
virtual std::pair< const char *, RE::FormID > GetOriginalFormID(const char *newName, const RE::FormID newFormID)=0
Get the original modName and formID.
virtual bool wasMerged(const char *modName)=0
Whether modName was an input to a zmerge file. To find new file use GetNewFormID(modName,...
virtual std::pair< const char *, RE::FormID > GetNewFormID(const char *oldName, const RE::FormID oldFormID)=0
Get the new modName and formID.
Definition: MergeMapper.h:11
@ kMessage_GetInterface
Definition: MergeMapper.h:14