Open Viproz opened 10 years ago
Thanks for taking this issue. I think the patcher options need some work.
Do you know if there is there a reason for pressing a key at all before exiting? It would be easier to automate if the patcher just printed a success or fail message and exited, wouldn't it?
I think just one command line argument will work fine. If you're working on Fougerite you need a 1st pass-only patched assembly in References. If you aren't working on Fougerite then you are installing Fougerite on a vanilla server, and you want both passes. Wouldn't it make sense to just check for "-1" and do 1st pass, otherwise do both passes?
how about?
public void AutoPatch ()
{
// if there is no FirstPass
if (rustAssembly.MainModule.GetType("Fougerite_Patched_FirstPass") == null)
FirstPass();
fougeriteAssembly = AssemblyDefinition.ReadAssembly("Fougerite.dll");
// if there is first, but no second pass, and there is fougerite.dll
if (rustAssembly.MainModule.GetType("Fougerite_Patched_FirstPass") != null && rustAssembly.MainModule.GetType("Fougerite_Patched_SecondPass") == null && fougeriteAssembly != null)
SecondPass();
}
Added the ability to enter the -1 and -2 parameters once the patcher is openned and added an error message for incorrect parameter Changed the readline of the end to a "Press any key to continue"