Create: Difference between revisions

From StarLogo Nova Wiki
(Marked this version for translation)
No edit summary
Line 2: Line 2:
<translate>
<translate>


<!--T:1-->
 
[[Category:Agents]]
[[Category:Agents]]
<section begin=image/>[[File:Create Block.png|alt=The create block|thumb]]<section end=image/>
<section begin=image/>[[File:Create Block.png|alt=The create block|thumb]]<section end=image/>
{{#vardefine:create|<code>create [_] [▼](s)</code>}}
{{#vardefine:create|<code>create [_] [▼](s)</code>}}
<section begin=name/>'''<code>create [_] [▼](s)</code>'''<section end=name/> is a [[code block]] part of the [[agents]] drawer.
<section begin=name/>'''<code>create [_] [▼](s)</code>'''<section end=name/> is a [[code block]] part of the [[agents]] drawer.
</translate>
<translate>
==Usage==
==Usage==
</translate>


<!--T:2-->
<translate>
<p id="tooltip"><code>create [_] [▼](s)</code> is used to populate [[Spaceland]] with [[agent]]s.</p>
<p id="tooltip"><code>create [_] [▼](s)</code> is used to populate [[Spaceland]] with [[agent]]s.</p>
</translate>


===Syntax=== <!--T:3-->
<translate>
===Syntax===
</translate>


<!--T:4-->
<translate>
<code> create [Textbox: Number] [Dropdown: Type of Agent](s) </code>
<code> create [Textbox: Number] [Dropdown: Type of Agent](s) </code>
</translate>


==Nuances== <!--T:5-->
<translate>
==Nuances==  
</translate>


<!--T:6-->
<translate>
An important difference between {{#var:create}} and {{#vardefineecho:cedol|<code>[[Create Each Do|create [_] [▼](s) each do</code>]]}} is that {{#vardefineecho:cedo|<code>create [_] [▼](s) each do</code>}} allows a section of code to run individually for each [[agent]] that is created. {{#var:create}} only creates agents with the default [[trait]]s in the center of [[Spaceland]].
An important difference between {{#var:create}} and {{#vardefineecho:cedol|<code>[[Create Each Do|create [_] [▼](s) each do</code>]]}} is that {{#vardefineecho:cedo|<code>create [_] [▼](s) each do</code>}} allows a section of code to run individually for each [[agent]] that is created. {{#var:create}} only creates agents with the default [[trait]]s in the center of [[Spaceland]].
</translate>


<!--T:7-->
<translate>
{{#var:cedol}} can be useful for [[randomizing traits]] and [[scattering agents without effecting others]].
{{#var:cedol}} can be useful for [[randomizing traits]] and [[scattering agents without effecting others]].
</translate>


<!--T:8-->
<translate>
==Related Blocks==
==Related Blocks==
*{{#var:cedol}}
*{{#var:cedol}}
</translate>


==Relevant Video Resources== <!--T:9-->
<translate>
==Relevant Video Resources==
</translate>


<!--T:10-->
<translate>
==Relevant Activities==
==Relevant Activities==
[[Category:Code Block]]
[[Category:Code Block]]


</translate>
</translate>

Revision as of 19:01, 16 May 2023

Other languages:
The create block

create [_] [▼](s) is a code block part of the agents drawer.

Usage

create [_] [▼](s) is used to populate Spaceland with agents.

Syntax

create [Textbox: Number] [Dropdown: Type of Agent](s)

Nuances

An important difference between create [_] [▼](s) and create [_] [▼](s) each do is that create [_] [▼](s) each do allows a section of code to run individually for each agent that is created. create [_] [▼](s) only creates agents with the default traits in the center of Spaceland.

create [_] [▼](s) each do can be useful for randomizing traits and scattering agents without effecting others.

Related Blocks

Relevant Video Resources

Relevant Activities