Short answer; You can't. The only difference between flash (et.al.) games and js games in this regard is that in flash games it's harder to figure out how to cheat because the source code has to be decompiled first.
The only way of validating a high-score is by submitting the set of commands used to achieve the high-score for playback validation. This isn't feasible or viable for every game by the way. However, if you do and you do implement this, you'll have a nice way of allowing other players to replay a certain high score. I've seen the mechanisms applied in td's and point-and-click games. - peter On Tue, Dec 14, 2010 at 3:08 PM, 冷雨 <[email protected]> wrote: > If I write a javascript game(e.x. classical Pacman) which has a online > rank list, like most flash game. > It send players' scores to server by XMLHttpRequest, and then refresh > the rank list. > How can I avoid cheating? If a player write his/her own javascript > sending my server "999999"? > As javascript run on client entirely, how can I know whether a message > is from my script or not? > > -- > To view archived discussions from the original JSMentors Mailman list: > http://www.mail-archive.com/[email protected]/ > > To search via a non-Google archive, visit here: > http://www.mail-archive.com/[email protected]/ > > To unsubscribe from this group, send email to > [email protected]<jsmentors%[email protected]> > -- To view archived discussions from the original JSMentors Mailman list: http://www.mail-archive.com/[email protected]/ To search via a non-Google archive, visit here: http://www.mail-archive.com/[email protected]/ To unsubscribe from this group, send email to [email protected]
