DeityAPI
This plugin is designed to make the tedious tasks such as chat/config/command handling simple and unified. Think of it like the borg for bukkit.
What does this plugin allow me to do?
For Server Admins: This plugin will not do anything for you, unless you are developer and using its API. Otherwise it will sit in the background. For Developers: Plugin contains multiple api functions available to the developer, dealing with MySQL interaction, Player handling, Inventory handling, Chat handling, Econ handling (provided vault is installed), WorldEdit, WorldGuard, Mob handling, File Management, String Management, Time Management, and various others.
Benefits:
- The simplicity. Even if you do not use the Plugin and Command framework we provide, you still have access to a persistant MySQL Connection instantly, without having the Server admin configure the database multiple times.
- Within the Plugin framework, if the admin decides to enable it, it will profile the load times of all the plugins registered.
- Getting sick of building help files/pages, to go along with the plugin? The Command framework will take care of all that including all sub-command handling out of the box.
- Annoying at having to check permissions/check if its a player running the command? The Command framework will also do all of this for you.
Configuration?
deityapi: should_profile: true # Whether or not you would like to see load times on plugins inform_on_plugin_update: true # Whether or not you would like plugins to notify you if they update mysql: server: address: localhost # Change me to the address of your database server port: 3306 # Change me to the port of your database server database: name: kingdoms # Change me to the name of your database username: root # Change me to the username for your database password: root # Change me to the password for your database
Commands?
- /Query [show/hide]: This command will show/hide console logging of all database queries. Can be used by anyone who is Op/players with the permission node "DeityAPI.query" or from console itself
Plugins that use this plugin
If your using the API for a plugin and it wont load or throw a ClassNotFoundException. Please message me with your plugin name and ill add it to the list
I am confused about how to set up the config in terms of the address, port, name, username, and password. Can anyone help me?
@fivedarkops
You should not be running a server. Take a step back and re-evaluate your position.
@fredghostkyle1
that looks like you have no MySQL database information at the config. You must have a working database to use all deityapi-depending plugins!
hey DeityPortl needs this plugin, but when i boot this plugin up i get this: 16:42:53 [INFO] [DeityPortal] Enabling DeityPortal v12.09.01 16:42:53 [INFO] [DeityPortal] Loading Config... 16:42:53 [INFO] [DeityPortal] Saving Config... 16:42:53 [INFO] [DeityPortal] Loading Language... 16:42:53 [INFO] [DeityPortal] Saving Language... 16:42:53 [WARNING] [DeityAPI] com.imdeity.portals.DeityPortalMain attempted to access the data api which is offline (Check startup logs) 16:42:53 [SEVERE] Error occurred while enabling DeityPortal v12.09.01 (Is it up to date?) java.lang.NullPointerException at com.imdeity.portals.DeityPortalMain.initDatabase(DeityPortalMain.java:29) at com.imdeity.deityapi.api.DeityPlugin.onEnable(DeityPlugin.java:50) at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:217) at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:365) at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:381) at org.bukkit.craftbukkit.CraftServer.loadPlugin(CraftServer.java:265) at org.bukkit.craftbukkit.CraftServer.enablePlugins(CraftServer.java:247) at net.minecraft.server.MinecraftServer.i(MinecraftServer.java:296) at net.minecraft.server.MinecraftServer.d(MinecraftServer.java:275) at net.minecraft.server.MinecraftServer.a(MinecraftServer.java:225) at net.minecraft.server.DedicatedServer.init(DedicatedServer.java:140) at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:380) at net.minecraft.server.ThreadServerApplication.run(SourceFile:539)
If you could help me that would be great :D
Can you put some info up on how to use the config API?
@TheSheps03
First off, the formatting on that is horrid. Secondly why is your server output backwards :S never seen that before. As for your issue, when your loading deityapi [DeityAPI] DataAPI Offline: Failed to connect to MySQL. Have you updated the config? shows up. This means that you have incorrectly filled out the information for mysql. You will need to check with your host on the information to your MySQL database. Once you have the information just put what info corresponds to the correct info in the config. I cannot help you with that issue any more then that.
@weja93 I can see the plugin taking load 25 seconds after the modules initially attempt to load, but after that it should be taking little to no time. On the 25 second mark after a plugin using the api attempts to load, it will attempt to contact bukkit dev to see if the plugin has been updated. It does this once, and in an async thread so it shouldn't be of any actual concern. After that one time it caches the data on whether or not it has been updated and will spit that out once an hour. I can see this causing load because each plugin you have using DeityAPI will use this same function 25 seconds after loading however as i said, its all in an asynchronous task, so it should be of no concern
please help me out, I'm certainly not the best with computers but i'd like to think I'm decent and i've been spending hours just to get this game to work. This is the console message every time - (maybe i'm doing the config data wrong, but ive tried putting in MySQL info as well as the actual server info but this just keeps happening) please help!
18.08 16:33:25 [Server] Startup Done (1.498s)! For help, type "help" or "?" 18.08 16:33:25 [Server] SEVERE Error occurred while enabling Kingdoms-2 v12.08.07.04 (Is it up to date?) 18.08 16:33:25 [Server] WARNING [DeityAPI] com.imdeity.kingdoms.main.KingdomsMain attempted to access the data api which is offline (Check startup logs) 18.08 16:33:25 [Server] INFO [Kingdoms-2] Saving Language... 18.08 16:33:25 [Server] INFO [Kingdoms-2] Loading Language... 18.08 16:33:25 [Server] INFO [Kingdoms-2] Saving Config... 18.08 16:33:24 [Server] INFO [Kingdoms-2] Loading Config... 18.08 16:33:24 [Server] INFO [Kingdoms-2] Enabling Kingdoms-2 v12.08.07.04 18.08 16:33:24 [Server] INFO at net.minecraft.server.ThreadServerApplication.run(SourceFile:539) 18.08 16:33:24 [Server] INFO at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:380) 18.08 16:33:24 [Server] INFO at net.minecraft.server.DedicatedServer.init(DedicatedServer.java:140) 18.08 16:33:24 [Server] INFO at net.minecraft.server.MinecraftServer.a(MinecraftServer.java:225) 18.08 16:33:24 [Server] INFO at net.minecraft.server.MinecraftServer.d(MinecraftServer.java:275) 18.08 16:33:24 [Server] INFO at net.minecraft.server.MinecraftServer.i(MinecraftServer.java:296) 18.08 16:33:24 [Server] INFO at org.bukkit.craftbukkit.CraftServer.enablePlugins(CraftServer.java:247) 18.08 16:33:24 [Server] INFO at org.bukkit.craftbukkit.CraftServer.loadPlugin(CraftServer.java:265) 18.08 16:33:24 [Server] INFO at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:381) 18.08 16:33:24 [Server] INFO at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:365) 18.08 16:33:24 [Server] INFO at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:217) 18.08 16:33:24 [Server] INFO at com.imdeity.deityapi.api.DeityPlugin.onEnable(DeityPlugin.java:50) 18.08 16:33:24 [Server] INFO at com.imdeity.protect.DeityProtect.initDatabase(DeityProtect.java:38) 18.08 16:33:24 [Server] INFO java.lang.NullPointerException 18.08 16:33:24 [Server] SEVERE Error occurred while enabling DeityProtect v12.08.07 (Is it up to date?) 18.08 16:33:24 [Server] WARNING [DeityAPI] com.imdeity.protect.DeityProtect attempted to access the data api which is offline (Check startup logs) 18.08 16:33:24 [Server] INFO [DeityProtect] Saving Language... 18.08 16:33:24 [Server] INFO [DeityProtect] Loading Language... 18.08 16:33:24 [Server] INFO [DeityProtect] Saving Config... 18.08 16:33:24 [Server] INFO [DeityProtect] Loading Config... 18.08 16:33:24 [Server] INFO [DeityProtect] Enabling DeityProtect v12.08.07 18.08 16:33:24 [Server] INFO Preparing start region for level 2 (Seed: 830899422291126047) 18.08 16:33:24 [Server] INFO Preparing spawn area: 81% 18.08 16:33:24 [Server] INFO Preparing start region for level 1 (Seed: 830899422291126047) 18.08 16:33:23 [Server] INFO Preparing start region for level 0 (Seed: 830899422291126047) 18.08 16:33:23 [Server] INFO Preparing level "world" 18.08 16:33:23 [Server] INFO [DeityAPI] Enabled - 0.153 seconds 18.08 16:33:23 [Server] INFO [DeityAPI] UtilsAPI hooked and loaded 18.08 16:33:23 [Server] SEVERE [DeityAPI] SecAPI Offline: WorldGuard not found 18.08 16:33:23 [Server] SEVERE [DeityAPI] PermAPI Offline: Vault not found 18.08 16:33:23 [Server] INFO [DeityAPI] PlayerAPI hooked and loaded 18.08 16:33:23 [Server] INFO [DeityAPI] MobAPI hooked and loaded 18.08 16:33:23 [Server] INFO [DeityAPI] EffectAPI hooked and loaded 18.08 16:33:23 [Server] SEVERE [DeityAPI] EditAPI Offline: WorldEdit not found 18.08 16:33:23 [Server] SEVERE [DeityAPI] EconAPI Offline: Vault not found 18.08 16:33:23 [Server] SEVERE [DeityAPI] DataAPI Offline: Failed to connect to MySQL. Have you updated the config? 18.08 16:33:23 [Server] SEVERE [DeityAPI] ChatAPI not hooked into vault 18.08 16:33:23 [Server] INFO [DeityAPI] Saving Language... 18.08 16:33:23 [Server] INFO [DeityAPI] Loading Language... 18.08 16:33:23 [Server] INFO [DeityAPI] Saving Config... 18.08 16:33:23 [Server] INFO [DeityAPI] Loading Config... 18.08 16:33:23 [Server] INFO [DeityAPI] Enabling DeityAPI v12.08.07 18.08 16:33:23 [Server] INFO [Kingdoms-2] Loading Kingdoms-2 v12.08.07.04 18.08 16:33:23 [Server] INFO [DeityProtect] Loading DeityProtect v12.08.07 18.08 16:33:23 [Server] INFO [DeityAPI] Loading DeityAPI v12.08.07 18.08 16:33:23 [Server] INFO This server is running CraftBukkit version git-Bukkit-1.3.1-R1.0-b2320jnks (MC: 1.3.1) (Implementing API version 1.3.1-R1.0) 18.08 16:33:23 [Server] INFO Starting Minecraft server on 108.170.10.162:25627 18.08 16:33:22 [Server] INFO Generating keypair 18.08 16:33:22 [Server] INFO Default game type: SURVIVAL 18.08 16:33:22 [Server] INFO Loading properties 18.08 16:33:22 [Server] WARNING To start the server with more ram, launch it as "java -Xmx1024M -Xms1024M -jar minecraft_server.jar" 18.08 16:33:22 [Server] INFO Starting minecraft server version 1.3.1 18.08 16:33:22 [Server] INFO 27 achievements 18.08 16:33:22 [Server] INFO 195 recipes 18.08 16:33:22 [Multicraft] Loaded config for "Craftbukit 1.3.1-R1.0 (Build #02317) Recommended Build" 18.08 16:33:22 [Multicraft] Starting Minecraft! 18.08 16:33:22 [Multicraft] Loading Minecraft instance properties 18.08 16:33:22 [Multicraft] Received start command
This plugin is currently taking the most load.
This is causing it (98.737 ms / 500 ticks)
com.imdeity.deityapi.api.DeityPlugin$AutoUpdater
It does it for a while after start, when other plugins already have settled down :o
@willkiller1234
Refer to this: "[DeityAPI] com.imdeity.protect.DeityProtect attempted to access the data api which is offline (Check startup logs)"
How do i fix this error? 15.08 23:28:31 [Server] INFO at net.minecraft.server.ThreadServerApplication.run(SourceFile:539) 15.08 23:28:31 [Server] INFO at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:380) 15.08 23:28:31 [Server] INFO at net.minecraft.server.DedicatedServer.init(DedicatedServer.java:140) 15.08 23:28:31 [Server] INFO at net.minecraft.server.MinecraftServer.a(MinecraftServer.java:225) 15.08 23:28:31 [Server] INFO at net.minecraft.server.MinecraftServer.d(MinecraftServer.java:275) 15.08 23:28:31 [Server] INFO at net.minecraft.server.MinecraftServer.i(MinecraftServer.java:296) 15.08 23:28:31 [Server] INFO at org.bukkit.craftbukkit.CraftServer.enablePlugins(CraftServer.java:247) 15.08 23:28:31 [Server] INFO at org.bukkit.craftbukkit.CraftServer.loadPlugin(CraftServer.java:265) 15.08 23:28:31 [Server] INFO at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:381) 15.08 23:28:31 [Server] INFO at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:365) 15.08 23:28:31 [Server] INFO at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:217) 15.08 23:28:31 [Server] INFO at com.imdeity.deityapi.api.DeityPlugin.onEnable(DeityPlugin.java:50) 15.08 23:28:31 [Server] INFO at com.imdeity.protect.DeityProtect.initDatabase(DeityProtect.java:38) 15.08 23:28:31 [Server] INFO java.lang.NullPointerException 15.08 23:28:31 [Server] SEVERE Error occurred while enabling DeityProtect v12.08.07 (Is it up to date?) 15.08 23:28:31 [Server] WARNING [DeityAPI] com.imdeity.protect.DeityProtect attempted to access the data api which is offline (Check startup logs) 15.08 23:28:31 [Server] INFO [DeityProtect] Saving Language... 15.08 23:28:31 [Server] INFO [DeityProtect] Loading Language... 15.08 23:28:31 [Server] INFO [DeityProtect] Saving Config... 15.08 23:28:31 [Server] INFO [DeityProtect] Loading Config... 15.08 23:28:31 [Server] INFO [DeityProtect] Enabling DeityProtect v12.08.07
@louiskw
Sweet :D The whole point of this was to make the tedious plugin tasks simpler. At least the ones that I had been using regularly.
Ok, I managed to get up simple SQL stuff. I REALLY love this and it is easier to use than I first thought.
Because of this I made an automated supporter system and am getting loads of donations. I smell your coffee fund when ive broken even :P
@louiskw
Sure. Ill get something simple up later on.
jah, I find javadocs immensely hard to use :P
Could you do a simple example, maybe a 'load content from a MYSQL database' tutorial?
@louiskw http://deitykingdomsdev.github.com/DeityAPI-Public
@MaxxeRoy You have configured the database incorrectly. Check the DeityAPI config file and verify the information
I'm getting this error...
2012-08-07 18:53:02 [WARNING] [DeityAPI] com.imdeity.protect.DeityProtect attempted to access the data api which is offline (Check startup logs) 2012-08-07 18:53:02 [SEVERE] Error occurred while enabling DeityProtect v12.08.07 (Is it up to date?) java.lang.NullPointerException at com.imdeity.protect.DeityProtect.initDatabase(DeityProtect.java:38) at com.imdeity.deityapi.api.DeityPlugin.onEnable(DeityPlugin.java:50) at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:217) at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:365) at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:381) at org.bukkit.craftbukkit.CraftServer.loadPlugin(CraftServer.java:265) at org.bukkit.craftbukkit.CraftServer.enablePlugins(CraftServer.java:247) at net.minecraft.server.MinecraftServer.i(MinecraftServer.java:296) at net.minecraft.server.MinecraftServer.d(MinecraftServer.java:275) at net.minecraft.server.MinecraftServer.a(MinecraftServer.java:225) at net.minecraft.server.DedicatedServer.init(DedicatedServer.java:140) at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:380) at net.minecraft.server.ThreadServerApplication.run(SourceFile:539)
This is really great, I have kinda got somewhere.... I need some docs
@thernztrom
That was a bug with an old version, you can remove that node. Its not needed
@vanZeben
What is the mcbans api token for? I use mcbans already, but why is it listed in the config?
@selfservice0
Ahh that explains it then :P