Netlogo Hightlight.js Plugin
link
emphasis
strong
string
quote
section
title
variable
bullet
meta
code
regexp
symbol
name
patches-own [
halfrond
]
; Tool de unit
set unit pink
set test false
to setup
; Tool ook hier de unit
clear-all
ask patches [
set pcolor 8
set plabel pxcor
]
ask patches with [(pxcor + pycor) mod 2 = 0] [
set pcolor 106
]
end
to patroon
clear-all
ask patches [
set pcolor 8
set plabel pycor
set plabel-color 25
ifelse pycor > 0
[set halfrond "noord"]
[set halfrond "zuid"]
]
ask patches with [(pxcor + pycor) mod 2 = 0] [
set pcolor (abs pxcor + abs pycor + 10)
]
end
breed [mice mouse]
breed [frogs frog]
mice-own [cheese]
to tool
create-turtles
ask turtles
end
to do
ifelse pxcor < -2 [
set pcolor green
][
set pcolor red
]
if pxcor > 2 [
set pcolor yellow
set test -"string"
]
end
to setup
clear-all
create-mice 50
[ set color white
set cheese random 10 ]
create-frogs 50
[ set color green ]
reset-ticks
end