Jump to content

Recommended Posts

Posted

Good morning,

I am looking for a code where I can make an online query on the website how many players are currently online, who has something like that by chance ? or can anyone give me a tip ?

 

 

Greetz.

  • 2 weeks later...
Posted

Hi

What can you do easily is to:

1. Create a table either a new variable into an existing table with name "currentOnlinePlayers" ( or whatever name you want to give to it )

2. Update using a query ( MySQL in my case ) every time a player logs in..

3. Get that value using a query into your web application.

Pros:

You have it, the viable solution, but it's doable at least as a first POC ( proof of concept ) / MVS (minimum viable solution)

Cons:

It doesn't update asynchronous, using a thread - player needs to refresh the page to see latest update from database.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...