Hi everyone, so I'm working on a chat room and I have a few things that are probably easy but just not clicking for me. I'm attaching the project here for anyone who wants to take a look. i'm not changing much about the project.. the big change is simply to allow users to leave the chat room and come back in. This is working great.. but i have two major issues I'm trying to work out.
1. When a user leaves the room.. others don't see the user leave.. but if the leaving user refreshes their browser, THEN the user disappears for everyone else. I can't find where the logical difference is.
2. How do you properly use kick feature? I tried to use it and none of my efforts resulted in the user being ejected from the room. The multiplayer options all seem really straight forward so I must be missing something more subtle perhaps?
It seems like you could simply grab the name of the person you need to kick and kick "username" and it would remove them.. but i feel like maybe there is further logic needed for it to work.
here is a working example of it. you can actually join multiple times in the same browser with multiple tabs. https://part12studios.com/games/rd_bbs/rd_bbs_62/
here is the file i'm working from right now.
dropbox.com/s/g2ixbgaucqa6u21/BBS_Text%20%28updated%20original%29%20with%20exit%20button%203.zip
I just don't get it.. it does seem like a "peer leaving room" is missing.. vs. "peer disconnected".. but also I just can't see what's going on that a peer refreshing their browser will register a "remove this guy" but my other conditions won't.
And for the life of my, can't see how i could do it differently to insure any time a person leaves a room, their name disappears for everyone else.