Skip to content

Commit

Permalink
fixed a bug where gloop could penetrate the goal target
Browse files Browse the repository at this point in the history
  • Loading branch information
eternauta1337 committed May 15, 2012
1 parent c5d7077 commit 7dbfc21
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ package com.away3d.gloop.gameobjects {
_width = width;
_physics = new GoalWallPhysicsComponent(this, offsetX, offsetY, width, height);
_physics.enableReportBeginContact();
_physics.enableReportEndContact();
super(offsetX, offsetY, width, height, worldX, worldY);

initVisual();
Expand Down Expand Up @@ -64,8 +65,9 @@ package com.away3d.gloop.gameobjects {
_splatDistance = 1;
}

override public function onCollidingWithGloopStart( gloop:Gloop, event:ContactEvent = null ):void {
super.onCollidingWithGloopStart(gloop);
override public function onCollidingWithGloopEnd( gloop:Gloop, event:ContactEvent = null ):void {

super.onCollidingWithGloopEnd(gloop);

var gloopCenter:V2 = gloop.physics.b2body.GetWorldCenter();
var wallCenter:V2 = this.physics.b2body.GetWorldCenter();
Expand Down

0 comments on commit 7dbfc21

Please sign in to comment.