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

GetAngle

(Difference between revisions)
Return to current revision
Current Revision 04-26-2012, 09:45 PM
  1. -
    Retrieves the last known angle (X, Y, Z coordinates) of an [[Object]].

    == Declaration ==
    <code cpp>
    VAULTSCRIPT void (*GetAngle)(vaultmp::ID, vaultmp::Value&, vaultmp::Value&, vaultmp::Value&);
  2. +
    Retrieves the current angle (X, Y, Z coordinates) of an [wiki]Object[/wiki].
    [h="2"] Declaration [/h]
    [highlight=cpp]
    VAULTSCRIPT vaultmp::Void (*GetAngle)(vaultmp::ID, vaultmp::Value&, vaultmp::Value&, vaultmp::Value&);
  3.  
    native GetAngle(ID, &Float:X, &Float:Y, &Float:Z);
  4. -
    </code>
    == Parameters ==

    '''[[vaultmp::ID]]''' - the ID of the Object

    '''[[vaultmp::Value]]&''' - a reference to a Value (X coordinate)

    '''[[vaultmp::Value]]&''' - a reference to a Value (Y coordinate)

    '''[[vaultmp::Value]]&''' - a reference to a Value (Z coordinate)

    == Return value ==

  5. +
    [/highlight]
    [h="2"] Parameters [/h]
    [b][wiki="ID"]vaultmp::ID[/wiki][/b] - the ID of the [wiki]Object[/wiki]
    [b][wiki="Value"]vaultmp::Value[/wiki]&[/b] - a reference to a [wiki]Value[/wiki] (X coordinate)
    [b][wiki="Value"]vaultmp::Value[/wiki]&[/b] - a reference to a [wiki]Value[/wiki] (Y coordinate)
    [b][wiki="Value"]vaultmp::Value[/wiki]&[/b] - a reference to a [wiki]Value[/wiki] (Z coordinate)
    [h="2"] Return value [/h]
  6.  
    None.
  7. -

    == Usage example (C++) ==

    <code cpp>
  8. +
    [h="2"] Usage example (C++) [/h]
    [highlight=cpp]
  9.  
    vaultmp::Value X, Y, Z;
    GetAngle(object, X, Y, Z);
  10. -
    </code>
  11. +
    [/highlight]
    [category]VaultMP interface[/category]
    [category]Scripting functions[/category]
    [category]Object functions[/category]