Restrictions With Php/mysql

Restrictions With Php/mysql
Hello, I have a game where players get statistics such as wins and losses.

Let’s say Player1 wins a game against Player2, the Player1 will have a win to his profile, and Player2 will have a loss to his profile.
(You can click on a player to see his record)

All of this is already controlled by PHP and MySQL.

Though, let’s say Player1 is friends with Player2, and Player2 decides to give him “Freewins”, for example they will play 100 games on which Player2 will leave right at the start of the game.

I want to avoid this, and my idea is to simple add a restriction using the IP adresses of the players.

The IP adresses of each player are ALREADY recorded in MySQL.

The plan is, let’s say BOB plays against JACK one game, and Bob wins, he gets his win and Jack gets his loss. Then, any game they play afterwards WILL NOT BE COUNTED before let’s say 15 minutes.
They CAN play again for fun, but the record will not be counted, unless they play for real because a game lasts about 15 minutes.

Simple PHP/MySQL work, should be done fast and the price should be reasonable.

Leave a Reply

Your email address will not be published. Required fields are marked *