LlGetListEntryType

From Second Life Wiki

(Redirected from LSL llGetListEntryType)
Jump to: navigation, search

Contents

Description

Function: integer llGetListEntryType( list src, integer index );
194 Function ID
0.0 Delay
10.0 Energy

Returns an integer that is the type of the entry index in src.

• list src List containing the element of interest.
• integer index Index of the element of interest.


index supports negative indexes.
If index describes a location not in src then TYPE_INVALID is returned.

Specification

Index Positive Negative
First 0 -length
Last length - 1 -1

Type Description
TYPE_INTEGER 1 integer
TYPE_FLOAT 2 float
TYPE_STRING 3 string
Type Description
TYPE_KEY 4 key
TYPE_VECTOR 5 vector
TYPE_ROTATION 6 rotation
Type Description
TYPE_INVALID 0 none

Caveats

If a vector is stored in a list as "<7,5,0>" (as opposed to <7,5,0>), its type will be returned as TYPE_STRING, not TYPE_VECTOR. The same applies for "1" being returned as a string instead of an integer, etc. There is no easy way to guess what the type could be from a string value.

Examples

See Also

Functions

•  llList2Float
•  llList2Integer
•  llList2Key
•  llList2Rot
•  llList2String
•  llList2Vector

Articles

•  Negative Index
Personal tools