Skip to content

Commit

Permalink
Don't apply the patch unless a level has been set
Browse files Browse the repository at this point in the history
  • Loading branch information
michael-fadely committed Dec 3, 2016
1 parent 08f8b0c commit ab1640b
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions sadx-test-spawn/mod.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,6 @@ extern "C"

__declspec(dllexport) void __cdecl Init(const char* path, const HelperFunctions& helperFunctions)
{
WriteJump((void*)0x0040C115, ForceTrialMode);

int argc = 0;
LPWSTR* argv = CommandLineToArgvW(GetCommandLineW(), &argc);

Expand Down Expand Up @@ -84,6 +82,11 @@ extern "C"
}
}

if (level_set || act_set)
{
WriteJump((void*)0x0040C115, ForceTrialMode);
}

LocalFree(argv);
}
}

0 comments on commit ab1640b

Please sign in to comment.