distance

From Bohemia Interactive Community

Jump to: navigation, search
Editors, please check Policy: Scripting Command Page Syntax.
Introduced in Operation Flashpoint version 1.00Arguments of this scripting command don't have to be local to the client the command is executed on

Click on the images for descriptions

Introduced in

Game:
Operation Flashpoint
Version:
1.00

Description

Description:
Returns the distance in meters between two Objects or Positions.

Syntax

Syntax:
Number = ObjectOrPosition1 distance ObjectOrPosition2
Parameters:
ObjectOrPosition : Object or Position
Return Value:
Number - Distance in meters.

Examples

Example 1:
_meters=player distance _object
Example 2:
_meters=player distance [1,2,3]
Example 3:
_meters=[1,2,3] distance player

Additional Information

Multiplayer:
Behaviour unknown.

Notes

Notes

+ Add Note

Only post proven facts here. Use the talk page or the forums for discussions.

Notes

Posted on Feb 14, 2007 - 12:00
Sudden Death
distance to position3D (array) doesnt work with OFP, only objects

Armed Assault: position3D (array) and object works

Bottom Section

Personal tools
Buy ArmA now!