mirror of
https://github.com/Laupetin/OpenAssetTools.git
synced 2025-04-20 00:02:55 +00:00
WIP
This commit is contained in:
parent
0f3ee1fa79
commit
421728d027
@ -56,8 +56,8 @@ namespace
|
||||
void CreateFromString(const std::string& templateString)
|
||||
{
|
||||
const auto templateStringLength = templateString.size();
|
||||
auto partStart = 0u;
|
||||
for (auto i = 0u; i < templateStringLength; i++)
|
||||
auto partStart = 0uz;
|
||||
for (auto i = 0uz; i < templateStringLength; i++)
|
||||
{
|
||||
if (templateString[i] != '?')
|
||||
continue;
|
||||
|
@ -245,7 +245,7 @@ void UnlinkerArgs::AddSpecifiedAssetType(std::string value)
|
||||
|
||||
void UnlinkerArgs::ParseCommaSeparatedAssetTypeString(const std::string& input)
|
||||
{
|
||||
auto currentPos = 0u;
|
||||
auto currentPos = 0uz;
|
||||
size_t endPos;
|
||||
|
||||
std::string lowerInput(input);
|
||||
|
@ -1,4 +1,5 @@
|
||||
#pragma once
|
||||
|
||||
#include "Game/IW4/IW4.h"
|
||||
#include "Loading/ContentLoaderBase.h"
|
||||
#include "Loading/IContentLoadingEntryPoint.h"
|
||||
@ -7,17 +8,18 @@ namespace IW4
|
||||
{
|
||||
class ContentLoader final : public ContentLoaderBase, public IContentLoadingEntryPoint
|
||||
{
|
||||
XAsset* varXAsset;
|
||||
ScriptStringList* varScriptStringList;
|
||||
public:
|
||||
ContentLoader();
|
||||
|
||||
void Load(Zone* zone, IZoneInputStream* stream) override;
|
||||
|
||||
private:
|
||||
void LoadScriptStringList(bool atStreamStart);
|
||||
|
||||
void LoadXAsset(bool atStreamStart) const;
|
||||
void LoadXAssetArray(bool atStreamStart, size_t count);
|
||||
|
||||
public:
|
||||
ContentLoader();
|
||||
|
||||
void Load(Zone* zone, IZoneInputStream* stream) override;
|
||||
XAsset* varXAsset;
|
||||
ScriptStringList* varScriptStringList;
|
||||
};
|
||||
} // namespace IW4
|
||||
|
@ -25,7 +25,7 @@ public:
|
||||
LoadDataInBlock(const_cast<void*>(reinterpret_cast<const void*>(dst)), sizeof(T));
|
||||
}
|
||||
|
||||
template<typename T> void Load(T* dst, const uint32_t count)
|
||||
template<typename T> void Load(T* dst, const size_t count)
|
||||
{
|
||||
LoadDataInBlock(const_cast<void*>(reinterpret_cast<const void*>(dst)), count * sizeof(T));
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user