• Salut Visiteur ! ✌
    Découvre nos partenaires officiels avec VeryLeak's. Des choix réfléchis, dignes de confiance pour tes avantages.

    StoryFound | REFUNDER TEAM

    StoryFound

    Rejoindre le Canal ✨ ou Plus d'information 📃

    Une question ? Rejoingnez nos différents canaux (Discord, Telegram, Revolt)

    Nos Canaux Communautaires

    Cet affichage peut se clôturer définitivement via la croix en haut à droite.

Essentials MySQL Storage Extension 1.19.1

H4X0RR

VeryLeak's Unique Member 👑
Level 5

Torrents Stats

Messages
1 513
J'aime
1 234
Trophées
830
Inscrit
26 Novembre 2015
MPDB-small.png
MySQL Player Data Bridge

Features
  • Online and Offline UUID support! Does no work on non UUID servers, so will will work on 1.7.10 and up.
  • Add MySQL storage for Essentials userdata files.
  • Option to remove inactive users from the database.
  • Saves all data that is stored in the user data files. (Ex. homes, money, mails... everything)
  • Allows you to sync essentials data across servers.
  • Support for QuickShop plugin for offline sales.
  • Support for ChestShop plugin for offline sales and buy orders.
  • Support for AuctionHouse plugin for offline auctions.
  • Support for PlayerShopGUI+ plugin for offline sales.
  • Support for ShopChest plugin for offline sales and buy orders.
  • Option to delete the entire Essentials/userdata folder on server shutdown or restart.
  • Option to delete user data files when players leave the server and data is saved on database.
  • Command to import all users data files to the database.
  • Command to export all users from the database back into essentials userdata files. So you can remove the plugin anytime without data loss.
  • Command to get Balance Top from the database data.
  • Ability to filter the players data file and remove data that you don't what to save.
  • Very configurable, check the config sample below.
  • Light, will use little resources and tasks run async to not impact the server performance or TPS.

How does it work?
When the player leaves the server his essentials data file is saved on the database. Then when he joins the server his essentials data file is deployed from the database to the Essentials/userdata folder and hook into Essentials to load it. This plugin does not change the way Essentials work, but manipulates the user data files to save them on the database.


Dependencies
  • MySQL Database
  • Essentials , EssentialsX or Spigot-Essentials
*These are all required dependency's.
*Only 1 of the 3 Essentials plugins listed above you must have installed. DO NOT INSTALL all of them.


Install instructions
  1. Place the plugin in the server plugins folder, and make sure you have Essentials installed.
  2. Start the server to generate the config, then stop the server.
  3. Open the config and set up the database connection details and configure the plugin. You need to create the database, then the plugin will create the tables on it's own.
  4. Start the Server. Check the server log and make sure everything is ok. Done, enjoy.


Permissions
EMS.admin - Unlock access to the import/export data command. Default to op.
EMS.baltop - Unlock access to the /ems baltop command. Default to op.


Commands
/ems and /ems help - Display the help menu.
/ems baltop - EMS.baltop - Get Money Top 10 from the database.
/ems reload - EMS.admin - Reload plugin config.
/ems import - EMS.admin - Import all users files from the Essentials/userdata folder to the database. Will skip users already in the database or broken data files.
/ems export - EMS.admin - Export all users from the database back into essentials userdata files. Will not remove the users from the database. Make sure you disable removal of essentials userdata folder or files before export.
/ems saveAndKick - EMS.admin - Kick all players and save their data.
/ems remove <name> - EMS.admin - Delete a specific user from the database.


Config sample
Spoiler: config.yml
#MySQL Database details
Database:
Mysql:
#MySQL server address
Host: 127.0.0.1
#MySQL server port (default 3306)
Port: 3306
#Database name (NOTE! You need to create the database, then the plugin will create the tables.)
DatabaseName: 'mydatabase'
#Table name (the plugin will auto create them)
TableName: 'Essentials_userdata'
#User name
User: 'admin'
#User password
Password: 'cheesecake'
#SSL connection
SslEnabled: false
#This maintenance task runs async with a 2 min delay after the server starts.
RemoveInactiveUsers:
#Enable or disable database clean up of old accounts. | (true or false)
enabled: false
#Inactivity in days. Default 60 days.
inactivity: 60


#Plugin settings
Settings:
#Built in support for other plugins.
# NOTE! A server restart is needed for changes here to take effect!
SupportFor:
#Support for QuickShop plugin: Link Removed
#If you use Essentials Economy and QuickShop plugin enable this option. If you use other economy plugin keep it disabled.
#Set the tax value same as in QuickShop config. To disable set: QuickShopTax: 0.00
QuickShop: false
QuickShopTax: 0.05
#Support for ChestShop plugin: https://dev.bukkit.org/projects/chestshop
##If you use Essentials Economy and ChestShop plugin enable this option. If you use other economy plugin keep it disabled.
ChestShop: false
#Enable support for plugin ShopChestPlayerShopGUI+: Link Removed
PlayerShopGUI-Support: false
#Enable support for plugin AuctionHouse: Link Removed
AuctionHouse-Support: false
#Enable support for plugin ShopChest: Link Removed
ShopChest-Support: false
#Delete the entire Essentials/userdata folder on server shutdown or restart.
#NOTE! Will delete all users files. Make sure you import them first.
RemoveUserDataFolder: false
#Delete the data file for players that leave the server after his data is saved on database.
RemoveUserFile: false
#Save online players data files to database. If this is disabled the data will be saves only when the player leaves the server.
SaveDataTask:
#Enable or disable the data save task. | (true or false)
enabled: true
#Time between data saves in minutes. | Default 3 min.
interval: 3
#Hide the data save task log messages.
hideLogMessages: false
#Prevent saving of some Essentials users data.
SaveFilter:
#Enable or disable the filter.
enabled: false
#The following data will be removed from essentials users data file when saving.
preventSaveOf:
- 'logoutlocation'
- 'lastlocation'
#Add support for essentials commands when players are offline.
EssentialsCmdIntegration:
#Support for essentials /pay command for offline players.
PayCmd: true
#Support for essentials /balance command for offline players.
BalanceCmd: true
#Support for essentials /seen command for offline players.
SeenCmd: true
#Support for essentials /eco commands for offline players.
EcoCmd: true

#Chat messages with color and format codes support.
#Minecraft Color and Format Codes: http://minecraft.gamepedia.com/Formatting_codes
ChatMessages:
NoPermission: '&4[EMS] &cYou don''t have permission!'
ImportCmd: '&2[EMS] &aImport essentials data started! Check server console for progress.'
ExportCmd: '&2[EMS] &aExport essentials data started! Check server console for progress.'
CmdNotFound: '&4[EMS] &cCommand not found! For help do /ems'
MoneySymbol: '$'
MoneySyncDisabled: '&4[EMS] &cMoney sync is disabled.'
BalTopTitle: '&6&l Money Top 10'
BalTopUpdate: '&2[EMS] &aUpdating Money Top 10 list...'
BalTopEmptyDB: '&4[EMS] &cDatabase is empty!'
BalTopUsage: '&4[EMS] &cUsage: &6/baltop'
RemoveCmdUsage: '&6[EMS] &eUsage: &6/ems delete <name>'
RemoveCmdComplete: '&2[EMS] &aUser removed from database!'
RemoveCmdNotFound: '&4[EMS] &cUser not found in the database!'
ReloadCmdWarning: '&cThis plugin does not recommend server reloads. If you have issues after running this command stop using it.'
PlayerNotFound: '&4[System] &cPlayer not found!'
PayAmountPositive: '&4[System] &cAmount must be positive!'
PayFormatError: '&4[System] &cAmount must be a number!'
PayNoMoney: '&4[System] &cYou do not have sufficient funds!'
PayComplete: '&2[System]&a $<amount> has been sent to&e <name>'
TakeComplete: '&2[System]&a $<amount> has been taken from&e <name>'
ResetComplete: '&2[System]&a Money reset complete for&e <name>'
BalanceCmd: '&2[System]&a Balance of&e <name>&a:&c $<amount>'
ReloadCmd: '&2[System]&a Config reload complete'
DatabaseTaskStart: '&6[System]&e Command will run in background for all players in database! Check console for progress...'
DatabaseTaskRunning: '&4[System]&c A database task is already running! Please wait until it''s done, check console for progress.'
HelpScreen:
- ' '
- ' &6&lEssentialsMysqlStorage Help'
- ' &7Get Money Top 10: '
- ' &e/ems baltop'
- ' &7Import Essentials data to database: '
- ' &e/ems import'
- ' &7Export Essentials data back to files: '
- ' &e/ems export'
- ' &7Kick all players and save their data: '
- ' &e/ems saveAndKick'
- ' &7Remove a user from the database '
- ' &e/ems remove <name>'
- ' &7Reload plugin config.'
- ' &e/ems reload'
- ' '

#Minecraft Color and Format Codes: http://minecraft.gamepedia.com/Formatting_codes
KickMessages:
saveAndKickCommand: '&cServer is restarting please come back in 20 seconds.'



Useful Info

[Essentials] Version mismatch! Please update EssentialsMysqlStorage to the same version.
Please ignore this log warning message. The reason Essentials posts this message is because this plugin hooks into essentials to sync data. Essentials thinks this is a module like EssentialsChat and posts that warning message to let you know it does not match the Essentials core version. This does nothing else.

Replace essentials /baltop with /ems baltop
You first need to disable essentials /baltop command, go to essentials config file and add the baltop command to the disabled commands like this:
disabled-commands:
- baltop
Then make a command alias for /ems baltop to /baltop , to do so go to the main server folder and add this to the commands.yml config file:
aliases:
baltop:
- ems baltop

Kit cooldown lost issues?
If you are still using old Essentials or Spigot-Essentials I recommend that you will update to EssentialsX as this is the updated and future of Essentials, it has fixes and is updated to work with latest spigot versions. If your kit cooldowns are not working after server restart update to EssentialsX but make sure it's the right version for your minecraft server version.

Issues with players not having the same UUID's when changing servers?
You need to make sure that all players have the same UUID's on all servers, this is important as player's data is stored based on their UUID and not their name. To have the same UUID's on all servers make sure that in the server config file spigot.yml on: settings > bungeecord: true , this will allow the server to get the player UUID from bungeecord and all servers will get the same UUID's. Make sure you have bungeecord: true on all spigot servers.

Issues with data save when you kick all players before server restart/shutdown?
Kicking all players before a server shutdown/restart can cause issues because when the plugin is disabling the server cancels all async tasks it is running. Normally when a player disconnects or is kicked his data is saved async to not lag the server, but when you kick all players right before stopping the server this becomes a problem as if data save is not complete for all players when you do /stop the server will cancel them! If you don't kick players before the shutdown the plugin will save their data on the main thread so the server will wait for all data to be saved before shutdown. If you still need to kick all players before shutdown then use the command /ems saveAndKick it will save all data and kick all players for you in a safe way.

Found a problem or got a suggestion?
I'm happy to add new features and fix any issue you may find, just post it in plugins forum, the button Discussion.

Future updates.
In case the plugin will need to be updated I will do it as fast as we get the new Minecraft version to keep the plugin running on all new versions.


Agreement
This plugin works as it is stated in the description.
If you are unsure if this plugin is for you, don't make a blind purchase!
Leave a comment or send me a pm to state your questions/concerns before buying!
By purchasing this plugin, you agree to the following terms:
  • All purchases are final.
  • You will not redistribute this plugin or any of its source code to anyone publicly or privately.
  • Absolutely no refunds.
  • You will not attempt to modify the this plugin source code without direct permission from me.

Source: Link Removed
Download: https://veryleaks.to/index.php?resources/essentials-mysql-storage-extension-1-19-1.2607/download


Cdt, .
 
Haut Bas