
In this practice, I tried to create a simple game by detecting an object to gain the points. As you can see in this picture, once the ruler showed up on the screen, a red horizontal line will move with it at the same time. When the red line crossed through the blue line, we can get the positive score and in the meanwhile both of the blue and yellow lines will get thicker. However, if the red line went down below the blue one, the blue and yellow lines will no longer get thicker and the score will be deducted gradually. I used plenty of pointers to deal with the X-axis and Y-axis, and that was indeed a complicated part for me.
沒有留言:
張貼留言