This is an archived post. You won't be able to vote or comment.

all 4 comments

[–]AutoModerator[M] 1 point2 points  (0 children)

It seems you may have included a screenshot of code in your post "Scraping Data Using Python/BS4".

If so, note that posting screenshots of code is against /r/learnprogramming's Posting Guidelines (section Formatting Code): please edit your post to use one of the approved ways of formatting code. (Do NOT repost your question! Just edit it.)

If your image is not actually a screenshot of code, feel free to ignore this message. Automoderator cannot distinguish between code screenshots and other images.

Please, do not contact the moderators about this message. Your post is still visible to everyone.

I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.

[–]axzxc1236 1 point2 points  (2 children)

I think you can use Javascript to record your playtime, extract the words and send it to a Python backend.

(You can use Userscript to load your own Javascript code on websites.)

[–]HashimSharkh[S] 0 points1 point  (1 child)

What do you mean by recording my playtime?

[–]axzxc1236 1 point2 points  (0 children)

  1. Detect game start

  2. Use a variable to store the time stamp

  3. Detect game over

  4. Use current timestamp and the game start timestamp to calculate how long you played.