全ての形状は凸形状としてセットされます [詳細]
Public メソッド | |
| PhysicsShape () | |
| デフォルトコンストラクタ | |
| PhysicsShape (float radius) | |
| 球生成 | |
| PhysicsShape (Vector2 width) | |
| ボックス生成 | |
| PhysicsShape (Vector2[] pos, int num) | |
| 凸形状生成 | |
| PhysicsShape (Vector2[] pos, int num, bool flag) | |
| 接続したライン形状生成 | |
| PhysicsShape (PhysicsShape con) | |
| コピー形状生成 | |
Static Public メソッド | |
| static PhysicsShape | CreateConvexHull (Vector2[] vertList, int num) |
| ランダム頂点から凸包を生成します | |
Public 変数 | |
| int | numVert |
| 頂点数 | |
| Vector2[] | vertList = new Vector2[30] |
| 頂点リスト | |
| uint | hint |
| PhysicsShapeに対するヒント | |
プロパティ | |
| int | NumVert [get, set] |
| setter and getter of numVert | |
| Vector2[] | VertList [get, set] |
| setter and getter of vertList | |
| uint | Hint [get, set] |
| setter and getter of hint | |
全ての形状は凸形状としてセットされます
| PhysicsShape | ( | float | radius | ) |
球生成
| radius | 球の半径 |
| PhysicsShape | ( | Vector2 | width | ) |
ボックス生成
| width | ボックスの半分の縦横長さ |
縦横長さではなく、縦横半分の長さである
| PhysicsShape | ( | Vector2[] | pos, |
| int | num | ||
| ) |
凸形状生成
| pos | 凸形状の頂点リスト |
| num | 頂点リストの数 |
頂点リストの数の最大は30個
| PhysicsShape | ( | Vector2[] | pos, |
| int | num, | ||
| bool | flag | ||
| ) |
接続したライン形状生成
| pos | ライン形状の頂点リスト |
| num | 頂点リストの数 |
| flag | trueを常に与える |
頂点リストの数の最大は30個であり、また、これによって作れるのは静的剛体のみです
| PhysicsShape | ( | PhysicsShape | con | ) |
コピー形状生成
| con | 剛体の形状 |
| static PhysicsShape CreateConvexHull | ( | Vector2[] | vertList, |
| int | num | ||
| ) | [static] |
ランダム頂点から凸包を生成します
| vertList | ランダムな頂点列 |
| num | 頂点数 |
| uint hint |
PhysicsShapeに対するヒント
PhysicsShapeの対称性を判定している hint=1は形状が対称性を有していないケースで, hint=2は形状が対称性を有している, 任意に凸形状を指定した場合、球とボックスの場合を除いて、シミュレーション速度を上げるため、 適切にこの変数を指定することが望ましい