fix formatting

This commit is contained in:
Evil Factory
2022-05-21 12:48:35 -03:00
parent c9e13ad412
commit 7ee81aca24
2 changed files with 5 additions and 6 deletions

View File

@@ -225,7 +225,8 @@ namespace Barotrauma
private static readonly string[] prohibitedHooks = {
"Barotrauma.Lua",
"Barotrauma.Cs"
"Barotrauma.Cs",
"ContentPackageManager",
};
public void HookMethod(string identifier, MethodInfo method, LuaCsPatch patch, HookMethodType hookType = HookMethodType.Before, ACsMod owner = null)
{

View File

@@ -39,7 +39,7 @@ namespace Barotrauma
public const bool IsClient = true;
#endif
private static int ExecutionNumber = 0;
private static int executionNumber = 0;
private Script lua;
public CsScriptRunner CsScript { get; private set; }
@@ -416,7 +416,7 @@ namespace Barotrauma
lua.Globals["Networking"] = Networking;
lua.Globals["Steam"] = Steam;
lua.Globals["ExecutionNumber"] = ExecutionNumber;
lua.Globals["ExecutionNumber"] = executionNumber;
lua.Globals["SERVER"] = IsServer;
lua.Globals["CLIENT"] = IsClient;
@@ -458,8 +458,6 @@ modding needs.
var modTypes = CsScriptLoader.Compile();
modTypes.ForEach(t =>
{
//Please register `t` in lua-side
//UserData.RegisterType(t);
t.GetConstructor(new Type[] { })?.Invoke(null);
});
}
@@ -504,7 +502,7 @@ modding needs.
PrintError("LuaSetup.lua not found! Lua/LuaSetup.lua, no Lua scripts will be executed or work.");
}
ExecutionNumber++;
executionNumber++;
}
}