Closed Fi1osof closed 10 months ago
I think is working correctly for what I can see. roomEntrySlotCount
is the number of currently in-room clients and it has to be smaller than the room max clients number in hub.room_size
otherwise we would allow hub.room_size
+ 1 clients connected. Let me know if I missed anything.
@keianhzo let hub.room_size = 3 currently roomEntrySlotCount = 2 and < hub.room_size (3). OK. But in this case in room will be never 3 users (cause candidate can not enter room). So room_size === 2?
Fix canEnterRoom method. Should be <= instead <, cause roomEntrySlotCount includes current user. Last user can not enter.