made fast objects bullets, fixes #126

This commit is contained in:
Jeena 2015-04-02 21:27:13 +02:00
parent f9d97c5a47
commit 46f14c22c6
2 changed files with 4 additions and 1 deletions

View file

@ -265,7 +265,7 @@ function () {
"category": "kitchen", "category": "kitchen",
"image": "banana.gif", "image": "banana.gif",
"weight": "1", "weight": "3",
"width": "5", "width": "5",
"height": "9", "height": "9",

View file

@ -37,6 +37,9 @@ function (Parent, Box2D, Options, Settings, Exception, Nc, Assert) {
this.createFixture(); this.createFixture();
this.body.ResetMassData(); this.body.ResetMassData();
this.flipDirection = 1; this.flipDirection = 1;
if (this.body.GetMass() < 1) {
this.body.SetBullet(true);
}
Nc.trigger(Nc.ns.core.game.gameObject.add, "animated", this); Nc.trigger(Nc.ns.core.game.gameObject.add, "animated", this);
} }