11. Change the bubble shape


#1

There is an error in the lesson. You should create a var named bubbleShape and set it to square. The description says, after that the shape of the bubbles will change to squares. But they don't. If you want the shape changed, you need to supply this new var to the function. If you do so, the lesson fails. Instructions unclear.


#2

hahaha in the following lesson it's not needed to include bubbleshape in the function. It works anyways...


#3

This is true. If you view the bubbles.js code and look for the drawName function, you will see that it is only expecting your name and your letter colors:

function drawName(name, letterColors) {

It is not expecting you to send it your bubbleShape as well.


#4

well, but the preview doesn't show squareshaped bubbles until you transport it into the function.


#5

As long as you have a line like this:

bubbleShape = "square";

then you should see square bubbles.

bubbleShape is used by the PointCollection, Point, draw and shake functions but not by the drawName function.