This forum is read only and just serves as an archive. If you have any questions, please post them on

1 decade ago by harryfeng

check the game. so each floor is a collision so entities can walk on it.

but I want to make the plant fall off the building after the player hit it.

how do I make it happen?

1 decade ago by harryfeng

oh, press space to skip the entro screen.

1 decade ago by ArcadeHype

Box2D physics would be your best bet.

1 decade ago by StuartTresadern

If you just want the plants to drop through the floors when the Player hits them, override the update on your plant entity when the Player hits the plant.In effect stopping the trace against the collision map. Not sure Box2D would be any better as you would still Need the same sort of logic !.

Setup a property

override update

                if(this.hit==true) {
                    this.pos.x += this.vel.x * ig.system.tick;
                    this.pos.y += this.vel.y * ig.system.tick;
                else {
                    this.parent( );


and Change the state of hit in the plants check

                if (other instanceof EntityPlayer){


Page 1 of 1
« first « previous next › last »