From 459161dbba9a350ecdae1f0cc2b12d2ae3f0a3b8 Mon Sep 17 00:00:00 2001
From: beleko <
[email protected]>
Date: Mon, 25 Jan 2010 09:25:45 +0100
Subject: [PATCH] {289] Fix Character Create and Crash when you logged in the World ! Thanks lecails for Help
Signed-off-by: beleko <
[email protected]>
---
.../character_updates_dual_spec.sql | 2 +-
src/game/Player.cpp | 7 ++++---
src/shared/revision_nr.h | 2 +-
3 files changed, 6 insertions(+), 5 deletions(-)
diff --git a/sql/evo-X Updates/Dual_Specialization/character_updates_dual_spec.sql b/sql/evo-X Updates/Dual_Specialization/character_updates_dual_spec.sql
index 81cb7ea..b0f167a 100644
--- a/sql/evo-X Updates/Dual_Specialization/character_updates_dual_spec.sql
+++ b/sql/evo-X Updates/Dual_Specialization/character_updates_dual_spec.sql
@@ -36,7 +36,7 @@ DELETE FROM `character_spell` WHERE `spell` IN (12505,12522,12523,12524,12525,12
DELETE FROM `character_spell` WHERE `spell` IN (3674,5420,9800,19263,20927,20928,20929,20930,24905,27174,27179,31904,32699,32700,33072,33891,34123,48359,48824,48825,48826,48827,48951,48952,50170,50171,50172,50306,50536,51373,51374,51375,51376,51378,51379,52881,53640,55265,55270,55271,57019,57224,62795,63668,63669,63670,63671,63672,64299,65139);
-ALTER TABLE `characters` ADD `speccount` tinyint(3) unsigned NOT NULL default 1 AFTER `arena_pending_points`;
+ALTER TABLE `characters` ADD `speccount` tinyint(3) unsigned NOT NULL default 1 AFTER `power7`;
ALTER TABLE `characters` ADD `activespec` tinyint(3) unsigned NOT NULL default 0 AFTER `speccount`;
ALTER TABLE `character_action` RENAME `character_action_old`;
diff --git a/src/game/Player.cpp b/src/game/Player.cpp
index b556156..c82c968 100644
--- a/src/game/Player.cpp
+++ b/src/game/Player.cpp
@@ -14800,7 +14800,7 @@ bool Player::LoadFromDB( uint32 guid, SqlQueryHolder *holder )
//"resettalents_time, trans_x, trans_y, trans_z, trans_o, transguid, extra_flags, stable_slots, at_login, zone, online, death_expire_time, taxi_path, dungeon_difficulty,"
// 40 41 42 43 44 45 46 47 48 49 50
//"arenaPoints, totalHonorPoints, todayHonorPoints, yesterdayHonorPoints, totalKills, todayKills, yesterdayKills, chosenTitle, knownCurrencies, watchedFaction, drunk,"
- // 51 52 53 54 55 56 57 58
+ // 51 52 53 54 55 56 57 58 59 60
//"health, power1, power2, power3, power4, power5, power6, power7, speccount, activespec FROM characters WHERE guid = '%u'", GUID_LOPART(m_guid));
QueryResult *result = holder->GetResult(PLAYER_LOGIN_QUERY_LOADFROM);
@@ -15218,7 +15218,7 @@ bool Player::LoadFromDB( uint32 guid, SqlQueryHolder *holder )
m_specsCount = fields[41].GetUInt32();
m_activeSpec = fields[42].GetUInt32();
- delete result;
+ /*delete result;*/
// sanity check
if (m_specsCount > MAX_TALENT_SPECS || m_activeSpec > MAX_TALENT_SPEC ||
@@ -16496,7 +16496,8 @@ void Player::SaveToDB()
for(uint32 i = 0; i < MAX_POWERS; ++i)
ss << "," << GetPower(Powers(i));
-
+
+ ss << ", ";
ss << uint32(m_specsCount);
ss << ", ";
ss << uint32(m_activeSpec);
and
From 855ed8a15e109d12bdde331fe28553760903ee5f Mon Sep 17 00:00:00 2001
From: beleko <
[email protected]>
Date: Mon, 25 Jan 2010 12:49:30 +0100
Subject: [PATCH] [291] More DualSpec Updates Thanks ganjoula
Signed-off-by: beleko <
[email protected]>
---
src/game/Player.cpp | 4 ++--
src/shared/revision_nr.h | 2 +-
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/src/game/Player.cpp b/src/game/Player.cpp
index c82c968..34b8ccc 100644
--- a/src/game/Player.cpp
+++ b/src/game/Player.cpp
@@ -15216,8 +15216,8 @@ bool Player::LoadFromDB( uint32 guid, SqlQueryHolder *holder )
// Mail
_LoadMail();
- m_specsCount = fields[41].GetUInt32();
- m_activeSpec = fields[42].GetUInt32();
+ m_specsCount = fields[59].GetUInt32();
+ m_activeSpec = fields[60].GetUInt32();
/*delete result;*/