Skip to content

Commit

Permalink
fixed typo
Browse files Browse the repository at this point in the history
  • Loading branch information
asalga committed Oct 23, 2014
1 parent 8ced69f commit 707c306
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 8 deletions.
3 changes: 1 addition & 2 deletions BoundingBoxYComponent.pde
Expand Up @@ -70,11 +70,10 @@ class BoundingBoxYComponent extends BoundingBoxComponent {

// LANDING but only if player was actually in the air
if (gameObject.position.y > other.position.y && phy.isTouchingFloor() == false ) {

phy.landed();

phy.setGroundY(other.position.y);
phy.setTouhcingFloor(true);
phy.setTouchingFloor(true);

mario._isJumping = false;
}
Expand Down
4 changes: 2 additions & 2 deletions CreatureBoundingBoxComponent.pde
Expand Up @@ -26,7 +26,7 @@ class CreatureBoundingBoxComponent extends BoundingBoxComponent {
// if we are no longer colliding with anything, then fall
if (colliders.isEmpty()) {
phy.setGroundY(TILE_SIZE);
phy.setTouhcingFloor(false);
phy.setTouchingFloor(false);
}
}

Expand All @@ -42,7 +42,7 @@ class CreatureBoundingBoxComponent extends BoundingBoxComponent {
//
if (other.position.y + TILE_SIZE >= gameObject.position.y && phy.isTouchingFloor() == false ) {
phy.setGroundY(other.position.y);
phy.setTouhcingFloor(true);
phy.setTouchingFloor(true);
}

// If hit side of something, reversedirection
Expand Down
5 changes: 3 additions & 2 deletions MarioControllerComponent.pde
Expand Up @@ -111,7 +111,7 @@ class MarioControllerComponent extends Component {
if (canJump() && _isJumping == false) {
dprintln("jump()");

physics.setTouhcingFloor(false);
physics.setTouchingFloor(false);
physics.applyForce(0, jumpForce);
soundManager.playSound("jump");
animation.play("jump");
Expand Down Expand Up @@ -164,14 +164,15 @@ class MarioControllerComponent extends Component {
dprintln("fall()");

phy.setGroundY(TILE_SIZE);
phy.setTouhcingFloor(false);
phy.setTouchingFloor(false);
phy.velocity.y = 0;
animation.play("jump");
}

void hitStructureY(GameObject structure){
// LANDED ON TOP
if(gameObject.position.y > structure.position.y){
dprintln("Landed on top");
_isJumping = false;
}
// PUNCHED
Expand Down
2 changes: 1 addition & 1 deletion PhysicsComponent.pde
Expand Up @@ -59,7 +59,7 @@ class PhysicsComponent extends Component {
return _isTouchingFloor;
}

void setTouhcingFloor(boolean b) {
void setTouchingFloor(boolean b) {
_isTouchingFloor = b;
}

Expand Down
2 changes: 1 addition & 1 deletion SpriteControllerComponent.pde
Expand Up @@ -63,7 +63,7 @@ class SpriteControllerComponent extends Component {
physics.setGroundY(-600);
//physics.setGravity(0, -150);
physics.applyForce(0, 10);
physics.setTouhcingFloor(false);
physics.setTouchingFloor(false);
// disconnect?

// 1) invalidate object?
Expand Down

0 comments on commit 707c306

Please sign in to comment.