Difference between revisions of "FindInArray"

From the Oblivion ConstructionSet Wiki
Jump to navigation Jump to search
imported>Haama
(Fixed syntax - takes a long)
imported>Speedo
(Remove beta tag)
Line 1: Line 1:
__NOTOC__
__NOTOC__


{{Beta}}
A command for [[:Category:Pluggy|Pluggy]]
A command for [[:Category:Pluggy|Pluggy]]


Line 12: Line 11:
*Start is optional. By default it is 0
*Start is optional. By default it is 0
**Stop is optional. By default it is the last index of the array
**Stop is optional. By default it is the last index of the array
*If the value is not in the array or the array does not exists, it returns -1.
*If the value is not in the array or the array does not exist, it returns -1.


[[Category: Pluggy]]
[[Category: Pluggy]]

Revision as of 14:58, 18 February 2008


A command for Pluggy

Syntax:

(Index:long) FindInArray ArrayID:long Value:long Start:long Stop:long

Returns the index of the first occurrence of Value between indexes Start & Stop in the array.

  • This can only be used to find integers (short and long).
  • Start is optional. By default it is 0
    • Stop is optional. By default it is the last index of the array
  • If the value is not in the array or the array does not exist, it returns -1.