Skip to content

Fixed Goomba and player collision and also added a bounce #124

@GavinCopley

Description

@GavinCopley

Fixed Goomba and player collision and added a bounce when Mario touches the top of the goomba

Files Changed Fixed Goomba Collision With Mario Added Bounce When Mario Lands on Goomba
GameEnv.js - Added variable "invincible"
- Added variable "goombaInvincible"
- Added variable 'goombaBounce'
Player.js - Remade collision detection with goomba
- Now uses goombaCollision function when referencing Mario death
- Has function that subtracts 125 from
y when variable is true
Goomba.js - Makes Mario invincible after goomba dies to allow time for
animation to play
- When Goomba is stepped on, changes
variable to true
Other - Commented out many 'console.log's in various files
- Added Goomba changes to FlyingGoomba.js

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions