Fork me on GitHub
  February 25, 2018, 05:57:05 am
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
   Home   Help Search Login Register  
Pages: [1]
  Print  
Author Topic: A few questions about plugins  (Read 3896 times)
pazzesco
Newbie
*
Posts: 1


View Profile
« on: December 21, 2010, 05:38:37 pm »

Hey everybody,
   First off, I love the idea of this project. Coming from developing plugins for hey0's mod, this is going to be a breath of fresh air. Not that hey0's mod isn't anything but awesome, but waiting for poor hey0 to wrestle with a pile of obfuscated Java classes can be tedious with a bunch of programmers/players wanting instant, working results. Hats off to him and the others over at that community.
  That being said, I've looked around a little for plugin development resources and haven't turned up any. This is still very much in the works I take it? I'm definitely anticipating developing for this.
Logged

Ships are safe in harbor, but they were never meant to stay there.
deoxxa
Administrator
Newbie
*****
Posts: 28


View Profile
« Reply #1 on: December 21, 2010, 05:56:18 pm »

Yep it's still very early days for plugins. Over the last 48 hours or so I got plugins technically working, but I'm not a fan of some of the implementation specifics right now. Check out `src/plugins/banlist/banlist.{cpp,h}` for how a plugin currently looks (note: that plugin doesn't currently do much aside from loading itself).

The implementation problems that we're currently met with are familiar to anyone who's worked with dynamically linked C++ code before: name mangling. Right now plugins need to be compiled with the same compiler and preferably toolchain as the main Mineserver executable. The only way to get around this will be to completely re-engineer the way functionality from the core of Mineserver is exposed to plugins by using a far more C-ish interface, passing a struct of function pointers and maybe some kind of context cookie into the init/shutdown functions instead of a Mineserver (the class, not the application) instance.

If you're interested in keeping up with development and such, especially with the volatility of the plugin interface, joining IRC wouldn't be a horrible idea. We're situated on irc.esper.net in #mineserver if you want to drop in for a chat.
Logged
Fador
Administrator
Full Member
*****
Posts: 126


View Profile
« Reply #2 on: December 29, 2010, 10:20:22 pm »

I was able to put together a nice Plugin API (http://mineserver.be/wiki/Plugin_API) last night. A lot of functions and hooks missing but I'm going to add them! Wink
Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.21 | SMF © 2015, Simple Machines Valid XHTML 1.0! Valid CSS!