You are here: Lua Scripting Resources eGuide > Lua Scripting API Reference Guide > Physics Library > world2Local

19.4.39 world2Local

lvec = physics.Body:world2Local(wvec)

Parameter

Type

Description

self

in physics.Body

The input Body

wvec

in physics.Vect

A vector in world coordinates

lvec

out physics.Vect

A vector relative to the position of the Body

Converts wvec from world coordinates to body-relative coordinates. Returns the converted vector.

Introduced in platform.apiLevel = '2.0'