I have a kind of complicated question. I wrote a couple of plugins which are stored in a single C# DLL. I access these two plugins through an interface (another C# DLL) The two plugins are two seperate classes inside the same DLL. The second plugin inherits from the first one, so all of the first plugin's functions are automatically inherited by the second. What I am trying to do now, is override some of the first plugin's functions in the second. However, I get a compile errors. I've never had to deal with plugins or interfaces before, so maybe it's just not bossible to override a function of an inherited base class in this case. Here's a little bit of the code I am trying to use:
// First plugin class
class PluginOne : IPluginOne
virtual double IPluginOne.Add(double x, double y)
//Add two doubles together
// Second plugin class
class PluginTwo : PluginOne, IPluginTwo
double IPluginTwo.Subtract(intx, int y)
override int IPluginOne.Add(int x, int y)
//Add two integers together
I get the following two errors:
"The modifier 'virtual' is not valid for this item"
"The modifier 'override' is not valid for this item"
What am I doing wrong? Any help would be great...