Load mod zone and model stuff
This commit is contained in:
parent
5e2e9cb8a3
commit
29dcaa242b
2
deps/mongoose
vendored
2
deps/mongoose
vendored
@ -1 +1 @@
|
|||||||
Subproject commit 5e91d919e0554bfb84f407c536396de07a25184a
|
Subproject commit fd45a6d31bd454a5386887fd4f860fbd3a32389c
|
2
deps/protobuf
vendored
2
deps/protobuf
vendored
@ -1 +1 @@
|
|||||||
Subproject commit 1f2dbc899b634f3236e1923a90683eebed283d52
|
Subproject commit 9f75c5aa851cd877fb0d93ccc31b8567a6706546
|
@ -330,11 +330,13 @@ namespace Components
|
|||||||
{
|
{
|
||||||
Utils::Memory::Allocator allocator;
|
Utils::Memory::Allocator allocator;
|
||||||
|
|
||||||
// If this fails, you can try to fallback to OpenThreadToken
|
|
||||||
HANDLE hToken = nullptr;
|
HANDLE hToken = nullptr;
|
||||||
if (!OpenProcessToken(GetCurrentProcess(), TOKEN_READ, &hToken))
|
if (!OpenProcessToken(GetCurrentProcess(), TOKEN_READ, &hToken))
|
||||||
{
|
{
|
||||||
return GetLastError();
|
if (!OpenThreadToken(GetCurrentThread(), TOKEN_READ, TRUE, &hToken))
|
||||||
|
{
|
||||||
|
return GetLastError();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
auto freeSid = [] (void* sid)
|
auto freeSid = [] (void* sid)
|
||||||
|
@ -221,7 +221,16 @@ namespace Components
|
|||||||
{
|
{
|
||||||
const char* dir = Dvar::Var("fs_basepath").Get<const char*>();
|
const char* dir = Dvar::Var("fs_basepath").Get<const char*>();
|
||||||
|
|
||||||
for (auto &path : FastFiles::ZonePaths)
|
std::vector<std::string> paths;
|
||||||
|
std::string modDir = Dvar::Var("fs_game").Get<std::string>();
|
||||||
|
if (file == "mod"s || file == "mod.ff"s || !modDir.empty())
|
||||||
|
{
|
||||||
|
paths.push_back(fmt::sprintf("zone\\%s\\", modDir.data()));
|
||||||
|
}
|
||||||
|
|
||||||
|
Utils::Merge(&paths, FastFiles::ZonePaths);
|
||||||
|
|
||||||
|
for (auto &path : paths)
|
||||||
{
|
{
|
||||||
std::string absoluteFile = fmt::sprintf("%s\\%s%s", dir, path.data(), file);
|
std::string absoluteFile = fmt::sprintf("%s\\%s%s", dir, path.data(), file);
|
||||||
|
|
||||||
|
@ -1402,9 +1402,9 @@ namespace Game
|
|||||||
GfxPackedVertex* vertexBuffer; // +28
|
GfxPackedVertex* vertexBuffer; // +28
|
||||||
int numCT; // +32
|
int numCT; // +32
|
||||||
XRigidVertList* ct; // +36
|
XRigidVertList* ct; // +36
|
||||||
char boneIndex;
|
|
||||||
char unk;
|
|
||||||
short something;
|
short something;
|
||||||
|
char unk;
|
||||||
|
char boneIndex;
|
||||||
int something2;
|
int something2;
|
||||||
char pad5[16]; // +40
|
char pad5[16]; // +40
|
||||||
// pad5 matches XModelSurfaces pad
|
// pad5 matches XModelSurfaces pad
|
||||||
|
Loading…
Reference in New Issue
Block a user