diff --git a/changelog.txt b/changelog.txt index 312abf5b9..dfebe38c0 100644 --- a/changelog.txt +++ b/changelog.txt @@ -2,13 +2,19 @@ EQEMu Changelog (Started on Sept 24, 2003 15:50) ------------------------------------------------------- == 10/28/2013 == Uleat: Client patch prep work for extending usable skill range (no apparent issues with Ti through RoF[12-10-2012] testing - i.e., clients showed proper skills and they didn't crash) +Uleat: This final patch aligns the existing server PlayerProfile_Struct with the previous changes. The pp_struct, as well as the character 'pp' blob, remains unchanged in size and alignment. The only difference is that the first trailing 100 bytes of the unknown array have been re-assigned to the skills array, and the unknown array decreased by the same amount. +Notes: + - The existing configuration will allow the use of any new skills up to 99 + - Due to this new segment of the blob having never been written to properly, we may have erratic data there that needs to be cleared before use + - None of the new skills are coded to use these 'new' skill slots + - A per-client method will still need to be observed when coding for the new skill uses == 10/27/2013 == Uleat: Attempted fix for high level (12) debug compile failiures Notes: - - Explicit Windows vs. Linus code was not changed due to my inability to compile Linux code + - Explicit Windows vs. Linux code was not changed due to my inability to compile Linux code - Only CMake accessible flags were corrected if adding the 'std' namespace did not correct the issue - - the tag [CODEBUG] was added to code identifed by the above note + - the tag [CODEBUG] was added to failed code identifed by the above note - If you are having compile issues after this patch is committed, look to the changes here first Uleat: Changed riposte fail check to proper failure criteria - (x == a && x == b, where a != b) never passes, so skills a and b can riposte (discovery find, no known reported occurences) Uleat: Enforced naming standard on my recent changes (Sorry for any inconviencies) diff --git a/common/eq_packet_structs.h b/common/eq_packet_structs.h index 81114edc0..758decc45 100644 --- a/common/eq_packet_structs.h +++ b/common/eq_packet_structs.h @@ -802,8 +802,7 @@ struct SuspendedMinion_Struct static const uint32 MAX_PP_LANGUAGE = 28; static const uint32 MAX_PP_SPELLBOOK = 480; // Increased to 480 to support SoF static const uint32 MAX_PP_MEMSPELL = 9; -static const uint32 MAX_PP_SKILL = 75; // still in-use server-side - this must remain 75 until all code and database can be changed -//static const uint32 MAX_PP_SKILL = _SkillPacketArraySize; // 100 +static const uint32 MAX_PP_SKILL = _SkillPacketArraySize; // 100 - actual skills buffer size static const uint32 MAX_PP_AA_ARRAY = 240; static const uint32 MAX_GROUP_MEMBERS = 6; static const uint32 MAX_RECAST_TYPES = 20; @@ -942,9 +941,8 @@ struct PlayerProfile_Struct /*4764*/ int32 copper_cursor; // Copper on cursor /*4768*/ int32 platinum_shared; // Platinum shared between characters /*4772*/ uint8 unknown4808[24]; -/*4796*/ uint32 skills[MAX_PP_SKILL]; // currently, 75 dword buffer -/*5096*/ uint8 unknown5132[284]; // this is for 75 dword buffer -///*5196*/ uint8 unknown5132[184]; // this is for 100 dword buffer +/*4796*/ uint32 skills[MAX_PP_SKILL]; // [400] List of skills // 100 dword buffer +/*5196*/ uint8 unknown5132[184]; /*5380*/ uint32 pvp2; // /*5384*/ uint32 unknown5420; // /*5388*/ uint32 pvptype; // diff --git a/common/patches/Client62.cpp b/common/patches/Client62.cpp index d145bf48f..ae8eb7e42 100644 --- a/common/patches/Client62.cpp +++ b/common/patches/Client62.cpp @@ -266,20 +266,7 @@ ENCODE(OP_PlayerProfile) { OUT(silver_cursor); OUT(copper_cursor); - //OUT_array(skills, structs::MAX_PP_SKILL); // 1:1 direct copy (100 dword) - OUT_array(skills, MAX_PP_SKILL); // copy first 75 from server struct - for(r = MAX_PP_SKILL; r < structs::MAX_PP_SKILL; r++) { eq->skills[r] = (uint32)0; } // zero the rest - - /* - // SKILLS TEST - eq->skills[75] = (uint32)5; // SkillRemoveTrap - eq->skills[76] = (uint32)10; // SkillTripleAttack - eq->skills[77] = (uint32)15; // Skill2HPiercing - eq->skills[78] = (uint32)20; // SkillNone - - for(r = MAX_PP_SKILL + 4; r < structs::MAX_PP_SKILL; r++) { eq->skills[r] = (uint32)0; } - // END TEST - */ + OUT_array(skills, structs::MAX_PP_SKILL); // 1:1 direct copy (100 dword) OUT(toxicity); OUT(thirst_level); diff --git a/common/patches/RoF.cpp b/common/patches/RoF.cpp index 65c52ccbc..3577fb6f3 100644 --- a/common/patches/RoF.cpp +++ b/common/patches/RoF.cpp @@ -1020,30 +1020,18 @@ ENCODE(OP_PlayerProfile) outapp->WriteUInt32(structs::MAX_PP_SKILL); - for(uint32 r = 0; r < MAX_PP_SKILL; r++) + for(uint32 r = 0; r < structs::MAX_PP_SKILL; r++) { outapp->WriteUInt32(emu->skills[r]); } + // deprecated // Write zeroes for the rest of the skills + /* for(uint32 r = 0; r < structs::MAX_PP_SKILL - MAX_PP_SKILL; r++) { outapp->WriteUInt32(emu->skills[r]); } - - /* - // SKILLS TEST - outapp->WriteUInt32(5); // SkillRemoveTrap - outapp->WriteUInt32(10); // SkillTripleAttack - outapp->WriteUInt32(15); // Skill2HPiercing - outapp->WriteUInt32(20); // SkillNone - - // Write zeroes for the rest of the skills - for(uint32 r = 0; r < structs::MAX_PP_SKILL - MAX_PP_SKILL - 4; r++) - { - outapp->WriteUInt32(emu->skills[r]); - } - // END TEST */ outapp->WriteUInt32(25); // Unknown count diff --git a/common/patches/SoD.cpp b/common/patches/SoD.cpp index 8506ddc5a..cadd4b8a8 100644 --- a/common/patches/SoD.cpp +++ b/common/patches/SoD.cpp @@ -536,20 +536,7 @@ ENCODE(OP_PlayerProfile) { OUT(silver_cursor); OUT(copper_cursor); - //OUT_array(skills, structs::MAX_PP_SKILL); // 1:1 direct copy (100 dword) - OUT_array(skills, MAX_PP_SKILL); // copy first 75 from server struct - for(r = MAX_PP_SKILL; r < structs::MAX_PP_SKILL; r++) { eq->skills[r] = (uint32)0; } // zero the rest - - /* - // SKILLS TEST - eq->skills[75] = (uint32)5; // SkillRemoveTrap - eq->skills[76] = (uint32)10; // SkillTripleAttack - eq->skills[77] = (uint32)15; // Skill2HPiercing - eq->skills[78] = (uint32)20; // SkillNone - - for(r = MAX_PP_SKILL + 4; r < structs::MAX_PP_SKILL; r++) { eq->skills[r] = (uint32)0; } - // END TEST - */ + OUT_array(skills, structs::MAX_PP_SKILL); // 1:1 direct copy (100 dword) // OUT(unknown04760[236]); OUT(toxicity); diff --git a/common/patches/SoF.cpp b/common/patches/SoF.cpp index f18366d6a..0262858d5 100644 --- a/common/patches/SoF.cpp +++ b/common/patches/SoF.cpp @@ -535,20 +535,7 @@ ENCODE(OP_PlayerProfile) { OUT(silver_cursor); OUT(copper_cursor); - //OUT_array(skills, structs::MAX_PP_SKILL); // 1:1 direct copy (100 dword) - OUT_array(skills, MAX_PP_SKILL); // copy first 75 from server struct - for(r = MAX_PP_SKILL; r < structs::MAX_PP_SKILL; r++) { eq->skills[r] = (uint32)0; } // zero the rest - - /* - // SKILLS TEST - eq->skills[75] = (uint32)5; // SkillRemoveTrap - eq->skills[76] = (uint32)10; // SkillTripleAttack - eq->skills[77] = (uint32)15; // Skill2HPiercing - eq->skills[78] = (uint32)20; // SkillNone - - for(r = MAX_PP_SKILL + 4; r < structs::MAX_PP_SKILL; r++) { eq->skills[r] = (uint32)0; } - // END TEST - */ + OUT_array(skills, structs::MAX_PP_SKILL); // 1:1 direct copy (100 dword) // OUT(unknown04760[236]); OUT(toxicity); diff --git a/common/patches/Titanium.cpp b/common/patches/Titanium.cpp index 7369377fd..2f0e6a607 100644 --- a/common/patches/Titanium.cpp +++ b/common/patches/Titanium.cpp @@ -270,20 +270,7 @@ ENCODE(OP_PlayerProfile) { OUT(silver_cursor); OUT(copper_cursor); - //OUT_array(skills, structs::MAX_PP_SKILL); // 1:1 direct copy (100 dword) - OUT_array(skills, MAX_PP_SKILL); // copy first 75 from server struct - for(r = MAX_PP_SKILL; r < structs::MAX_PP_SKILL; r++) { eq->skills[r] = (uint32)0; } // zero the rest - - /* - // SKILLS TEST - eq->skills[75] = (uint32)5; // SkillRemoveTrap - eq->skills[76] = (uint32)10; // SkillTripleAttack - eq->skills[77] = (uint32)15; // Skill2HPiercing - eq->skills[78] = (uint32)20; // SkillNone - - for(r = MAX_PP_SKILL + 4; r < structs::MAX_PP_SKILL; r++) { eq->skills[r] = (uint32)0; } - // END TEST - */ + OUT_array(skills, structs::MAX_PP_SKILL); // 1:1 direct copy (100 dword) // OUT(unknown04760[236]); OUT(toxicity); diff --git a/common/patches/Underfoot.cpp b/common/patches/Underfoot.cpp index 757640189..0a17ef9e6 100644 --- a/common/patches/Underfoot.cpp +++ b/common/patches/Underfoot.cpp @@ -550,20 +550,7 @@ ENCODE(OP_PlayerProfile) { OUT(silver_cursor); OUT(copper_cursor); - //OUT_array(skills, structs::MAX_PP_SKILL); // 1:1 direct copy (100 dword) - OUT_array(skills, MAX_PP_SKILL); // copy first 75 from server struct - for(r = MAX_PP_SKILL; r < structs::MAX_PP_SKILL; r++) { eq->skills[r] = (uint32)0; } // zero the rest - - /* - // SKILLS TEST - eq->skills[75] = (uint32)5; // SkillRemoveTrap - eq->skills[76] = (uint32)10; // SkillTripleAttack - eq->skills[77] = (uint32)15; // Skill2HPiercing - eq->skills[78] = (uint32)20; // SkillNone - - for(r = MAX_PP_SKILL + 4; r < structs::MAX_PP_SKILL; r++) { eq->skills[r] = (uint32)0; } - // END TEST - */ + OUT_array(skills, structs::MAX_PP_SKILL); // 1:1 direct copy (100 dword) // OUT(unknown04760[236]); OUT(toxicity); diff --git a/utils/player_profile_set/player_profile_set/eq_player_structs.h b/utils/player_profile_set/player_profile_set/eq_player_structs.h index 7b4137dc8..e732757a4 100644 --- a/utils/player_profile_set/player_profile_set/eq_player_structs.h +++ b/utils/player_profile_set/player_profile_set/eq_player_structs.h @@ -738,7 +738,7 @@ struct BindStruct { static const uint32 MAX_PP_LANGUAGE = 28; static const uint32 MAX_PP_SPELLBOOK = 400; static const uint32 MAX_PP_MEMSPELL = 9; -static const uint32 MAX_PP_SKILL = 75; +static const uint32 MAX_PP_SKILL = 100; static const uint32 MAX_PP_AA_ARRAY = 240; static const uint32 MAX_GROUP_MEMBERS = 6; @@ -878,7 +878,7 @@ struct PlayerProfile_Struct /*4768*/ sint32 platinum_shared; // Platinum shared between characters /*4772*/ uint8 unknown3812[24]; // @bp unknown skills? /*4796*/ uint32 skills[MAX_PP_SKILL]; -/*5096*/ uint8 unknown5096[284]; // @bp unknown skills? +/*5196*/ uint8 unknown5096[184]; // @bp unknown skills? /*5380*/ int32 pvp2; // /*5384*/ int32 unknown4420; // /*5388*/ int32 pvptype; //