static void Main(string[] args) { string GZipResource = "ShinyRipper.ICSharpCode.SharpZipLib.dll"; string DrawingResource = "ShinyRipper.System.Drawing.Common.dll"; EmbeddedAssembly.Load(GZipResource, "ICSharpCode.SharpZipLib.dll"); EmbeddedAssembly.Load(DrawingResource, "System.Drawing.Common.dll"); AppDomain.CurrentDomain.AssemblyResolve += new ResolveEventHandler(CurrentDomain_AssemblyResolve); ShinyTools.Helpers.Console.WriteColor("S", ConsoleColor.Red, false); ShinyTools.Helpers.Console.WriteColor("H", ConsoleColor.Yellow, false); ShinyTools.Helpers.Console.WriteColor("I", ConsoleColor.Green, false); ShinyTools.Helpers.Console.WriteColor("N", ConsoleColor.Cyan, false); ShinyTools.Helpers.Console.WriteColor("Y", ConsoleColor.Blue, false); Console.Write(" Ripper v1.2.0 by "); ShinyTools.Helpers.Console.WriteColor("[hy]\n", ConsoleColor.Magenta); Console.Write("with research provided by "); ShinyTools.Helpers.Console.WriteColor("shrubbyfrog\n\n", ConsoleColor.Green); Console.WriteLine("FILES SUPPORTED ARE:\n" + "\x10 .cha (compressed)\n" + "\x10 .cha (uncompressed)\n" + "\x10 .zrs (compressed)\n\n" + "GAMES FULLY SUPPORTED:\n" + "\x10 Eversion\n" + "\x10 Eversion HD\n" + "\x10 Eversion HD (Steam)\n\n" + "GAMES PARTIALLY SUPPORTED\n" + "\x10 4Four\n" + "\x10 Pac-Shark\n" + "\x10 Castle Awesome\n" + "\x10 Zeta's World\n" + "====\n" ); if (args.Length < 1) { Console.WriteLine("Enter the path to the Shiny graphic archive."); args = new string[1] { Console.ReadLine() }; } if (args.Length < 2 || string.IsNullOrEmpty(args[1])) { ConsoleKeyInfo keyInfo; Console.WriteLine("Do you want to convert all transparent pixels? y/n"); do { while (!Console.KeyAvailable) { Thread.Sleep(10); } keyInfo = Console.ReadKey(true); if (keyInfo.Key == ConsoleKey.Y) { Func(args[0], true); } if (keyInfo.Key == ConsoleKey.N) { Func(args[0], false); } if (keyInfo.Key == ConsoleKey.Escape || keyInfo.Key == ConsoleKey.X) { QuitResult = "Cancelling application..."; ShinyTools.Helpers.Application.Quit(QuitResult, 1200, 0); } } while (keyInfo.Key != ConsoleKey.Y || keyInfo.Key != ConsoleKey.N || keyInfo.Key != ConsoleKey.Escape || keyInfo.Key != ConsoleKey.X); } }
static Assembly CurrentDomain_AssemblyResolve(object sender, ResolveEventArgs args) { return(EmbeddedAssembly.Get(args.Name)); }