mirror of
https://github.com/2revoemag/PSF-BotServer.git
synced 2026-01-20 02:24:45 +00:00
Allow multiple OCDM per bundle
This commit is contained in:
parent
4dd414589b
commit
fdc87516c1
|
|
@ -181,9 +181,15 @@ class MiddlewareActor(
|
|||
|
||||
packet match {
|
||||
// Super awkward special case: Bundling CharacterInfoMessage with OCDM causes the character selection
|
||||
// to show blank lines and be broken. So we only dequeue either if they are the first packet.
|
||||
case _: CharacterInfoMessage | _: ObjectCreateDetailedMessage =>
|
||||
length == packetLength
|
||||
// to show blank lines and be broken. So we make sure CharacterInfoMessage is always sent as the only
|
||||
// packet in a bundle.
|
||||
case _: CharacterInfoMessage =>
|
||||
if (length == packetLength) {
|
||||
length += MTU
|
||||
true
|
||||
} else {
|
||||
false
|
||||
}
|
||||
case _ =>
|
||||
// Some packets may be larger than the MTU limit, in that case we dequeue anyway and split later
|
||||
// We deduct some bytes to leave room for SlottedMetaPacket (4 bytes) and MultiPacketEx (2 bytes + prefix per packet)
|
||||
|
|
|
|||
Loading…
Reference in a new issue