netlogo - What do I need to add to this code to allow me to draw road networks? -


  globals [road?] If you have to go down the mouse? [EDIT_TOOL = "Road" [Ask Patch [Set P Color Black]] If EDITIT = = "Grass" [Ask Patch [Set Poccur Green]] [Edit] End  

I I want to create a road network with this code. How do I specify the size of the patch and the size of the patch that I want to attract?

In a netlogo world, all the patches are always the same size (square) and the same size (1 In netlogo world units, and on the screen, though many pixels are in model settings).

Then, "How do I specify the size of the patch and the size of the patch that I want to attract?" That is, you can not.

You have the code almost right, but you need to remove the use of the ask patches to edit-world > process, and do the job Should you already ask ... [edit-world] , so editing-world is already a patch process, so understand it Do not come again ask patch.


Comments