Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System.IO;
- using System;
- using System.Collections.Generic;
- using System.ComponentModel;
- using System.Data;
- using System.Text;
- using WinApi;
- using WinApi.Kernel;
- using WinApi.FileFormat;
- namespace gothic_2_edit
- {
- class Program
- {
- public static void Main(string[] args)
- {
- Console.WriteLine("Kliknij ENTER by rozpocząć grę");
- Console.ReadLine();
- String dll = "NetInject.dll";
- if (!System.IO.File.Exists(dll))
- throw new Exception("Elementu " + dll + " nie znaleziono");
- System.Diagnostics.ProcessStartInfo psi = new System.Diagnostics.ProcessStartInfo();
- psi.WorkingDirectory = Environment.CurrentDirectory;
- psi.Arguments = "-zwindow";
- psi.FileName = "Gothic2.exe";
- WinApi.Process process = WinApi.Process.Start(psi);
- if (process.LoadLibary(dll) == IntPtr.Zero)
- Error.GetLastError();
- Console.ReadLine();
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment