Scatter: Difference between revisions

From StarLogo Nova Wiki
No edit summary
No edit summary
Line 1: Line 1:
{{#vardefine:scatter|<code>scatter</code>}}
== Usage ==
== Usage ==
<code>scatter</code> is used to scatter an agent to a random location in [[SpaceLand]].
<code>scatter</code> is used to scatter an agent to a random location in [[SpaceLand]].
Line 4: Line 6:
===Syntax===
===Syntax===
<code>scatter</code>
<code>scatter</code>
==Nuances==
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]].
{{#var:cedol}} can be useful for [[randomizing traits]] and [[scattering agents without effecting others]].

Revision as of 17:35, 8 August 2022


Usage

scatter is used to scatter an agent to a random location in SpaceLand.

Syntax

scatter

Nuances

An important difference between 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. 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.