Thread Rating:
  • 1 Vote(s) - 4 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Turtle graphics
#15
Wonderful  Big Grin
Thank you Tomaaz, your Turtle library is very useful to produce amazing turtle graphics / arts.
Thank you also to Marcus for giving us an insight regarding numbers in n7.

Herewith another turtle experiment :
   

First experiment : turtle library contained int()           
     produced "shifted green lines"

Second experiment : turtle library without int()  
     produced clean blue lines

Code:
'-------------------------------------------------------------
' Modified turtle library
'  First Experiment : function forward (dlugosc) with int()
'  Second Experiment :function forward3(dlugosc) without int()
'-------------------------------------------------------------

include "turtle_modified.n7"

set window "Turtle Experiment",640,360
reset() 'set angle to 0
set color 0,0,0;cls 'clear screen
iteration = 100

'FIRST experiment
set color 0,255,0 'green
goxy(300,120)
for i = 1 to iteration
    forward(50)
    turnleft(45)
next

'SECOND experiment
set color 0,0,255 'blue
goxy(350,120)
for i = 1 to iteration
    forward3(50)
    turnleft(45)
next

'pause
pln "Press ENTER to quit"
temp = rln()
Reply


Messages In This Thread
Turtle graphics - by Tomaaz - 02-13-2024, 05:13 PM
RE: Turtle graphics - by Marcus - 02-13-2024, 05:58 PM
RE: Turtle graphics - by johnno56 - 02-13-2024, 07:28 PM
RE: Turtle graphics - by Tomaaz - 02-13-2024, 08:09 PM
RE: Turtle graphics - by johnno56 - 02-13-2024, 08:57 PM
RE: Turtle graphics - by Tomaaz - 02-13-2024, 11:37 PM
RE: Turtle graphics - by Marcus - 02-14-2024, 07:28 PM
RE: Turtle graphics - by Tomaaz - 02-14-2024, 08:54 PM
RE: Turtle graphics - by 1micha.elok - 02-15-2024, 04:11 AM
RE: Turtle graphics - by Tomaaz - 02-15-2024, 08:18 AM
RE: Turtle graphics - by 1micha.elok - 02-15-2024, 09:22 AM
RE: Turtle graphics - by Tomaaz - 02-15-2024, 12:17 PM
RE: Turtle graphics - by Marcus - 02-15-2024, 06:59 PM
RE: Turtle graphics - by Tomaaz - 02-15-2024, 08:35 PM
RE: Turtle graphics - by 1micha.elok - 02-16-2024, 02:22 AM

Forum Jump:


Users browsing this thread: 1 Guest(s)