Log off
  • 15 posts
  • Page 1 of 1
momagajic wrote:
It would be good if the program automatically logged off players showing no activity for 1 hour.
It is hard to know if there are enough players actually online to fill the games I create, because a lot of players stay logged on when they are away from D12.      
Crystal wrote:
I really like this idea, since I think I forgot to log out last night...
momagajic wrote:
I look first who is online and then choose what point limit to put ,then start sendind invites and private mesages ,most of them answer to me tomorow and say oh i always leave D12 online !! We dont need this automatic log off if all players going to be fair to others and simply close d12 when is away,its just showing a litlle respect for others and nothing more ,then people can see real picture who is online and who is not..
Matty wrote:
But... how do you see they are online? Only because they are active right?
That should only show if they actually do something...

If that's not the case, than that should be fixed, not randomly starting to log out ppl...
"Strength doesn't lie in numbers, strength doesn't lie in wealth. Strength lies in nights of peaceful slumbers." ~Maria
momagajic wrote:
Yes Matty show is like they online ,last activity is shows in seconds.yes i think bcause they active ..
aeronautic wrote:
moma is right, it shows people who are not active, as if they have been active within x seconds, players that you know are not online as you send them a PM and get the reply the next day of, "sorry I didn't log out, but shut my computer down".
It might be because somebody is making them active, by sending them a PM or clicking on their profile, but I doubt it, because I have noticed for years that inactive players constantly refresh as active in the "Who's online" page.
Hyd yn oed er fy mod Cymraeg , dim ond yn siarad Saesneg, felly yr wyf yn gobeithio y bydd y cyfieithu yn gywir.
Vexer wrote:
This is how "last active" works. You see the black bar with some links at the very top of the page? That is called the user bar. Every 30 seconds code gets run to check to see if you have any turns or messages. This is also when your last active is updated. So leaving any page open will make it look like you are still online even if you haven't clicked on anything.

Matty, would it be possible to add some code to global.js to only update the last active if there has been mouse movement on the page in the last 30 seconds?
Matty wrote:
It's certainly possible, but I'm very unsure as to how easy it is to do. Don't have that much time around now...
"Strength doesn't lie in numbers, strength doesn't lie in wealth. Strength lies in nights of peaceful slumbers." ~Maria
Matty wrote:
Ok. implemented it. It now no longer should show someone as active unless he actually views one of the pages and moves his mouse.

Not sure how it works for touch devices, but oh well.

Edit: Should work now, although I can't test it - somebody tell me if you are not active when using an iPhone or something.
"Strength doesn't lie in numbers, strength doesn't lie in wealth. Strength lies in nights of peaceful slumbers." ~Maria
Matty wrote:
Yes, the point is that they should stay as active if they touch the screen...
With this 'fix' they could otherwise be inactive even if they are playing a game...
"Strength doesn't lie in numbers, strength doesn't lie in wealth. Strength lies in nights of peaceful slumbers." ~Maria
Vexer wrote:
Wow, It's surprising now that we have more accurate stats for how many players are online. Looks like 3/5ths of the browsers open to the site were inactive.

Once I saw that I modified Matty's code to also not update the rest of the user bar data (turns, messages, games waiting for players) if there hasn't been mouse movement in the last 30 seconds. I also coded it to update immediately once mouse movement is detected again. This should save the server some work and hopefully improve performance a little.

This means that leaving the site open in another inactive tab should no longer use server resources.

I can't believe how easy this was to code. I wish we had done it long ago.

Also, I tested it on my phone and it worked fine.
Matty wrote:
Vexer - May 13, 03:37 AM
This means that leaving the site open in another inactive tab should no longer use server resources.
Assuming you leave it open on a page that does not do manual updates, like a page with a chat lobby (live/LTG lobbies, game page, etc...)
"Strength doesn't lie in numbers, strength doesn't lie in wealth. Strength lies in nights of peaceful slumbers." ~Maria
Vexer wrote:
Yes, correct. If you leave it open to the live game lobby or long term game room you will still hit the server every 10 or 30 seconds. The game page will only hit the server if players are taking turns. If the game is over or it's a long term game then it will eventually stop auto refreshing. But any other page on the site can be safely left open all day.