Skip to content

Barrier's done! #2

@eiddor

Description

@eiddor

Not an issue, but I did manage to figure out how to put in barriers based on the other concepts (2d array) that you explained in the tutorial. It took me a bit to wrap my head around why we have a bullet and enemy controller, but not a player controller, but I think I figured that out. I created a BarrierController.js and Barrier.js and went to work!

Next up are some player lives and a way to restart the game after a win or game over. Hopefully those are the easy parts!

Update: I've added Player lives and Player score and also "Press Any Key to Start" (or restart) logic. In order to do that I had to add reset() methods to my elements. Again I was only able to do that because of what I already learned from the tutorial. I even implemented requestAnimationFrame instead of setInterval because I saw that suggested in a Reddit post.

So, thank you again for a great tutorial! I learned a ton.

space_more

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions