C# Class FarseerPhysics.Factories.LinkFactory

显示文件 Open project: prime31/Nez

Public Methods

Method Description
CreateChain ( World world, Vector2 start, Vector2 end, float linkWidth, float linkHeight, int numberOfLinks, float linkDensity, bool attachRopeJoint, bool fixStart = false, bool fixEnd = false ) : List

Creates the chain.

Method Details

CreateChain() public static method

Creates the chain.
public static CreateChain ( World world, Vector2 start, Vector2 end, float linkWidth, float linkHeight, int numberOfLinks, float linkDensity, bool attachRopeJoint, bool fixStart = false, bool fixEnd = false ) : List
world FarseerPhysics.Dynamics.World World.
start Microsoft.Xna.Framework.Vector2 Start.
end Microsoft.Xna.Framework.Vector2 End.
linkWidth float Link width.
linkHeight float Link height.
numberOfLinks int Number of links.
linkDensity float Link density.
attachRopeJoint bool Creates a rope joint between start and end. This enforces the length of the rope. Said in another way: it makes the rope less bouncy.
fixStart bool If set to true fix start.
fixEnd bool If set to true fix end.
return List