"Sputnik" help  
Sputnik Help
NbtCompoundGetValues(<nbtCompound>)

Description

Returns an array containing all the values from an NBT compound, where each value is converted to the appropriate Sputnik variable type based on the NBT tag's type.

Parameters

<nbtCompound> The NBT compound from which to retrieve the values.

Return Value

Success: Returns an array containing all the values from the NBT compound, converted to the appropriate Sputnik variable types.
Failure: Returns null if the provided nbtCompound parameter is not a valid NBT compound.

Remarks

The NbtCompoundGetValues function allows you to retrieve an array containing all the values from an NBT compound. It verifies that the nbtCompound parameter is a valid NBT compound and converts each value to the appropriate Sputnik variable type based on the NBT tag's type.

Related

Example

Example of usage:

my $nbt = NbtNew(@NbtCompound);
NbtCompoundSet($nbt, "Cat", "Meow");
NbtCompoundSet($nbt, "Dog", "Woof");
printr NbtCompoundGetValues($nbt);

// PRINTS
// Array
// (
//     [0] => Meow
//     [1] => Woof
// )

 


Contact
Cheryl (uberfox@hotmail.com)
Homepage
http://ubersoft.org