Hi,
I am getting this error.
{ DATA IN } : <msg t='sys'><body action='joinRoom' r='1'><room id='1' pwd='' spec='0' leave='1' old='1' /></body></msg>
[ INFO ] > Room Join Error: User is already in this room!, User: "my mail ID", IP: ???????
[ INFO ] > { DATA OUT } : <msg t='sys'><body action='joinKO' r='0'><error msg='User is already in this room!' /></body></msg>
Can anyone help??
Room Join Error : User is already in this room
Re: Room Join Error : User is already in this room
I have restarted the server then also it is coming.
What's the cause?
Thanks,
Prasoon
What's the cause?
Thanks,
Prasoon
Re: Room Join Error : User is already in this room
Please check the server-side log. An error should be reported there.
This happens if you try to join the same Room twice. Maybe there's a bug in your code making the user join twice?
This happens if you try to join the same Room twice. Maybe there's a bug in your code making the user join twice?
Paolo Bax
The SmartFoxServer Team
The SmartFoxServer Team
Re: Room Join Error : User is already in this room
Hey bax,
Thanks a lot bax.
I have checked the codes at server side and whenever a user is leaving the room from "handleInternalEvent", I have given a room.removeUser(user, true, true). I have tried a lot but the error still persists.
Actually, What the client is doing is, when a user wants to leave a room it sends a join room to lobby and send the user to lobby without calling anything at server-side to leave the room. Can this be the root of the issue??
Thanks a lot bax.
I have checked the codes at server side and whenever a user is leaving the room from "handleInternalEvent", I have given a room.removeUser(user, true, true). I have tried a lot but the error still persists.
Actually, What the client is doing is, when a user wants to leave a room it sends a join room to lobby and send the user to lobby without calling anything at server-side to leave the room. Can this be the root of the issue??
Re: Room Join Error : User is already in this room
First of all you don't have to remove the user from the Room manually. The server will do it for you. This is mandatory.
Also, when you need to join a Room leaving the previous one, you have to pass a specific parameter to the joinRoom method. The server will then handle this for you.
Also, when you need to join a Room leaving the previous one, you have to pass a specific parameter to the joinRoom method. The server will then handle this for you.
Paolo Bax
The SmartFoxServer Team
The SmartFoxServer Team
Re: Room Join Error : User is already in this room
Hey Bax,
Thanks a lot.
But i have not yet been able to resolve it. Is there any support/paid for sfs?
Thanks,
Prasoon
Thanks a lot.
But i have not yet been able to resolve it. Is there any support/paid for sfs?
Thanks,
Prasoon
Re: Room Join Error : User is already in this room
I don't think you need paid support to solve this. Also we don't provide code reviews.
The error you shown at the very beginning is quite straightforward: the user is trying to join the same Room two times.
The reason could be an error in your code, or maybe when moving from one Room to the other, you are not leaving the first one.
For example when the user connects he joins Room A. Then he moves to Room B without leaving Room A. If then he goes back to Room A, the server will trace that error.
The error you shown at the very beginning is quite straightforward: the user is trying to join the same Room two times.
The reason could be an error in your code, or maybe when moving from one Room to the other, you are not leaving the first one.
For example when the user connects he joins Room A. Then he moves to Room B without leaving Room A. If then he goes back to Room A, the server will trace that error.
Paolo Bax
The SmartFoxServer Team
The SmartFoxServer Team
Return to “SmartFoxServer 1.x Discussions and Help”
Who is online
Users browsing this forum: No registered users and 66 guests