Page tree
Skip to end of metadata
Go to start of metadata




Introduced in

Version:1.19

Description

Description:

Returns the pitch and bank of an object, in degrees. Yaw can be found using the getDir command.

Syntax

Syntax:object call fn_vbs_getPitchBank
Parameters:
  • object: Object - The given object.
Return Value:

Array - [pitch (Number), bank (Number)] - Has the following pitch and bank values:

  • Pitch:
    • 0 when the object is level.
    • 90 when pointing straight up.
    • -90 when pointing straight down.
  • Bank:
    • 0 when the the object is level.
    • 90 when the object is rolled to the right.
    • -90 when rolled to the left.
    • 180 when rolled upside down.

Warning

When using functions in VBS versions older than 3.4, certain limitations and requirements should be kept in mind - the main ones being that capitalization of the function name is crucial, and that #include "\vbs2\headers\function_library.hpp" has to be included in every script that utilizes it. More Category VBS Scripting Functions.

Examples

Examples:
_pitchbank = car call fn_vbs_getPitchBank;

Additional Information

See also: fn vbs setPitchBank
Multiplayer: 
Problems: 

Notes