Attention: Here be dragons
This is the latest
(unstable) version of this documentation, which may document features
not available in or compatible with released stable versions of Godot.
Checking the stable version of the documentation...
PackedInt32Array¶
A packed array of 32-bit integers.
Description¶
An array specifically designed to hold 32-bit integer values. Packs data tightly, so it saves memory for large array sizes.
Note: This type stores signed 32-bit integers, which means it can take values in the interval [-2^31, 2^31 - 1]
, i.e. [-2147483648, 2147483647]
. Exceeding those bounds will wrap around. In comparison, int uses signed 64-bit integers which can hold much larger values. If you need to pack 64-bit integers tightly, see PackedInt64Array.
Poznámka
There are notable differences when using this API with C#. See C# API differences to GDScript for more information.
Constructors¶
PackedInt32Array ( ) |
|
PackedInt32Array ( PackedInt32Array from ) |
|
PackedInt32Array ( Array from ) |
Methods¶
void |
append_array ( PackedInt32Array array ) |
void |
clear ( ) |
duplicate ( ) |
|
void |
|
is_empty ( ) const |
|
void |
|
void |
reverse ( ) |
void |
|
size ( ) const |
|
void |
sort ( ) |
to_byte_array ( ) const |
Operators¶
operator != ( PackedInt32Array right ) |
|
operator + ( PackedInt32Array right ) |
|
operator == ( PackedInt32Array right ) |
|
operator [] ( int index ) |
Constructor Descriptions¶
PackedInt32Array PackedInt32Array ( )
Constructs an empty PackedInt32Array.