Difference between revisions of "love.physics.newRevoluteJoint"
m |
(Moved 0.8.0 variant to the top.) |
||
Line 1: | Line 1: | ||
− | + | Creates a pivot joint between two bodies. | |
This joint connects two bodies to a point around which they can pivot. | This joint connects two bodies to a point around which they can pivot. | ||
== Function == | == Function == | ||
+ | {{newin|[[0.8.0]]|type=variant}} | ||
=== Synopsis === | === Synopsis === | ||
<source lang="lua"> | <source lang="lua"> | ||
− | joint = love.physics.newRevoluteJoint( body1, body2, x, y ) | + | joint = love.physics.newRevoluteJoint( body1, body2, x, y, collideConnected ) |
</source> | </source> | ||
=== Arguments === | === Arguments === | ||
− | {{param|Body|body1|The first body | + | {{param|Body|body1|The first body.}} |
− | {{param|Body|body2|The second body | + | {{param|Body|body2|The second body.}} |
{{param|number|x|The x position of the connecting point.}} | {{param|number|x|The x position of the connecting point.}} | ||
{{param|number|y|The y position of the connecting point.}} | {{param|number|y|The y position of the connecting point.}} | ||
+ | {{param|boolean|collideConnected (false)|Specifies whether the two bodies should collide with each other.}} | ||
=== Returns === | === Returns === | ||
{{param|Joint|joint|The new revolute joint.}} | {{param|Joint|joint|The new revolute joint.}} | ||
+ | |||
== Function == | == Function == | ||
− | {{ | + | {{oldin|[[0.8.0]]|type=variant}} |
=== Synopsis === | === Synopsis === | ||
<source lang="lua"> | <source lang="lua"> | ||
− | joint = love.physics.newRevoluteJoint( body1, body2, x, y | + | joint = love.physics.newRevoluteJoint( body1, body2, x, y ) |
</source> | </source> | ||
=== Arguments === | === Arguments === | ||
Line 26: | Line 29: | ||
{{param|number|x|The x position of the connecting point.}} | {{param|number|x|The x position of the connecting point.}} | ||
{{param|number|y|The y position of the connecting point.}} | {{param|number|y|The y position of the connecting point.}} | ||
− | |||
=== Returns === | === Returns === | ||
{{param|Joint|joint|The new revolute joint.}} | {{param|Joint|joint|The new revolute joint.}} | ||
Line 34: | Line 36: | ||
* [[Constructs::RevoluteJoint]] | * [[Constructs::RevoluteJoint]] | ||
[[Category:Functions]] | [[Category:Functions]] | ||
− | {{#set:Description= | + | {{#set:Description=Creates a pivot joint between two bodies.}} |
{{#set:Since=000}} | {{#set:Since=000}} | ||
== Other Languages == | == Other Languages == | ||
{{i18n|love.physics.newRevoluteJoint}} | {{i18n|love.physics.newRevoluteJoint}} |
Revision as of 22:23, 9 April 2012
Creates a pivot joint between two bodies.
This joint connects two bodies to a point around which they can pivot.
Contents
Function
Available since LÖVE 0.8.0 |
This variant is not supported in earlier versions. |
Synopsis
joint = love.physics.newRevoluteJoint( body1, body2, x, y, collideConnected )
Arguments
Body body1
- The first body.
Body body2
- The second body.
number x
- The x position of the connecting point.
number y
- The y position of the connecting point.
boolean collideConnected (false)
- Specifies whether the two bodies should collide with each other.
Returns
Joint joint
- The new revolute joint.
Function
Removed in LÖVE 0.8.0 |
This variant is not supported in that and later versions. |
Synopsis
joint = love.physics.newRevoluteJoint( body1, body2, x, y )
Arguments
Body body1
- The first body to connect with a Revolute Joint.
Body body2
- The second body to connect with a Revolute Joint.
number x
- The x position of the connecting point.
number y
- The y position of the connecting point.
Returns
Joint joint
- The new revolute joint.
See Also
Other Languages
Dansk –
Deutsch –
English –
Español –
Français –
Indonesia –
Italiano –
Lietuviškai –
Magyar –
Nederlands –
Polski –
Português –
Română –
Slovenský –
Suomi –
Svenska –
Türkçe –
Česky –
Ελληνικά –
Български –
Русский –
Српски –
Українська –
עברית –
ไทย –
日本語 –
正體中文 –
简体中文 –
Tiếng Việt –
한국어
More info