Nebula Animation Problem

I thought I was following the video closely, but I appear to have goofed up somewhere as the nebulae don’t spin.

Here’s my code.

nebulaData[i].updateTime needs to be more than 0.0, i.e 1.0/12.0. I think this is missing lecture.

Yup, updateTime should be 1.0/12.0 for the nebula.

Technically, the nubla are animating. It’s just so fast that you can’t see it.

I found another bug, so they still aren’t animating despite that change. You forgot to initialize i to 0 in the for-loop that runs updateAnimData() for the nebulae.

So should be:

        for (int i = 0; i < nebulaSize; i++)
        {
            cout << "nebula:" << endl;
            nebulaData[i] = updateAnimData(nebulaData[i], dT, 7);
        }

Thanks! I must be going blind, I didn’t see those. :smiley:

Thanks!

This topic was automatically closed 20 days after the last reply. New replies are no longer allowed.

Privacy & Terms