Difference between revisions of "PolygonShape"

Line 1: Line 1:
 
Polygon is a convex polygon with up to 8 sides.
 
Polygon is a convex polygon with up to 8 sides.
 
+
== Constructors ==
Create a new polygon shape with [[love.physics.newPolygonShape]] or [[love.physics.newRectangleShape]].
+
{{#ask: [[Category:Functions]] [[Constructs::PolygonShape]] [[Since::<071]]
 
 
== Functions ==
 
{{#ask: [[Category:Functions]] [[parent::PolygonShape]]
 
 
| headers=hide
 
| headers=hide
 +
| default=None.
 
| ?Description
 
| ?Description
 
}}
 
}}
{{#ask: [[Category:Functions]] [[parent:Shape]]
+
== Functions ==
| headers=hide
+
{{#ask: [[Category:Functions]] [[parent::PolygonShape||Shape||Object]] [[Since::<071]]
| ?Descrition
 
}}
 
{{#ask: [[Category:Functions]] [[parent::Object]]
 
 
| headers=hide
 
| headers=hide
 
| ?Description
 
| ?Description
Line 21: Line 16:
 
== See Also ==
 
== See Also ==
 
* [[parent::love.physics]]
 
* [[parent::love.physics]]
* [[love.physics.newPolygonShape]]
 
* [[love.physics.newRectangleShape]]
 
 
[[Category:Types]]
 
[[Category:Types]]
{{#set:Description=Polygon is a convex polygon with up to 8 sides.
+
{{#set:Description=Polygon is a convex polygon with up to 8 sides.}}
}}
+
{{#set:Since=000}}
 
== Other Languages ==
 
== Other Languages ==
 
{{i18n|PolygonShape}}
 
{{i18n|PolygonShape}}

Revision as of 17:45, 25 March 2011

Polygon is a convex polygon with up to 8 sides.

Constructors

love.physics.newPolygonShapeCreates a new PolygonShape.
love.physics.newRectangleShapeShorthand for creating rectangular PolygonShapes.

Functions

Object:typeGets the type of the object as a string.
Object:typeOfChecks whether an object is of a certain type.
PolygonShape:getPointsGet the local coordinates of the polygon's vertices.
Shape:destroyExplicitly destroys the Shape.
Shape:getBodyGet the body the shape is attached to.
Shape:getBoundingBoxGets the bounding box of the shape.
Shape:getCategoryGets the categories this shape is a member of.
Shape:getCategoryBitsGets the categories as a 16-bit integer.
Shape:getDataGet the data set with setData.
Shape:getDensityGets the density of the Shape.
Shape:getFilterDataGets the filter data of the Shape.
Shape:getFrictionGets the friction of this shape.
Shape:getMaskGets which categories this shape should NOT collide with.
Shape:getRadiusGets the radius of the shape.
Shape:getRestitutionGets the restitution of this shape.
Shape:getTypeGets a string representing the Shape.
Shape:isSensorChecks whether a Shape is a sensor or not.
Shape:setCategorySets the categories this shape is a member of.
Shape:setDataSet data to be passed to the collision callback.
Shape:setDensitySets the density of a Shape.
Shape:setFilterDataSets the filter data for a Shape.
Shape:setFrictionSets the friction of the shape.
Shape:setMaskSets which categories this shape should NOT collide with.
Shape:setRestitutionSets the restitution of the shape.
Shape:setSensorSets whether this shape should act as a sensor.
Shape:testPointChecks whether a point lies inside the shape.
Shape:testSegmentChecks whether a line segment intersects a shape.

Supertypes

Shape Object

See Also


Other Languages