Difference between revisions of "Assignv"

From AGI Wiki
Jump to navigationJump to search
Line 9: Line 9:
 
==Parameters==
 
==Parameters==
  
    <code>variableA:</code> a variable, <code>v0-v255</code>, which should receive the value of <code>variableB</code>
+
* <code>variableA:</code> a variable, <code>v0-v255</code>, which should receive the value of <code>variableB</code>
    <code>variableB:</code> a variable, <code>v0-v255</code>, whose value should be assigned to <code>variableA</code>
+
* <code>variableB:</code> a variable, <code>v0-v255</code>, whose value should be assigned to <code>variableA</code>
  
 
==Possible errors==
 
==Possible errors==

Revision as of 14:35, 2 August 2013

The assignv command sets the value of a variable to the value of another variable.

assignv(variableA, variableB);

variableA = variableB;

When this command is issued, the value of variableA is set to the value of variableB.

Parameters

  • variableA: a variable, v0-v255, which should receive the value of variableB
  • variableB: a variable, v0-v255, whose value should be assigned to variableA

Possible errors

None known.

Examples

The following example assigns the value of variable v30 to variable v200, using the longhand syntax:

assignv(v200, v30);

The next example assigns the value of variable v98 to variable v207, using the shorthand syntax:

v207 = v98;

See also

Sources