Loot tables to SQL DB
(#183)
* Loot tables to SQL DB
Migrated the loot tables to an SQL DB with tables for (Global_Items, Normal_Items)
This allows the data to be shared by all of the characters without to many conflicts.
If you edit or add anything on the driver and save the settings you can issue /rgl lootreload on all characters to reload from the DB.
## IMPORTANT !!
The **FIRST TIME** you run this after this update,
**ONLY** Load RGMercs Lua On **ONE Character** to build the DB.
This Could take a couple seconds to create and populate the database. (_especially if your loot.ini is large_)
After you have the database created you can load as many toons as you would like.
## Loading Order of Operation.
* Check for loot DB (saved by server name cause emu servers can have different loot)
* If the DB is missing we create it and the 2 tables.
* If we created a new Database
* then load working tables from loot.ini file and write their contents to the database tables.
* If we already have the DB then load our working tables from that.
* Pass the Working tables back to the Loot Module
## Notes:
Any item changes and new additions are written to the ini file for non mercs users, and to the Database. Buy items are per character so we will keep those in our own tables since we do not need to share them.
* forgot a couple debug prints
* lookup items checks the db so we have less need to reload
* fix: for missing config ini file
* /rgl lootupdate will import the ini into the db
this way if you ran lootnscoot in standalone mode and then came back to rgmercs you can get the new items.
* addresses comments
also moved my printf statements from testing to rgmercslogger.
* silly me missed an actors call. replaced with RGMercUtils.Actors
* applied the same to loot_hist
* typo
* missed a setting conversion
* Some Cosmetics
* Added Button to Reload working table from Database
* Added Button to Update the Database from the loot.ini file.
* both buttons have tooltips the Update warns that you should only run on one character and use reload on the others.
* added classes column to tables for future additions
* Updating DB only pulls in new items instead of updating old ones
* removed some debug spam
* fix buy items table clearing on reload