As for the problems with the game going to the wrong directory, this is actually a client-side problem related to Flash and its handling of POST variables. The way the script works is like this:
script gets "play" request from user
script sends game, user, highscore, and location of forums to a flash game
flash game plays
flash game ends, and sends game, user, score to the page defined in location
script takes that data and keeps going
So basically, what's happening is that Flash is not correctly sending the location back to the script via POST.
Because of the problems with this, one option is to change the script to use GET. This means that the URL bar would look something like this:
http://www.yoursite.com/forum/proarcade.php?action=gameover&game=tetris&score=45 6000&whatever
Obviously this creates a problem in that people can see how the score is being passed and just enter it manually. So I'm thinking that we'd need to put an MD5 hash on it before transmission, and I'm not sure that Flash's ActionScript can do that. So I'm kind of stumped as where to go from here.
I will keep working on a solution...
|