mirror of
https://github.com/AxioDL/PrimeWorldEditor.git
synced 2025-12-20 18:29:13 +00:00
Tweak cooking for MP1
This commit is contained in:
17
src/Core/Tweaks/CTweakCooker.cpp
Normal file
17
src/Core/Tweaks/CTweakCooker.cpp
Normal file
@@ -0,0 +1,17 @@
|
||||
#include "CTweakCooker.h"
|
||||
#include "Core/Resource/Cooker/CScriptCooker.h"
|
||||
|
||||
/** Cooker entry point */
|
||||
bool CTweakCooker::CookCTWK(CTweakData* pTweakData, IOutputStream& CTWK)
|
||||
{
|
||||
CStructRef TweakProperties = pTweakData->TweakData();
|
||||
CScriptCooker ScriptCooker(pTweakData->Game());
|
||||
ScriptCooker.WriteProperty(CTWK, TweakProperties.Property(), TweakProperties.DataPointer(), true);
|
||||
return true;
|
||||
}
|
||||
|
||||
bool CTweakCooker::CookNTWK(const std::vector<CTweakData*>& kTweaks, IOutputStream& NTWK)
|
||||
{
|
||||
// Unimplemented
|
||||
return false;
|
||||
}
|
||||
18
src/Core/Tweaks/CTweakCooker.h
Normal file
18
src/Core/Tweaks/CTweakCooker.h
Normal file
@@ -0,0 +1,18 @@
|
||||
#ifndef CTWEAKCOOKER_H
|
||||
#define CTWEAKCOOKER_H
|
||||
|
||||
#include "CTweakData.h"
|
||||
|
||||
/** Class responsible for cooking tweak data */
|
||||
class CTweakCooker
|
||||
{
|
||||
/** Private constructor */
|
||||
CTweakCooker() {}
|
||||
|
||||
public:
|
||||
/** Cooker entry point */
|
||||
static bool CookCTWK(CTweakData* pTweakData, IOutputStream& CTWK);
|
||||
static bool CookNTWK(const std::vector<CTweakData*>& kTweaks, IOutputStream& NTWK);
|
||||
};
|
||||
|
||||
#endif // CTWEAKCOOKER_H
|
||||
Reference in New Issue
Block a user