Skip to content

Commit

Permalink
Add 4.4.1 support
Browse files Browse the repository at this point in the history
todo: replace ptr build with first live build
  • Loading branch information
funjoker committed Oct 27, 2024
1 parent dc01a27 commit cb701f5
Show file tree
Hide file tree
Showing 56 changed files with 7,878 additions and 1 deletion.
2 changes: 2 additions & 0 deletions WowPacketParser/Enums/ClientVersionBuild.cs
Original file line number Diff line number Diff line change
Expand Up @@ -812,6 +812,8 @@ public enum ClientVersionBuild
V4_4_0_56713 = 56713, // live
V4_4_0_57244 = 57244, // live

V4_4_1_57141 = 57141, // ptr

// Battle.net - should probably not mix this but oh well
BattleNetV37165 = 37165,

Expand Down
5 changes: 5 additions & 0 deletions WowPacketParser/Enums/Version/Opcodes.cs
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
using WowPacketParser.Enums.Version.V4_3_3_15354;
using WowPacketParser.Enums.Version.V4_3_4_15595;
using WowPacketParser.Enums.Version.V4_4_0_54481;
using WowPacketParser.Enums.Version.V4_4_1_57141;
using WowPacketParser.Enums.Version.V5_0_4_16016;
using WowPacketParser.Enums.Version.V5_0_5_16048;
using WowPacketParser.Enums.Version.V5_1_0_16309;
Expand Down Expand Up @@ -962,6 +963,8 @@ public static ClientVersionBuild GetOpcodeDefiningBuild(ClientVersionBuild build
case ClientVersionBuild.V4_4_0_56713:
case ClientVersionBuild.V4_4_0_57244:
return ClientVersionBuild.V4_4_0_54481;
case ClientVersionBuild.V4_4_1_57141:
return ClientVersionBuild.V4_4_1_57141;
default:
return ClientVersionBuild.V3_3_5a_12340;
}
Expand Down Expand Up @@ -1139,6 +1142,8 @@ public static BiDictionary<Opcode, int> GetOpcodeDictionary(ClientVersionBuild b
return Opcodes_3_4_3.Opcodes(direction);
case ClientVersionBuild.V4_4_0_54481:
return Opcodes_4_4_0.Opcodes(direction);
case ClientVersionBuild.V4_4_1_57141:
return Opcodes_4_4_1.Opcodes(direction);
default:
return Opcodes_3_3_5.Opcodes(direction);
}
Expand Down
4 changes: 4 additions & 0 deletions WowPacketParser/Enums/Version/UpdateFields.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1179,6 +1179,10 @@ private static string GetUpdateFieldDictionaryBuildName(ClientVersionBuild build
{
return "V4_4_0_54481";
}
case ClientVersionBuild.V4_4_1_57141:
{
return "V4_4_1_57141";
}
default:
{
return "V3_3_5a_12340";
Expand Down
1,663 changes: 1,663 additions & 0 deletions WowPacketParser/Enums/Version/V4_4_1_57141/Opcodes.cs

Large diffs are not rendered by default.

2 changes: 2 additions & 0 deletions WowPacketParser/Misc/ClientVersion.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1367,6 +1367,7 @@ public static ClientVersionBuild GetVersionDefiningBuild(ClientVersionBuild buil
case ClientVersionBuild.V4_4_0_56489:
case ClientVersionBuild.V4_4_0_56713:
case ClientVersionBuild.V4_4_0_57244:
case ClientVersionBuild.V4_4_1_57141:
return ClientVersionBuild.V4_4_0_54481;
case ClientVersionBuild.BattleNetV37165:
return ClientVersionBuild.BattleNetV37165;
Expand Down Expand Up @@ -1889,6 +1890,7 @@ public static bool IsCataClientVersionBuild(ClientVersionBuild build)
case ClientVersionBuild.V4_4_0_56489:
case ClientVersionBuild.V4_4_0_56713:
case ClientVersionBuild.V4_4_0_57244:
case ClientVersionBuild.V4_4_1_57141:
return true;
default:
return false;
Expand Down
6 changes: 5 additions & 1 deletion WowPacketParserModule.V4_4_0_54481/Parsers/SpellHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,11 @@ public static void ReadSpellCastLogData(Packet packet, params object[] idx)
// SpellLogPowerData
for (var i = 0; i < spellLogPowerDataCount; ++i)
{
packet.ReadInt32("PowerType", idx, i);
if (ClientVersion.AddedInVersion(ClientVersionBuild.V4_4_1_57141))
packet.ReadByte("PowerType", idx, i);
else
packet.ReadInt32("PowerType", idx, i);

packet.ReadInt32("Amount", idx, i);
packet.ReadInt32("Cost", idx, i);
}
Expand Down
Loading

0 comments on commit cb701f5

Please sign in to comment.