Difference between revisions of "See-a Condition"
Jump to navigation
Jump to search
imported>Andri |
imported>Andri |
||
Line 1: | Line 1: | ||
− | [[image: | + | [[image:Next to condition.png|150px]] |
− | |||
<table cellpadding="10" cellspacing="0" border="0" width="100%"> | <table cellpadding="10" cellspacing="0" border="0" width="100%"> | ||
<tr> | <tr> | ||
<td align="left" valign="top" width="80"><b>Definition:</b></td> | <td align="left" valign="top" width="80"><b>Definition:</b></td> | ||
− | <td align="left" valign="top" width="100%">The <strong> | + | <td align="left" valign="top" width="100%">The <strong>Next-to</strong> condition checks to see how many of the adjacent neighbors have a certain [[Shape parameter|shape]]. If the agent is next to the right number of the specified shapes, the condition is true. Otherwise, the condition is false.</td> |
</tr> | </tr> | ||
<tr> | <tr> | ||
<td align="left" valign="top" width="80"><b>Parameters:</b></td> | <td align="left" valign="top" width="80"><b>Parameters:</b></td> | ||
− | <td align="left" valign="top" width="100%">[[ | + | <td align="left" valign="top" width="100%">[[Comparator parameter|comparator]], [[Formula parameter|formula]], [[Shape parameter|shape]] </td> |
− | |||
− | |||
− | |||
− | |||
</tr> | </tr> | ||
<tr> | <tr> | ||
<td align="left" valign="top" width="80"><b>Example:</b></td> | <td align="left" valign="top" width="80"><b>Example:</b></td> | ||
− | <td align="left" valign="top" width="100%"> | + | <td align="left" valign="top" width="100%"> The Person agent in the Virus Attack project checks if it is next to one or more sick Person agents. If so, it has a 5% chance of acquiring the virus. |
− | [[Image: | + | [[Image:Next to condition example.png|500px]]</td> |
</tr> | </tr> | ||
Revision as of 17:42, 17 June 2011
Definition: | The Next-to condition checks to see how many of the adjacent neighbors have a certain shape. If the agent is next to the right number of the specified shapes, the condition is true. Otherwise, the condition is false. |
Parameters: | comparator, formula, shape |
Example: | The Person agent in the Virus Attack project checks if it is next to one or more sick Person agents. If so, it has a 5% chance of acquiring the virus. |