I've read your comment again, and I see that bin2hex returns a string. Yes I thought it would perform better just to use an integer instead. I can also see now, that on Windows the getrandmax() is…
Yes, that was my intention as well. I just couldn't find the time for implementing and properly testing it, and it's also isn't really part of this story.
Users can even cheat, if they just reload the page, because that resets the timer, or just by pausing the script. That's a bigger issue. But because PHP doesn't support websockets and I didn't want…
I know, but I already put a lot of changes into this PR. I think we should refactor it in a separate story.
Good point. However I don't think it would cause any problems. I thought it would be better to use 4 byte length integers instead of 3 bytes for more possible ids, because challenges are normally not…
My eye is twitching when variables are used outside of the scope of {}, but it's different in PHP, so it can be refactored.
I had to create span from javascript, because I didn't know, how else to control the display css attribute from both css (depending on screen size) and javascript (depending on the game type). Javascript overrides the css attribute even for narrow screens. Is there a more elegant solution?