Commit Graph

307 Commits

Author SHA1 Message Date
Akkadius 3c2b8d13b9 Restructure and refactoring of database convert/upgrade check routine, breaking out to individual functions 2014-11-23 23:46:06 -06:00
Akkadius ce248d83d6 Corpse Class Private scope variables renamed for understandability across the source
Removed ThrowDBError from the source
Implemented MySQL query error log at the root of the MySQL API
Readability changes
2014-11-23 21:37:42 -06:00
Akkadius 111fb84041 Moved zonedatabase functions out of corpse.cpp
Conversion portion mostly complete
Some header readability cleanup
Some function renaming
Struct renaming
Many variable renaming
MySQL error log for all of QueryDatabase
Corpse table renaming
Corpse table field renaming
Most corpse database functions redone
2014-11-22 17:55:48 -06:00
KayenEQ 6c7a4edae3 Support for spell field to determine if a spell can be blocked or not.
Numerous other spell fields defined.

Required sql added for updating spells_new field definations.
2014-11-14 00:23:26 -05:00
KayenEQ 563a39c2d9 Spell field defined that determines if must be sneaking to use this ability.
This is handled by client under normal conditions, however if you
force cast this effect in situations like 'procs' you can cause
zone crashes, therefore a failsafe check is added in 'SpellOnTarget'
2014-11-13 21:45:19 -05:00
SecretsOTheP 77f0e7919e Indentation fix. Ornamentation Augments are integrated now. 2014-11-09 03:40:33 -05:00
Natedog2012 efdc177b78 Implement RoF + UF ornament augmentation.. thanks for the help Drajor! 2014-11-09 03:33:58 -05:00
JJ 09e1155a26 Merge pull request #261 from addtheice/RunQueryToDatabaseQuery_common_shareddb
Run query to database query common shareddb
2014-10-15 21:37:33 -04:00
Uleat fa1fe55e01 Added corpse encode and decode translators 2014-10-05 06:12:33 -04:00
Arthur Ice 528f16bdaf SetBotInspectMessage converted to QueryDatabase 2014-10-04 14:24:29 -07:00
Arthur Ice 64641a3390 GetBotInspectMessage converted to QueryDatabase 2014-10-04 14:23:53 -07:00
Arthur Ice 74b8f38030 LoadLootDrops converted to QueryDatabase 2014-10-04 14:22:27 -07:00
Arthur Ice c7faf8a03c LoadLootTables converted to QueryDatabase 2014-10-04 14:21:25 -07:00
Arthur Ice aa9601352d GetLootDropInfo converted to QueryDatabase 2014-10-04 14:20:46 -07:00
Arthur Ice 81b9d9a57e LoadBaseData converted to QueryDatabase 2014-10-04 14:19:04 -07:00
Arthur Ice cecd9b89ba GetMaxBaseDataLevel converted to QueryDatabase 2014-10-04 14:18:11 -07:00
Arthur Ice 938322a3d1 LoadSpells converted to QueryDatabase 2014-10-04 14:16:54 -07:00
Arthur Ice 1c04dccf53 GetMaxSpellID converted to QueryDatabase 2014-10-04 14:16:00 -07:00
Arthur Ice 0622f02470 LoadDamageShieldTypes converted to queryDatabase 2014-10-04 14:14:27 -07:00
Arthur Ice 1366774931 LoadSkillCaps converted to QueryDatabase 2014-10-04 14:13:05 -07:00
Arthur Ice 5cbae2b833 GetcommandSettings converted to QueryDatabase 2014-10-04 14:12:16 -07:00
Arthur Ice c12805acce DeleteStalePlayerBackups converted to QueryDatabase 2014-10-04 14:11:40 -07:00
Arthur Ice e2c84c5f39 DeleteStalePlayerCorpses converted to QueryDatabase 2014-10-04 14:10:57 -07:00
Arthur Ice e19db3f447 LoadNPCFactionLists converted to QueryDatabase 2014-10-04 14:10:00 -07:00
Arthur Ice 7d0b316e74 GetFactionListInfo converted to QueryDatabase 2014-10-04 14:08:53 -07:00
Arthur Ice 0ef428d286 GetBook converted to QueryDatabase 2014-10-04 14:07:55 -07:00
Arthur Ice 2a73a572d3 LoadItems converted to QueryDatabase 2014-10-04 14:06:37 -07:00
Arthur Ice 638d121b75 GetItemsCount converted to QueryDatabase 2014-10-04 14:05:07 -07:00
Arthur Ice 3b75d4fa8f GetInventory char_id, inv) converted to QueryDatabase 2014-10-04 14:04:19 -07:00
Arthur Ice cb897786bc GetInventory(account_id, name, inv) converted to QueryDatabase 2014-10-04 14:02:43 -07:00
Arthur Ice aa780ceb8c GetSharedBank converted to QueryDatabase 2014-10-04 13:55:43 -07:00
Arthur Ice 4a3f94e688 SetStartingItems converted to QueryDatabase 2014-10-04 13:54:33 -07:00
Arthur Ice 211b3a135e SetSharedPlatinum converted to QueryDatabase 2014-10-04 13:53:28 -07:00
Arthur Ice cbce5e5eb6 GetSharedPlatinum converted to QueryDatabase 2014-10-04 13:50:01 -07:00
Arthur Ice a3347579e6 SaveInventory converted into 4 methods, converted to QueryDatabase 2014-10-04 13:45:50 -07:00
Arthur Ice 2fbd170188 VerifyInventory converted to QueryDatabase 2014-10-04 13:32:01 -07:00
Arthur Ice 95208eb24e SaveCursor 2014-10-04 13:31:06 -07:00
Arthur Ice bcf282da91 SetGMSpeed converted to QueryDatabase 2014-10-04 13:27:26 -07:00
Arthur Ice edc2567b10 GetGMSpeed converted to QueryDatabase 2014-10-04 13:26:45 -07:00
Arthur Ice b379bdd36e SetHideMe converted to QueryDatabase 2014-10-04 13:23:52 -07:00
akkadius 1170b57fd5 Fix starting items for starting_item entries that use slot -1 to find a free slot 2014-09-22 16:23:43 -05:00
akkadius 54c89d69f6 Merge remote-tracking branch 'remotes/origin/master' into blob_conversion
Conflicts:
	common/database.cpp
	common/mysql_request_result.h
	common/shareddb.cpp
2014-09-07 04:11:09 -05:00
Akkadius 4c12d31e4a Removed command character backup
Changed all remaining references from the character_ table to the character_data
2014-09-06 22:35:19 -05:00
Akkadius e50cf5c4be - Ported inspect_messages to character_inspect_messages
- Ported character leadership abilities to character_leadership_abilities
- Removed player profile debug printing
- Refactored total time entitled on account to load from the sum of time_played from all characters in character_data
2014-09-06 21:50:29 -05:00
KimLS ffed5a9e22 SQL Injection fix on inspect message setting 2014-09-06 16:43:36 -07:00
Uleat 1d0a6bdc71 Fix for losing 2nd and 3rd cursor items after zoning 2014-09-05 16:16:56 -04:00
Akkadius 4432c07081 State of Commit: Testable if you ask me (Akkadius) what you need to do
- Need to convert a list of functions and columns and should be ready to start intensive testing phase
 - All preliminary tests show things working great

- All of player profile is saved and loaded from the database
- DBAsync has been completely removed from all code
	- Removed zone/dbasync.cpp/.h
	- Removed common/dbasync.cpp/.h
	- Removed dbasync from cmake commmon and zone
- Cleaned up a ton of functions
- Added several tables to world CheckDatabaseConversions script:
	- `character_skills`
	- `character_languages`
	- `character_bind`
	- `character_alternate_abilities`
	- `character_currency`
	- `character_data`
	- `character_spells`
	- `character_memmed_spells`
	- `character_disciplines`
	- `character_material`
	- `character_tribute`
	- `character_bandolier`
	- `character_potionbelt`
- Character select now loads from `character_data`
- Character creation now creates to `character_data`
- Updated function Database::UpdateName to use `character_data`
- Updated function Database::CheckUsedName to use `character_data`
- Updated function Database::MoveCharacterToZone to use `character_data`
- Updated function Database::SetLoginFlags to use `character_data`
- Updated function Database::SetFirstLogon to use `character_data`
- Updated function Database::SetLFG to use `character_data`
- Removed CopyCharacter functions and commands, to be recreated later since it never worked to begin with
- Removed SharedDatabase::SetPlayerProfile
- Trimmed down redundant case switch statements for World sendpackets to QueryServ
- Added Character Methods to Database class:
	Loads:
		bool	LoadCharacterBandolier(uint32 character_id, PlayerProfile_Struct* pp);
		bool	LoadCharacterTribute(uint32 character_id, PlayerProfile_Struct* pp);
		bool	LoadCharacterPotions(uint32 character_id, PlayerProfile_Struct* pp);
	Saves:
		bool	SaveCharacterBindPoint(uint32 character_id, uint32 zone_id, uint32 instance_id, float x, float y, float z, float heading, uint8 is_home);
		bool	SaveCharacterCurrency(uint32 character_id, PlayerProfile_Struct* pp);
		bool	SaveCharacterData(uint32 character_id, uint32 account_id, PlayerProfile_Struct* pp);
		bool	SaveCharacterAA(uint32 character_id, uint32 aa_id, uint32 current_level);
		bool	SaveCharacterSpellSwap(uint32 character_id, uint32 spell_id, uint32 from_slot, uint32 to_slot);
		bool	SaveCharacterSpell(uint32 character_id, uint32 spell_id, uint32 slot_id);
		bool	SaveCharacterMemorizedSpell(uint32 character_id, uint32 spell_id, uint32 slot_id);
		bool	SaveCharacterMaterialColor(uint32 character_id, uint32 slot_id, uint32 color);
		bool	SaveCharacterSkill(uint32 character_id, uint32 skill_id, uint32 value);
		bool	SaveCharacterLanguage(uint32 character_id, uint32 lang_id, uint32 value);
		bool	SaveCharacterDisc(uint32 character_id, uint32 slot_id, uint32 disc_id);
		bool	SaveCharacterTribute(uint32 character_id, PlayerProfile_Struct* pp);
		bool	SaveCharacterBandolier(uint32 character_id, uint8 bandolier_id, uint8 bandolier_slot, uint32 item_id, uint32 icon, const char* bandolier_name);
		bool	SaveCharacterPotionBelt(uint32 character_id, uint8 potion_id, uint32 item_id, uint32 icon);
	Deletes:
		bool	DeleteCharacterSpell(uint32 character_id, uint32 spell_id, uint32 slot_id);
		bool	DeleteCharacterMemorizedSpell(uint32 character_id, uint32 spell_id, uint32 slot_id);
		bool	DeleteCharacterDisc(uint32 character_id, uint32 slot_id);
		bool	DeleteCharacterBandolier(uint32 character_id, uint32 band_id);
2014-09-04 07:24:17 -05:00
Akkadius 0a9222e1ee - 2014-09-01 23:54:15 -05:00
Akkadius e0db3c0b60 Fixed Character select to be loaded from new character data tables 2014-09-01 22:17:06 -05:00
Akkadius ca430e2494 Fix void Database::GetCharName(uint32 char_id, char* name)
Increased MAX_PP_SPELLBOOK to 720 for UF/RoF
Increased MAX_PP_MEMSPELL to 12
Implemented up to 12 spell slots
Fix for public_note default value in bool BaseGuildManager::DBSetGuild(uint32 charid, uint32 guild_id, uint8 rank)
Updated all CastSpell entries to use the appropriate slot type defines located now in zone/common.h
Fixed Guild Loading from character_data
Fixed #guild list
Refactored Merchantlist loading
Refactored Temp Merchantlist loading
Gutted most of dbasync

Added:
LoadCharacterSpellBook(uint32 character_id, PlayerProfile_Struct* pp);
LoadCharacterMemmedSpells(uint32 character_id, PlayerProfile_Struct* pp);
LoadCharacterLanguages(uint32 character_id, PlayerProfile_Struct* pp);
LoadCharacterBindPoint(uint32 character_id, PlayerProfile_Struct* pp);
SaveCharacterSpellSwap(uint32 character_id, uint32 spell_id, uint32 from_slot, uint32 to_slot);
SaveCharacterSpell(uint32 character_id, uint32 spell_id, uint32 slot_id);
SaveCharacterMemorizedSpell(uint32 character_id, uint32 spell_id, uint32 slot_id);
DeleteCharacterSpell(uint32 character_id, uint32 spell_id, uint32 slot_id);
DeleteCharacterMemorizedSpell(uint32 character_id, uint32 spell_id, uint32 slot_id);

Removed Zone::LoadTempMerchantData_result(MYSQL_RES* result)
Removed Zone::LoadMerchantData_result(MYSQL_RES* result)
Removed SharedDatabase::GetPlayerProfile
Removed SharedDatabase::SetPlayerProfile
Removed SharedDatabase::SetPlayerProfile_MQ
Removed Zone::DBAWComplete(uint8 workpt_b1, DBAsyncWork* dbaw) from zone.cpp
2014-08-31 17:52:43 -05:00