This site has been archived and made available for preservation purposes. No edits can be made.

ValueToString

(Difference between revisions)
Return to current revision
  1.  
    Retrieves the string representation of an [wiki]Actor value[/wiki].
    [h="2"] Declaration [/h]
    [highlight=cpp]
  2. -
    VAULTSCRIPT vaultmp::String (*ValueToString)(vaultmp::Index);
  3. +
    VAULTSCRIPT VAULTSPACE cRawString (*VAULTAPI(ValueToString))(VAULTSPACE Index) _CPP(noexcept);
    [/highlight]
    [highlight=c]
  4.  
    native ValueToString(index, value{});
    [/highlight]
    [h="2"] Parameters [/h]
  5. -
    [b][wiki="Index"]vaultmp::Index[/wiki][/b] - the index of the [wiki]Actor value[/wiki]
  6. +
    [b][wiki="Index"]Index[/wiki][/b] - the index of the [wiki]Actor value[/wiki]
  7.  
    [b]value[/b] (PAWN only) - an array large enough to hold at least 64 characters
    [h="2"] Return value [/h]
  8. -
    The C++ version returns a [wiki="String"]vaultmp::String[/wiki] containing the string representation of the actor value. The PAWN version has no return value.
    [h="2"] Usage example (C++) [/h]
    [highlight=cpp]
    vaultmp::String value;
    value = ValueToString(index);
    [/highlight]
    [h="2"] Usage example (PAWN) [/h]
    [highlight=c]
    new value{64};
    ValueToString(index, value);
    [/highlight]
  9. +
    The C version returns a [wiki="cRawString"]cRawString[/wiki] containing the string representation of the actor value. The PAWN version has no return value.
  10.  
    [category]VaultMP interface[/category]
    [category]Scripting functions[/category]
    [category]Misc functions[/category]