
-----------------------------------
mballaz
Sun Apr 05, 2009 3:06 pm

Analog 60 second timer- How to make the hand rotate
-----------------------------------
Hi, i'm new to turing and i was wondering how i can make a hand on the 60 second analog timer rotate if the center of the clock would be at the center of the screen. the size of the circle doesn't really matter. 
Thanks

-----------------------------------
Tony
Sun Apr 05, 2009 3:10 pm

RE:Analog 60 second timer- How to make the hand rotate
-----------------------------------
You know one point (center), length of the hand, and the angle (time). Calculate the location of the second point, and draw a line in between.

-----------------------------------
saltpro15
Sun Apr 05, 2009 3:11 pm

Re: Analog 60 second timer- How to make the hand rotate
-----------------------------------
use [url=http://compsci.ca/v3/viewtopic.php?t=11453&highlight=loops]for loops and the drawline command

-----------------------------------
tjmoore1993
Sun Apr 05, 2009 3:18 pm

Re: RE:Analog 60 second timer- How to make the hand rotate
-----------------------------------
You know one point (center), length of the hand, and the angle (time). Calculate the location of the second point, and draw a line in between.



360 / 60 = 6

1 second = 6 degrees

Equation(Linear)
D=6s
D=6(60)
D=360

60=6s
s=6/60
s=10

-----------------------------------
mballaz
Sun Apr 05, 2009 4:33 pm

Re: Analog 60 second timer- How to make the hand rotate
-----------------------------------
i was hoping it would be like the rotating house example, so that i wouldn't need to redraw the line

-----------------------------------
DanielG
Sun Apr 05, 2009 5:05 pm

RE:Analog 60 second timer- How to make the hand rotate
-----------------------------------
there are probably commands you can use, however, the things mentioned above combined with simple trig should be more than enough.

-----------------------------------
Zren
Mon Apr 06, 2009 3:03 pm

Re: Analog 60 second timer- How to make the hand rotate
-----------------------------------
i was hoping it would be like the rotating house example, so that i wouldn't need to redraw the line

So you would rather redraw a picture? Either way, to animate something you'll have to redraw something.
