Multiplayer using SQL database - speed test

There are a lot of options for multiplayer games. I haven't properly dug into GM networking functions but have used SQL databases to store information online.

I wondered how fast it is using GM http_post to a .php file which then talks to a SQL database - so decided to do a speed test.

RESULTS:
Write speed averaged 450ms
Read speed averaged 230ms

Code:
// SQL CODE INSIDE PHP FILE

// Write
UPDATE table_name
SET pencil_x = '$pencilX', pencil_y = '$pencilY'
WHERE player_id = '$playerID'

// Read
SELECT pencil_x, pencil_y FROM table_name WHERE player_id = '$playerID';

It was faster than I expected but nowhere near fast enough for a platformer game, only puzzle/turn-based games would suit.

Check out the 4k video below to see GML code and the speed test in operation:

 
Top