MyBB Community Forums

Full Version: Minecraft Connect [1.8]
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
=======================================================================

RELEASE THREAD: http://community.mybb.com/thread-193428.html

=======================================================================
Hey guys, had a request from someone to make a bridge for MyBB and Minecraft so I did! This is still a WIP obviously, but this will be my first public release. Login with Minecraft is fully functional! Still planning on adding a register with Minecraft feature but I don't have an estimate of when that will be done. Some of the error messages the plugin gives have more technical information that you would probably want/need to give your users, but I'll clean those up in the near future.

I'm looking for both feature suggestions/changes as well as people to bug test for me!

Requirements:
  • MyBB 1.8.* (tested on vanilla 1.8.6)
  • PHP >= 5.3
  • cURL enabled with SSL
  • Valid CA root certificate bundle on your server. This is to secure our connection to Mojang and block Man-in-the-Middle attacks. View installation section below if you need to install one.
Installation:
Unzip the file into your MyBB root directory. Install from ACP as you would any other plugin.
** If the plugin installs correctly you have cURL set up properly!!! This means you don't have to wory about the next installation step!! **
Installation (add new CA cert bundle):
Most servers should come with one pre-installed but if yours doesn't all you need to do is go to this link and copy everything in that file, save it on your server as cacert.pem somewhere that php can access. Then open your php.ini file and add
curl.cainfo=PATH/TO/cacert.pem
, (change PATH/TO to your actual absolute path to the file) save and restart your server and you should be good to go. If you can't figure it out post in here or a support thread, or honestly just do a simple Google search and it should be pretty straightforward.

Usage:
  1. Login with your MyBB info like normal.
  2. Go to UserCP and click the Minecraft Connect link (try clearing your cache, it make take a minute or two to show up)
  3. Link your Minecraft account
  4. Once your MC account is successfully linked you can log out and log in freely with your MC info
  5. Revisit the UserCP tab if you wish to unlink your account at any time
Screenshots in attachments below!

Download: http://community.mybb.com/mods.php?action=view&pid=741

View Source: https://github.com/squez/Minecraft-Connect

Credit to [email protected] for making the initial MCAuth wrapper.

Licensed under GNU GPL 3

Donate so I can keep making plugins!
Let me know what you guys think! Looking forward to the feedback.

-fizz
Updated to Release 0.5.2. Accidentally forgot to delete my MCAuthBACKUP.class.php file, so it is causing a lot of "Fatal error: cannot re-declare class ..." errors. Delete "inc/plugins/MinecraftConnect/MCAuthBACKUP.class.php" or just download the new release on Github and reinstall and it should fix the problem!

EDIT: Updated to 0.5.2 to fix missing where clause in a $db->update_query call. This update will fix every user getting the new MC login data added to their db info...
Anyone have any feature requests or anything? Trying to think what else to add besides registration with your Minecraft account.
(2016-04-18, 08:31 PM)fizz Wrote: [ -> ]Anyone have any feature requests or anything? Trying to think what else to add besides registration with your Minecraft account.

You could automatically pull the player's skin via the Minecraft API, crop the face and set it as the user's avatar if they don't already have one/are using the default avatar.
(2016-04-18, 08:40 PM)Marisa Wrote: [ -> ]
(2016-04-18, 08:31 PM)fizz Wrote: [ -> ]Anyone have any feature requests or anything? Trying to think what else to add besides registration with your Minecraft account.

You could automatically pull the player's skin via the Minecraft API, crop the face and set it as the user's avatar if they don't already have one/are using the default avatar.
Interesting idea, thanks for the suggestion I'll look into it!

Updated to version 0.6. Original post edited with link to new release.