Hex+Code


 * < Hexagonal <

globals [ticks] breed [ draw ] breed [ erase ]

to setup ca cct 1 [ set color white fd 1 pd ] end

to add-draw cct 1 [ setxy 0 0 set heading 0 pd] end

to add-erase cct 1 [ set color red setxy 0 0 set heading 0 pe] end

to go ask turtles [ move reproduce die ] set ticks (ticks + 1) end
 * if ticks = 15500 [ stop ]

to move let num-turtles-right 0 let num-turtles-left 0

ifelse ((random 2) = 0) [ go-left set num-turtles-left (num-turtles-left + 1) ] [ go-right set num-turtles-right (num-turtles-right + 1) ] end

to go-left lt 45 one-pace end

to go-right rt 45 one-pace end

to one-pace fd 1 end
 * set heading 0
 * fd 1

to reproduce hatch 1 [ fd 1 ] end


 * <hex<