Call (returns)/es: Difference between revisions
(Created page with "Category:Procedimientos Category:Code Block") |
(Updating to match new version of source page) |
||
Line 2: | Line 2: | ||
<div lang="en" dir="ltr" class="mw-content-ltr"> | <div lang="en" dir="ltr" class="mw-content-ltr"> | ||
<section begin=image/>[[File:Call_(returns).png|alt=The Call (returns) Block|thumb]]<section end=image/><p id="tooltip">Calls a procedure that returns a value.</ | <section begin=image/>[[File:Call_(returns).png|alt=The Call (returns) Block|thumb]]<section end=image/><p id="tooltip">The value that is returned when this specified procedure is called.</p> | ||
</div> | |||
<div lang="en" dir="ltr" class="mw-content-ltr"> | |||
==Usage== | |||
</div> | |||
<div lang="en" dir="ltr" class="mw-content-ltr"> | |||
Calls a procedure that returns a value. | |||
</div> | |||
<div lang="en" dir="ltr" class="mw-content-ltr"> | |||
==Syntax== | |||
</div> | |||
<div lang="en" dir="ltr" class="mw-content-ltr"> | |||
Inputs in this block: | |||
#a created procedure that returns a numerical value from the dropdown menu | |||
</div> | |||
<div lang="en" dir="ltr" class="mw-content-ltr"> | |||
==Example== | |||
</div> | |||
<div lang="en" dir="ltr" class="mw-content-ltr"> | |||
[[File:call_(returns)_example.gif|alt=Call (returns) example gif|thumb]] | |||
[[File:call_(returns)_example.png|alt=Call (returns) example code|thumb]] | |||
</div> | |||
<div lang="en" dir="ltr" class="mw-content-ltr"> | |||
In this model, a created [[Special:MyLanguage/Procedure|procedure]] calculates the distance of the “Turtle” agent from the center of spaceland using the pythagorean theorem. Whenever the calculate distance button is pushed, the [[Special:MyLanguage/Procedure|procedure]] ‘Calculate Distance’ is called and the distance from the center is displayed in a data box. Note that this shape of the call block is used to retrieve the returned information from the [[Special:MyLanguage/Procedure|procedure]]. | |||
</div> | |||
<div lang="en" dir="ltr" class="mw-content-ltr"> | |||
==Related Blocks== | |||
</div> | |||
<div lang="en" dir="ltr" class="mw-content-ltr"> | |||
*[[Special:MyLanguage/Call|Call]] | |||
</div> | </div> | ||
[[Category:Procedimientos]] | [[Category:Procedimientos]] | ||
[[Category:Code Block]] | [[Category:Code Block]] |
Latest revision as of 19:26, 14 August 2023
Usage
Calls a procedure that returns a value.
Syntax
Inputs in this block:
- a created procedure that returns a numerical value from the dropdown menu
Example
In this model, a created procedure calculates the distance of the “Turtle” agent from the center of spaceland using the pythagorean theorem. Whenever the calculate distance button is pushed, the procedure ‘Calculate Distance’ is called and the distance from the center is displayed in a data box. Note that this shape of the call block is used to retrieve the returned information from the procedure.