For$
<!-- begin site header -->
<div id=

Author Topic: Events based .NET API  (Read 6854 times)

Delirium

  • Newbie
  • *
  • Posts: 27
    • View Profile
Events based .NET API
« on: April 03, 2011, 01:09:53 pm »
So, as I'm a quite expirienced .NET Programmer, I thought of a API Plugin so that you can use CLR (.NET)-DLL-Assemblies as Plugins in Mineserver. I know this requires at least mono or .NET installed, but most of the people have these now, and as a matter of fact, the mono project is far enough implemented to get this working. I'll spend some time trying to make some PInvoke going.

What are your thoughts on this?

Many people know VisualBasic and many People know C#. If this would be implemented, it would be farily easy to write many Plugins.
Make it idiot proof and someone will make a better idiot.

Ligustah

  • Newbie
  • *
  • Posts: 42
    • View Profile
Re: Events based .NET API
« Reply #1 on: April 03, 2011, 01:23:46 pm »
If people are against bringing in Java, why would they link to .NET ?
I mean after all, they both run in a VM.

I just recently used a program that could convert Java bytecode to CLR bytecode.
I had it run the original minecraft server just to see that it was using slightly more
resources than the Java version.

This might not even apply in any other cases, but i think the differences in performance
between Java and .NET are neglectable.

Delirium

  • Newbie
  • *
  • Posts: 27
    • View Profile
Re: Events based .NET API
« Reply #2 on: April 03, 2011, 02:48:00 pm »
Well, this is totally against my expiriences. If you write a clean program in C#, its farily faster than Java. Those converters are often total crap, I used recently one which converts Java Bytecode to Native code. Resources usage was nearly the same. Those automatic converters aren't optimized for speed, they are optimized for accuracy of conversion. I get eye cancer if I see such converted source :/ That applies btw even for the VisualBasic to C# and reverse converters.

As I (hopefully) ported the plugin API to work with C# (found a tool which generates reasonable code, desipte from way too long variable names), I can run some speed tests with a sample plugin.

Edit: Oh, and by the way: if this works, it would be a optional plugin, so you can use it, if you want. You don't have to.
« Last Edit: April 03, 2011, 03:03:42 pm by Delirium »
Make it idiot proof and someone will make a better idiot.

Ligustah

  • Newbie
  • *
  • Posts: 42
    • View Profile
Re: Events based .NET API
« Reply #3 on: April 03, 2011, 07:31:00 pm »
I'd be certainly interested in seeing benchmarks. Especially since i'm looking for a new language to use (hrhr @ oracle), and i would really hate having to go with C++ in the end.

As for performance, i think Java and C# are actually pretty close. I just can't imagine that two bytecode-driven platforms that both do JIT compiling are too far off each other.

Anyways, looking forward to seeing your benchmarks.