mirror of
https://github.com/Mezeporta/Erupe.git
synced 2025-12-12 23:14:36 +01:00
enumerate missing clients
This commit is contained in:
@@ -29,6 +29,9 @@ func handleMsgSysEnumerateClient(s *Session, p mhfpacket.MHFPacket) {
|
||||
for _, cid := range stage.clients {
|
||||
clients = append(clients, cid)
|
||||
}
|
||||
for cid := range stage.reservedClientSlots {
|
||||
clients = append(clients, cid)
|
||||
}
|
||||
case 1: // Not ready
|
||||
for cid, ready := range stage.reservedClientSlots {
|
||||
if !ready {
|
||||
|
||||
@@ -386,7 +386,11 @@ func handleMsgSysEnumerateStage(s *Session, p mhfpacket.MHFPacket) {
|
||||
|
||||
bf.WriteUint16(uint16(len(stage.reservedClientSlots)))
|
||||
bf.WriteUint16(uint16(len(stage.clients)))
|
||||
bf.WriteUint16(uint16(len(stage.clients)))
|
||||
if strings.HasPrefix(stage.id, "sl2Ls") {
|
||||
bf.WriteUint16(uint16(len(stage.clients) + len(stage.reservedClientSlots)))
|
||||
} else {
|
||||
bf.WriteUint16(uint16(len(stage.clients)))
|
||||
}
|
||||
bf.WriteUint16(stage.maxPlayers)
|
||||
var flags uint8
|
||||
if stage.locked {
|
||||
|
||||
Reference in New Issue
Block a user