ItsMods

Full Version: Plugin that show the process id of a server
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
I know C and autoit and C# seem similar, i can try to make it, thanks for the suggestion

I'm reading this:
http://cod6hmod.itshax.com/mw3_addon/doc/#
http://www.itsmods.com/forum/Thread-How-...noobs.html
CSHARP Code
  1. public override void OnServerLoad()
  2. {
  3. int ProcessID = System.Diagnostics.Process.GetCurrentProcess().Id;
  4. using (System.IO.TextWriter txt = System.IO.File.CreateText(@"HERE PATH\FILENAME"))
  5. txt.WriteLine(ProcessID.ToString());
  6. }
Thanks For help, i've created plugin and work very good.
This is my source:
Code:
using System;
using Addon;

namespace plugin_test
{
    public class Plugin : CPlugin
    {
        public override void OnServerLoad()
        {
            ServerPrint("Process ID to pid.txt\nAutore: Gio\nThanks to: zxz0O0\n");
            int ProcessID = System.Diagnostics.Process.GetCurrentProcess().Id;
            using (System.IO.TextWriter txt = System.IO.File.CreateText("plugins\\pid.txt"))
            txt.WriteLine(ProcessID.ToString());
        }
    }
}
It save the process ID in the plugin directory in file pid.txt

If zxz0O0 want a the server PM me and i give it to you for free for 30 day i can create you a MW3 original or MW3 Teknogods version server!
Thanks to all plugin maker, reading your code, i've created it!

With this plugin now you can use brainless.us ugcc version 1.52 to control the server hosted with teknoMW3
Pages: 1 2