I'm trying to write a program that will save your mouse position to a file after you hit a specific hotkey, and then have another bit of code that reads the file and moves the mouse to each position listed in the file, and clicks. I've got most things working but I've run into an issue. Everytime you hit the first hotkey I mentioned, want I want to happen is a variable adds 1 to its self (used later in the code) but when I call on the variable in the second hotkey, the variable is blank. How do I fix this issue?
Here is the code so far.
Spoiler
Can someone tell me what I'm doing wrong? I'm very new to this program, and there is most likely an obvious solution. Please help.