Current.loop

From AGI Wiki
Revision as of 17:18, 29 March 2019 by Andrew Korson (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search

The current.loop command stores the number of the current loop of an object in a variable.

Syntax

current.loop(obj oA, var vB);

Remarks

Variable vB is set to the current loop number for object oA.

Possible Errors

AGI does not check that object number oA is a valid object. If it is not, the returned value is meaningless.

Example

Code:

<syntaxhighlight lang="agi"> current.loop(o0, v51); [ v51 now holds ego's current loop </syntaxhighlight>

Technical Information

Required Interpreter Version: Available in all AGI versions.
Byte-Code Value: 51 (0x33 hex)

See Also

current.cel
current.view
last.cel
number.of.loops
set.loop
set.loop.v