Thread: Plugins
View Single Post
Old 06-28-2004, 07:09 AM   #1 (permalink)
supster
 
Join Date: Oct 2003
Posts: 11
Default Plugins

I tried PMing this to Krrios but I'm sure hes pretty busy so I thought I might be able to get an answer here.


Hey, I was trying to write a plugin for Krrios' client and it isn't working. Wanted to see if anyone could help.

I'm using VS.NET as an IDE. I created a new C# Class Library project. I reference only Exposer.dll, System.Drawing, and System.Windows.Forms.

Heres my code:

Code:
using System;
using Client;
using System.Windows.Forms;

namespace KUOCPlugin
{
	public class Plugin1:Plugin
	{
		IExposed m_Exposed;

		public Plugin1()
		{
		}
		public override void Run(IExposed e)
		{
			MessageBox.Show("TEST");
			this.m_Exposed = e;
		}
		public override bool OnKeyDown(KeyEventArgs e)
		{
			if (e.KeyCode == Keys.F10)
				m_Exposed.Say("Hello World!");
			return true;
		}

	}
}
I built the project without any errors and moved the DLL file to the /Plugins folder and also added #Test.dll to the Plugins.def.

I load the client and login and nothing happens (I expected a message box saying "TEST"), when I hit F10 also nothing happens.

It seems like the library is never getting called. So for fun I changed the line from #Test.dll to #Test.test (there is no file Test.test), and next time I loaded the client I recieved a FileNotFound exception.

I'm stumped, do you have any clue what I'm doing wrong?
supster is offline   Reply With Quote