sketch [5]

Anti-surveillance Tool

my code here

Description

I just want to build a treasure map, I think that is a kind of anti-surveillance way to connect different people in different position and time. Then I think the treasure on the Internet is bitcoin, which is thought to be the safest way to trade, so I make a fake trade process. The main logic is: (1)Click the mouse, you will get the x,y parameter value of the bitcoin called "hide spot" on the left top of the screen (2)move your mouse, when your mouse is put on the specific location of hide spot, it will show a bitcoin pic representing that you find one (3)it will show the amount of the bitcoin you found already on the right top of the screen (4)press m to show/hide the direction line to modify your difficulty of the game

Process & Reflection

There are 3 questions I solved during the process: 1. direction line. I want to draw a line to link the random point and the mouse, and it will use the linear equation knowledge which I almost forget for 4 years, it really reminds me of my high school memory. 2. count amount. I separate two values of appearance and count. so that it won't count every time when I move the mouse onto the same position, only continue to count until I click the mouse to generate the next new bitcoin 3. random position. This is easier, I use the int() function to make the position value integrate so that it will be able to move the mouse to the accurate position more feasible.