static void Main(string[] args) { // load ThePit.exe var exePath = ConfigurationManager.AppSettings["ThePitExePath"]; var newExepath = ConfigurationManager.AppSettings["NewExePath"]; // modify it so we can load our mods ModGenerator generator = new ModGenerator(exePath); generator.BatchMakePublicMethodsAndVirtualize(Lines("classes.txt")); generator.BatchMakePublic(Lines("public_only_classes.txt")); // make some method calls virtual so we can override them generator.MakeCallVirtual("SelectPlayerScreen", "OnOpen", "PopulatePages"); generator.MakeCallVirtual("MainMenuScreen", "*compilergenerated*", "OpenLoadDialog"); generator.MakeCallVirtual("Game1", "UpdatePlayerInput", "UpdatePlayerActionInput"); // save the executable modifications generator.Save(newExepath); }