[{"data":1,"prerenderedAt":640},["ShallowReactive",2],{"/shapes":3,"/shapes-surround":629},{"id":4,"title":5,"body":6,"description":597,"extension":598,"meta":599,"navigation":617,"path":626,"seo":627,"stem":12,"__hash__":628},"content/shapes.md","Shapes",{"type":7,"value":8,"toc":572},"minimark",[9,21,25,28,71,79,96,106,117,124,129,143,146,151,163,174,181,192,201,204,207,230,233,236,250,259,262,265,274,285,294,300,309,320,329,332,335,338,347,350,359,366,373,382,391,394,413,424,431,438,462,465,505,508,511,566],[10,11,15],"h1",{"id":12,"className":13},"shapes",[14],"section-heading",[16,17,5],"a",{"className":18,"href":20},[19],"section-anchor","#shapes",[22,23,24],"p",{},"The Turtle and Link Shape Editors allows you to create and save turtle and link\ndesigns.",[22,26,27],{},"NetLogo uses fully scalable and rotatable vector shapes, which means you can\ncreate designs by combining basic geometric elements, which can appear on-screen\nin any size or orientation.",[29,30,33,43],"div",{"className":31},[32],"toc",[34,35,38],"h4",{"id":36,"className":37},"table-of-contents",[14],[16,39,42],{"className":40,"href":41},[19],"#table-of-contents","Table of Contents",[44,45,46,53,59,65],"ul",{},[47,48,49],"li",{},[16,50,52],{"href":51},"#getting-started","Getting started",[47,54,55],{},[16,56,58],{"href":57},"#creating-and-editing-turtle-shapes","Creating and editing turtle shapes",[47,60,61],{},[16,62,64],{"href":63},"#creating-and-editing-link-shapes","Creating and editing link shapes",[47,66,67],{},[16,68,70],{"href":69},"#using-shapes-in-a-model","Using shapes in a model",[72,73,76],"h2",{"id":74,"className":75},"getting-started",[14],[16,77,52],{"className":78,"href":51},[19],[22,80,81,82,86,87,90,91,95],{},"To begin making shapes, choose ",[83,84,85],"strong",{},"Turtle Shapes Editor"," or ",[83,88,89],{},"Link Shapes\nEditor"," in the Tools menu. A new window will open listing all the shapes\ncurrently in the model, beginning with ",[92,93,94],"em",{},"default",", the default shape. The Shapes\nEditor allows you to edit shapes, create new shapes, and borrow from another\nmodel. You can also import turtle shapes from a library of pre-existing shapes.",[97,98,101],"h3",{"id":99,"className":100},"importing-shapes",[14],[16,102,105],{"className":103,"href":104},[19],"#importing-shapes","Importing shapes",[22,107,108,109,112,113,116],{},"Every new model in NetLogo starts off containing a small core set of frequently\nused shapes. Many more turtle shapes are available by using the ",[83,110,111],{},"Import from\nlibrary…"," button. This brings up a dialog where you can select one or more\nshapes and bring them into your model. Select the shapes, then press the\n",[83,114,115],{},"Import"," button.",[22,118,119,120,123],{},"Similarly, you can use the ",[83,121,122],{},"Import from model…"," button to borrow shapes from\nanother model.",[22,125,126],{},[83,127,128],{},"Default shapes",[22,130,131,132],{},"Here are the turtle shapes that are included by default in every new NetLogo\nmodel: ",[133,134],"img",{"alt":135,"className":136,"src":138,"width":139,"height":140,"style":141},"shapes/shapes.png",[137],"netlogo-image","/_content/images/shapes/shapes.png",420,360,{"aspectRatio":142},"420/360",[22,144,145],{},"First row: default, airplane, arrow, box, bug, butterfly, car Second row:\ncircle, circle 2, cow, cylinder, dot, face happy, face neutral Third row: face\nsad, fish, flag, flower, house, leaf, line Fourth row: line half, pentagon,\nperson, plant, sheep, square, square 2 Fifth row: star, target, tree, triangle,\ntriangle 2, truck, turtle Sixth row: wheel, x",[22,147,148],{},[83,149,150],{},"Shapes library",[22,152,153,154],{},"And here are the shapes in the shapes library (including all of the default\nshapes, too): ",[133,155],{"alt":156,"className":157,"src":158,"width":159,"height":160,"style":161},"shapes/library.png",[137],"/_content/images/shapes/library.png",396,756,{"aspectRatio":162},"396/756",[22,164,165,166],{},"By default there is only one Link shape in a model, that is “default”. This\nshape is simply a single straight line with a simple arrowhead (if the link\nhappens to be directed). ",[133,167],{"alt":168,"className":169,"src":170,"width":171,"height":171,"style":172},"shapes/defaultlinkshape.png",[137],"/_content/images/shapes/defaultlinkshape.png",330,{"aspectRatio":173},"330/330",[72,175,178],{"id":176,"className":177},"creating-and-editing-turtle-shapes",[14],[16,179,58],{"className":180,"href":57},[19],[22,182,183,184,187,188,191],{},"Pressing the ",[83,185,186],{},"New"," button will make a new shape. Or, you may select an\nexisting shape and press ",[83,189,190],{},"Edit",".",[97,193,196],{"id":194,"className":195},"tools",[14],[16,197,200],{"className":198,"href":199},[19],"#tools","Tools",[22,202,203],{},"In the upper left corner of the editing window is a group of drawing tools. The\narrow is the selection tool, which selects an already drawn element.",[22,205,206],{},"To draw a new element, use one of the other seven tools:",[44,208,209,216],{},[47,210,211,212,215],{},"The ",[83,213,214],{},"line"," tool draws line segments.",[47,217,211,218,221,222,225,226,229],{},[83,219,220],{},"circle",", ",[83,223,224],{},"square",", and ",[83,227,228],{},"polygon"," tools come in two versions, solid\nand outline.",[22,231,232],{},"When using the polygon tool, click the mouse to add a new segment to the\npolygon. When you’re done adding segments, double click.",[22,234,235],{},"After you draw a new element, it is selected, so you can move, delete, or\nreshape it if you want:",[44,237,238,241,244,247],{},[47,239,240],{},"To move it, drag it with the mouse",[47,242,243],{},"To delete it, press the Delete button.",[47,245,246],{},"To reshape it, drag the small “handles” that appear on the element only when\nit is selected.",[47,248,249],{},"To change its color, click on the new color.",[97,251,254],{"id":252,"className":253},"previews",[14],[16,255,258],{"className":256,"href":257},[19],"#previews","Previews",[22,260,261],{},"As you draw your shape, you will also see it in five smaller sizes in the five\npreview areas found near the bottom of the editing window. The previews show\nyour shape as it might appear in your model, including how it looks as it\nrotates. The number below each preview is the size of the preview in pixels.\nWhen you edit the view, patch size is also measured in pixels. So for example,\nthe preview with “20” below it shows you how your shape would look on a turtle\n(of size 1) on patches of size 20 pixels.",[22,263,264],{},"The rotatable feature can be turned off if you want a shape that always faces\nthe same way, regardless of the turtle’s heading.",[97,266,269],{"id":267,"className":268},"overlapping-shapes",[14],[16,270,273],{"className":271,"href":272},[19],"#overlapping-shapes","Overlapping shapes",[22,275,276,277,280,281,284],{},"New elements go on top of previous elements. You can change the layering order\nby selecting an element and then using the ",[83,278,279],{},"Bring to front"," and ",[83,282,283],{},"Send to\nback"," buttons.",[97,286,289],{"id":287,"className":288},"undo",[14],[16,290,293],{"className":291,"href":292},[19],"#undo","Undo",[22,295,296,297,299],{},"At any point you can use the ",[83,298,293],{}," button to undo the edit you just\nperformed.",[97,301,304],{"id":302,"className":303},"colors",[14],[16,305,308],{"className":306,"href":307},[19],"#colors","Colors",[22,310,311,312,315,316,319],{},"Elements whose color matches the ",[92,313,314],{},"Color that changes"," (selected from a drop-down\nmenu — the default is gray) will change color according to the value of each\nturtle’s ",[92,317,318],{},"color"," variable in your model. Elements of other colors don’t change.\nFor example, you could create cars that always have yellow headlights and black\nwheels, but different body colors.",[97,321,324],{"id":322,"className":323},"other-buttons",[14],[16,325,328],{"className":326,"href":327},[19],"#other-buttons","Other buttons",[22,330,331],{},"The “Rotate Left” and “Rotate Right” buttons rotate elements by 90 degrees. The\n“Flip Horizontal” and “Flip Vertical” buttons reflect elements across the axes.",[22,333,334],{},"These four buttons will rotate or flip the entire shape, unless an element is\nselected, in which case only that element is affected.",[22,336,337],{},"These buttons are especially handy in conjunction with the “Duplicate” button if\nyou want to make shapes that are symmetrical. For example, if you were making a\nbutterfly, you could draw the butterfly’s left wing with the polygon tool, then\nduplicate the wing with the “Duplicate” button, then turn the copy into a right\nwing with the “Flip Horizontal” button.",[97,339,342],{"id":340,"className":341},"shape-design",[14],[16,343,346],{"className":344,"href":345},[19],"#shape-design","Shape design",[22,348,349],{},"It’s tempting to draw complicated, interesting shapes, but remember that in most\nmodels, the patch size is so small that you won’t be able to see very much\ndetail. Simple, bold, iconic shapes are usually best.",[97,351,354],{"id":352,"className":353},"keeping-a-shape",[14],[16,355,358],{"className":356,"href":357},[19],"#keeping-a-shape","Keeping a shape",[22,360,361,362,365],{},"When the shape is done, give it a name and press the ",[83,363,364],{},"Done"," button at the\nbottom of the editing window. The shape and its name will now be included in the\nlist of shapes along with the “default” shape.",[72,367,370],{"id":368,"className":369},"creating-and-editing-link-shapes",[14],[16,371,64],{"className":372,"href":63},[19],[22,374,375,376,378,379,381],{},"Managing link shapes is very similar to managing turtle shapes. So, you can\ncreate a new shape by pressing the ",[83,377,186],{}," button or you can edit existing\nshapes. When you are done editing a shape press ",[83,380,364],{}," if you want to keep it.",[97,383,386],{"id":384,"className":385},"changing-link-shape-properties",[14],[16,387,390],{"className":388,"href":389},[19],"#changing-link-shape-properties","Changing link shape properties",[22,392,393],{},"There are several different properties for each link shape that you are allowed\nto change:",[44,395,396,399,404,407,410],{},[47,397,398],{},"Name - link shapes can have the same name as turtle shapes but must be unique\namong link shapes.",[47,400,401,402,116],{},"Direction Indicator - the direction indicator (the little arrow on directed\nlinks) is just like the turtle vector shapes, you can edit it using the same\neditor by pressing the ",[83,403,190],{},[47,405,406],{},"Curviness - this is the amount of bend in a link expressed in patches (this is\nparticularly useful if you have directed links going in both directions so you\ncan discern both links)",[47,408,409],{},"Number of lines: You can have 1, 2, or 3 lines in each link shape, you control\nthis by selecting line patterns in the “left line”, “middle line”, and “right\nline” selection boxes.",[47,411,412],{},"Dash pattern of lines: There are several dashed line patterns available in the\nselection boxes so not all lines need be solid.",[22,414,415,416],{},"Here are some link shapes with various properties: ",[133,417],{"alt":418,"className":419,"src":420,"width":421,"height":421,"style":422},"shapes/linkshapes.png",[137],"/_content/images/shapes/linkshapes.png",380,{"aspectRatio":423},"380/380",[72,425,428],{"id":426,"className":427},"using-shapes-in-a-model",[14],[16,429,70],{"className":430,"href":69},[19],[22,432,433,434,437],{},"In the model’s code or in the command center, you can use any of the shapes that\nare in the model (though only turtles can have turtle shapes and only links can\nhave link shapes). For example, suppose you want to create 50 turtles with the\nshape “rabbit”. Provided there is some turtle shape called ",[92,435,436],{},"rabbit"," in this\nmodel, give this command to the observer in the command center:",[439,440,441],"pre",{},[442,443,444,451,452,451,457],"code",{},[445,446,450],"span",{"className":447},[448,449],"token","variable","observer>"," ",[445,453,456],{"className":454},[448,455],"command","crt",[445,458,461],{"className":459},[448,460],"number","50",[22,463,464],{},"And then give these commands to the turtles to spread them out, then change\ntheir shape:",[439,466,467],{},[442,468,469,451,473,451,477,451,482,486,489,451,492,451,496,451,500],{},[445,470,472],{"className":471},[448,449],"turtles>",[445,474,476],{"className":475},[448,455],"fd",[445,478,481],{"className":479},[448,480],"reporter","random",[445,483,485],{"className":484},[448,460],"15",[487,488],"br",{},[445,490,472],{"className":491},[448,449],[445,493,495],{"className":494},[448,455],"set",[445,497,499],{"className":498},[448,480],"shape",[445,501,504],{"className":502},[448,503],"string","\"rabbit\"",[22,506,507],{},"Voila! Rabbits! Note the use of double quotes around the shape name. Shape names\nare strings.",[22,509,510],{},"Similarly, you can set the shape variable of links. Assuming there is a link\nshape called “road” in this model:",[439,512,513],{},[442,514,515,451,518,451,521,525,526,451,530,451,534,538,539,541,451,544,451,547,550,552,451,556,451,559,451,562],{},[445,516,450],{"className":517},[448,449],[445,519,456],{"className":520},[448,455],[445,522,524],{"className":523},[448,460],"5"," [ ",[445,527,529],{"className":528},[448,455],"create-links-with",[445,531,533],{"className":532},[448,480],"other",[445,535,537],{"className":536},[448,480],"turtles"," ]",[487,540],{},[445,542,472],{"className":543},[448,449],[445,545,476],{"className":546},[448,455],[445,548,524],{"className":549},[448,460],[487,551],{},[445,553,555],{"className":554},[448,449],"links>",[445,557,495],{"className":558},[448,455],[445,560,499],{"className":561},[448,480],[445,563,565],{"className":564},[448,503],"\"road\"",[22,567,211,568,571],{},[442,569,570],{},"set-default-shape"," command is also useful for assigning shapes to turtles\nand links.",{"title":573,"searchDepth":574,"depth":575,"links":576},"",5,3,[577,579,583,593,596],{"id":36,"depth":578,"text":42},4,{"id":74,"depth":580,"text":52,"children":581},2,[582],{"id":99,"depth":575,"text":105},{"id":176,"depth":580,"text":58,"children":584},[585,586,587,588,589,590,591,592],{"id":194,"depth":575,"text":200},{"id":252,"depth":575,"text":258},{"id":267,"depth":575,"text":273},{"id":287,"depth":575,"text":293},{"id":302,"depth":575,"text":308},{"id":322,"depth":575,"text":328},{"id":340,"depth":575,"text":346},{"id":352,"depth":575,"text":358},{"id":368,"depth":580,"text":64,"children":594},[595],{"id":384,"depth":575,"text":390},{"id":426,"depth":580,"text":70},"The Turtle and Link Shape Editors allow you to create and save turtle and link designs using fully scalable and rotatable vector shapes.","md",{"source":600,"metadataOutputPath":601,"projectConfig":602,"language":609,"inheritFrom":618,"output":617,"version":603,"keywords":619,"tags":624,"assetsRoot":625},"autogen/shapes.md","content/shapes.metadata.yaml",{"version":603,"projectRoot":191,"scanRoot":604,"outputRoot":605,"defaults":606,"engine":612,"partials":613,"dedupeIdenticalDiskWrites":617},"7.0.4","autogen","content",{"inheritFrom":607,"language":609,"output":610,"extension":598,"title":611,"version":603},[608],0,"en",false,"NetLogo User Manual","handlebars",{"directoryPaths":614,"extensions":615},[191],[616,598],"mustache",true,[608],[5,620,621,622,623],"Turtle Shapes","Link Shapes","Shape Editor","NetLogo",[5,620,621,622],"/home/runner/work/Helio/Helio/apps/docs/autogen","/shapes",{"title":5,"description":597},"bTgXo9gA1qxPpsLoWh4uaQv_WOWVkPnyfMD5hFje7j8",[630,635],{"title":631,"path":632,"stem":633,"description":634},"Sample Model","/sample","sample","Walkthrough of a sample NetLogo model to demonstrate key concepts and features of the modeling environment.",{"title":636,"path":637,"stem":638,"description":639},"Sound Extension","/sound","sound","Documentation for the Sound extension.",1777657789124]