Binato/server/Packets/UserPresenceBundle.js

15 lines
364 B
JavaScript
Raw Normal View History

const osu = require("osu-packet");
2020-08-27 13:09:35 +01:00
module.exports = function(currentUser) {
const osuPacketWriter = new osu.Bancho.Writer;
let userIds = [];
for (let i = 0; i < global.users.length; i++) {
userIds.push(global.users[i].id);
}
osuPacketWriter.UserPresenceBundle(userIds);
currentUser.addActionToQueue(osuPacketWriter.toBuffer);
}