Patch Coordinates Example
Model was written in NetLogo 5.0.4
•
Viewed 1403 times
•
Downloaded 77 times
•
Run 0 times
Do you have questions or comments about this model? Ask them here! (You'll first need to log in.)
Comments and Questions
Please start the discussion about this model!
(You'll first need to log in.)
Click to Run Model
breed [centers center] breed [searchers searcher] to setup clear-all ask patches [ set pcolor gray ] ask patch start-x start-y [ set pcolor green ] create-searchers 1 [ set heading 0 set color red set size 0.2 set shape "circle" setxy start-x start-y ] create-centers 1 [ set color blue set size 0.1 set shape "circle" setxy start-x start-y ] reset-ticks end to go ;; this is to reset the patches to gray so it changes ;; when you move the start-x or start-y slider ask patches [ set pcolor gray ] ;; this resets the center turtle to the point indicated by the sliders ask centers [ setxy start-x start-y ] ask searchers [ setxy start-x start-y ;; return to center set pcolor green rt 5 ;; it goes clockwise in 5 degree increments fd distance-of-travel ;; go back out to edge of circle set pcolor black ] tick end ; Public Domain: ; To the extent possible under law, Uri Wilensky has waived all ; copyright and related or neighboring rights to this model.
There are 10 versions of this model.
Attached files
File | Type | Description | Last updated | |
---|---|---|---|---|
Patch Coordinates Example.png | preview | Preview for 'Patch Coordinates Example' | over 11 years ago, by Uri Wilensky | Download |
This model does not have any ancestors.
This model does not have any descendants.