|
|
@ -131,12 +131,10 @@ class ChromeDino extends BodyComponent
|
|
|
|
@override
|
|
|
|
@override
|
|
|
|
Body createBody() {
|
|
|
|
Body createBody() {
|
|
|
|
final bodyDef = BodyDef(
|
|
|
|
final bodyDef = BodyDef(
|
|
|
|
userData: this,
|
|
|
|
|
|
|
|
position: initialPosition,
|
|
|
|
position: initialPosition,
|
|
|
|
type: BodyType.dynamic,
|
|
|
|
type: BodyType.dynamic,
|
|
|
|
gravityScale: Vector2.zero(),
|
|
|
|
gravityScale: Vector2.zero(),
|
|
|
|
);
|
|
|
|
);
|
|
|
|
|
|
|
|
|
|
|
|
final body = world.createBody(bodyDef);
|
|
|
|
final body = world.createBody(bodyDef);
|
|
|
|
_createFixtureDefs().forEach(body.createFixture);
|
|
|
|
_createFixtureDefs().forEach(body.createFixture);
|
|
|
|
|
|
|
|
|
|
|
|