Web Development
Date : August 2017
Found a way better way to make the multiplayer tic tac toe game. Instead of using ajax and php calls (which are way too complex), Use Socket.io and Node.js.
Socket programming enables to simulate server-client mechanism which solves the problem to a great deal.
Configured the project with socket.io and now a game over web can be played. It is still restricted to only two players at a time, and players have to wait until one game finishes.
Date : 5 June 2017
Enabled the user to reset the game board when he requires by using jquery.
Date : 4 June 2017
Updated the website to prevent users from staying idle for too long. The technique is simple. Use AJAX in a setInterval javascript function, that sends a request to a php file, containing the username of the user. The php file checks if the user exists in the database of online users (which is updated every 5 minutes). If user doesn't exists there, alert them about the timeout, and refresh the page.
Date : 3 June 2017
Till now, updated the website to enable same computer multiplayer tic-tac-toe using AJAX, PHP, JavaScript and MySQL. The website is hosted on dlinkddns, and the server resides on the personal computer.
Comments
Post a Comment