Skip to content

Commit c5be8f1

Browse files
author
Liam
committed
Made loadstring compatible
1 parent a791282 commit c5be8f1

File tree

4 files changed

+4
-7
lines changed

4 files changed

+4
-7
lines changed

Lua Obfusactor/Lua Obfusactor.vcxproj

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -170,13 +170,13 @@
170170
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
171171
<ImportGroup Label="ExtensionTargets">
172172
<Import Project="..\packages\lua.redist.5.3.5.1\build\native\lua.redist.targets" Condition="Exists('..\packages\lua.redist.5.3.5.1\build\native\lua.redist.targets')" />
173-
<Import Project="..\packages\lua.5.3.5.1\build\native\lua.targets" Condition="Exists('..\packages\lua.5.3.5.1\build\native\lua.targets')" />
173+
<Import Project="..\packages\lua.5.4.1\build\native\Lua.targets" Condition="Exists('..\packages\lua.5.4.1\build\native\Lua.targets')" />
174174
</ImportGroup>
175175
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
176176
<PropertyGroup>
177177
<ErrorText>This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText>
178178
</PropertyGroup>
179179
<Error Condition="!Exists('..\packages\lua.redist.5.3.5.1\build\native\lua.redist.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\lua.redist.5.3.5.1\build\native\lua.redist.targets'))" />
180-
<Error Condition="!Exists('..\packages\lua.5.3.5.1\build\native\lua.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\lua.5.3.5.1\build\native\lua.targets'))" />
180+
<Error Condition="!Exists('..\packages\lua.5.4.1\build\native\Lua.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\lua.5.4.1\build\native\Lua.targets'))" />
181181
</Target>
182182
</Project>

Lua Obfusactor/Lua Obfusactor.vcxproj.filters

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,6 @@
2525
</Image>
2626
</ItemGroup>
2727
<ItemGroup>
28-
<ClInclude Include="resource.h">
29-
<Filter>Header Files</Filter>
30-
</ClInclude>
3128
<ClInclude Include="obfuscator.h">
3229
<Filter>Header Files</Filter>
3330
</ClInclude>

Lua Obfusactor/obfuscator.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ void file_loop(std::string dir) {
8787

8888
std::ofstream obfFile(entry.path());
8989

90-
obfFile << "load(\"" << obfCode << "\")()";
90+
obfFile << "local loading = load or loadstring\nloading(\"" << obfCode << "\")()";
9191

9292
obfFile.close();
9393
completedFiles++;

Lua Obfusactor/packages.config

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<packages>
3-
<package id="lua" version="5.3.5.1" targetFramework="native" />
3+
<package id="lua" version="5.4.1" targetFramework="native" />
44
<package id="lua.redist" version="5.3.5.1" targetFramework="native" />
55
</packages>

0 commit comments

Comments
 (0)