I was just curious as to why my program stopped working.
In the MDN doc, it says that “At this point, try reloading the code — it should work just the same as it did before, with our redesigned objects.” After I’ve redesigned the objects and added in the Shape class.
I haven’t done anything with the “Evil Circle” yet. The canvas is now black with no visible balls generating as before.
Forgot to add the “r” in “constructor” lol. That’s why the balls weren’t showing up!
Okay, Just finished the assessment! I added two players and TRIED to add a score counter BUT the number is coming out as “undefined” and Im not sure why. I’ve defined “this.score = 0” on both EvilCircle and EvilCircle2 and added the count in the loop in the bottom of the file.
To show both scores simultaneously you could add a second paragraph. Then you’ll give both a distinct class and use those as selectors for para and para2 in your JS. You’ll also need to use these classes in CSS to position one score above the other.
Another thing that could remove some duplication from the code would be to only have one EvilCircle class and put the differences into parameters (color, keys etc.)