This site has been archived and made available for preservation purposes. No edits can be made.
GetList
(Difference between revisions)
Return to current revision
-
-
Returns a [wiki="IDVector"]IDVector[/wiki] of all instances of a given [wiki="Type"]vaultmp::Type[/wiki].
-
+
Returns a vector of all instances of a given [wiki="Type"]Type[/wiki].
-
[h="2"] Declaration [/h]
[highlight=cpp]
-
-
VAULTSCRIPT vaultmp::IDVector (*GetList)(vaultmp::Type);
-
+
VAULTSCRIPT VAULTSPACE UCount (*VAULTAPI(GetList))(VAULTSPACE Type, VAULTSPACE RawArray(VAULTSPACE ID)*) VAULTCPP(noexcept);
[/highlight]
[highlight=cp]
-
native GetList(Type:type, id[]);
[/highlight]
[h="2"] Parameters [/h]
-
-
[b][wiki="Type"]vaultmp::Type[/wiki][/b] - the type
-
+
[b][wiki="Type"]Type[/wiki][/b] - the type
[b]Pointer to [wiki="RawArray"]RawArray[/wiki] of [wiki]ID[/wiki][/b] - used to return a pointer to the resulting vector
-
[b]id[/b] (PAWN only) - an array large enough to hold all instances. See [wiki]GetCount[/wiki]
[h="2"] Return value [/h]
-
-
The C++ version returns a [wiki="IDVector"]vaultmp::IDVector[/wiki]. The PAWN version returns the number of actually stored IDs.
-
+
Returns a [wiki="UCount"]UCount[/wiki], which is the number of instances in the vector.
-
[category]VaultMP interface[/category]
[category]Scripting functions[/category]
[category]Game functions[/category]