Assign proper protocol.

This commit is contained in:
MobiusDevelopment
2019-04-30 18:52:46 +00:00
parent fab63ee789
commit 70acd01537
4 changed files with 20 additions and 53 deletions

View File

@@ -101,8 +101,8 @@ MaximumOnlineUsers = 2000
# Numbers of protocol revisions that server allows to connect.
# Delimiter is ;
# WARNING: <u><b><font color="red">Changing the protocol revision may result in incompatible communication and many errors in game!</font></b></u>
# Seven Signs: 152;166
AllowedProtocolRevisions = 152;166
# Secret of Empire: 166
AllowedProtocolRevisions = 166
# Displays server type next to the server name on character selection.
# Notes:

View File

@@ -16,7 +16,6 @@
*/
package org.l2jmobius.gameserver.network.serverpackets;
import org.l2jmobius.Config;
import org.l2jmobius.commons.network.PacketWriter;
import org.l2jmobius.gameserver.model.items.instance.ItemInstance;
import org.l2jmobius.gameserver.network.OutgoingPackets;
@@ -63,30 +62,19 @@ public class EnchantResult implements IClientOutgoingPacket
packet.writeD(_crystal);
packet.writeQ(_count);
if ((Config.PROTOCOL_LIST.size() == 1) && Config.PROTOCOL_LIST.contains(152)) // 152
{
packet.writeD(_enchantLevel);
for (int option : _enchantOptions)
{
packet.writeH(option);
}
}
else
{
// Guessing.
// With 166 options became 3x write integers instead of shorts and enchant level moved bellow.
// Commenting until actually knowing.
// for (int option : _enchantOptions)
// {
// packet.writeD(option);
// }
packet.writeD(0x00);
packet.writeD(0x00);
packet.writeD(0x00);
packet.writeD(_enchantLevel); // Confirmed.
}
// Guessing.
// With 166 options became 3x write integers instead of shorts and enchant level moved bellow.
// Commenting until actually knowing.
// for (int option : _enchantOptions)
// {
// packet.writeD(option);
// }
packet.writeD(0x00);
packet.writeD(0x00);
packet.writeD(0x00);
packet.writeD(_enchantLevel); // Confirmed.
return true;
}