Computer Science Canada Turing Boat |
Author: | asdf001 [ Wed Apr 02, 2008 12:17 pm ] |
Post subject: | Turing Boat |
Hi, Im wondering how i can create a boat in turing and if someone can post a example. |
Author: | Tony [ Wed Apr 02, 2008 12:38 pm ] |
Post subject: | Re: Turing Boat |
here's a boat |
Author: | petree08 [ Wed Apr 02, 2008 1:16 pm ] |
Post subject: | RE:Turing Boat |
put "boat" |
Author: | asdf001 [ Wed Apr 02, 2008 8:18 pm ] |
Post subject: | Re: Turing Boat |
I ment on drawline and drawbox can someone post a example of that ? |
Author: | Nyrd [ Wed Apr 02, 2008 8:37 pm ] |
Post subject: | Re: Turing Boat |
Giving you an example would essentially be doing it for you. If you know how to use Draw.Line and such, just tinker with it until you figure it out. If you don't know how to use the Draw functions, the inbuilt Turing help is pretty good and http://compsci.ca/v3/viewtopic.php?t=8808 also helps ALOT! |
Author: | asdf001 [ Wed Apr 02, 2008 8:53 pm ] |
Post subject: | Re: Turing Boat |
Nyrd @ Wed Apr 02, 2008 8:37 pm wrote: Giving you an example would essentially be doing it for you.
If you know how to use Draw.Line and such, just tinker with it until you figure it out. If you don't know how to use the Draw functions, the inbuilt Turing help is pretty good and http://compsci.ca/v3/viewtopic.php?t=8808 also helps ALOT! The draw line command is confusing i dont know how to make it move to make it move a certain part of the screen and sometimes the line goes big |
Author: | Nyrd [ Wed Apr 02, 2008 9:12 pm ] | ||||
Post subject: | RE:Turing Boat | ||||
In order to draw a line from point A to point B on the screen you would need to use the Draw.Line command. In the following x1 and y1 would be equal to the coordinates of point A, and x2 and y2 would be equal to the coordinates of point B, colour is equal to the colour of the line.
to make the line move you just erase and redraw it a bit further down. That can be done like this (This line moves across the screen)
If that doesn't help enough, give us whatever code you have and we'll help from there. |
Author: | Tony [ Fri Apr 04, 2008 12:32 am ] |
Post subject: | RE:Turing Boat |
http://compsci.ca/blog/if-a-programming-language-was-a-boat/ |
Author: | theone07 [ Thu Jan 22, 2009 3:39 pm ] |
Post subject: | RE:Turing Boat |
hey guys i really need some help with turing on how to write number conversion programs i.e. binary to decimal etc. please help!!!!!!! |
Author: | andrew. [ Thu Jan 22, 2009 4:29 pm ] |
Post subject: | RE:Turing Boat |
Hey Tony, everytime I click that link in Safari, Safari stops responding. I've never really looked at the blog in Safari before, but if all the pages are like that, you should try and fix it. It worked fine in Camino though and the article makes sense. |
Author: | dc116 [ Fri Jan 23, 2009 4:46 pm ] |
Post subject: | RE:Turing Boat |
Uhh, just out of curiosity, how do you draw the water waves? It would be really difficult with Draw.Arc! |
Author: | saltpro15 [ Fri Jan 23, 2009 5:21 pm ] |
Post subject: | RE:Turing Boat |
wouldn't be that difficult... |
Author: | A.J [ Fri Jan 23, 2009 5:34 pm ] |
Post subject: | RE:Turing Boat |
I believe that you can simulates the waves by means of trigonometric functions (i.e. sine and cosine waves) you can translate it to your needs to make it look like whaever from of water waves you want |
Author: | DanielG [ Fri Jan 23, 2009 5:36 pm ] |
Post subject: | RE:Turing Boat |
it's not that hard, use sin, for i : 1 .. size of your screen, drawline (i,0, 50+10*sind(i), blue) end for I can't use turing now to check, but it should work. |