FANDOM


Supported In:
C D/S/W W-CD
? ? ?

The scripting command GotoRandom has the opcode (0x38).

Arguments

  • n (byte) - the number of supplied line numbers
  • Array of bytes (byte * n) - each a one byte line number


Description

This operation randomly jumps to one of any number of predefined line numbers in the current event. It is essentially a 'goto' operation which transfers execution a randomly-selected line from the array of supplied line numbers.

For example, if the supplied arguments were "03 05 09 1A", the first byte indicates that there are three possible jump locations and that the jump locations are lines 5, 9, and 28 (0x1A).

Notes

The theoretical maximum number of potential line numbers that could be supplied is approximately 250, however this is not an issue as the maximum number of lines that make up an event is limited to 255, due to the way the event data is stored.

Ad blocker interference detected!


Wikia is a free-to-use site that makes money from advertising. We have a modified experience for viewers using ad blockers

Wikia is not accessible if you’ve made further modifications. Remove the custom ad blocker rule(s) and the page will load as expected.