An Issue I had with the Prefabs, and my Solution to it

Hello classmates!

I just spent 15 minutes trying to solve an issue with making a prefab as was done in the video, then as I went step by step with the process while I typed up my issue so someone could see what was wrong, I found my issue. I figure other people may have this issue, so without any further ado, here we go.

After I copied my paddle and went to make my one hit brick, all hell seemed to break loose. I was getting an extra “1 hit” in my hierarchy, and then the issue really because a problem because I noticed that when I changed the color of my new prefab, that my paddle also changed color!

I couldn’t be having a paddle the same color as my bricks! I did the steps over and over and over again trying to get it straight.

What turned out to be the problem was something so simple. When you duplicate paddle (or any entity I suppose) in the hierarchy, it created a copy of it, DIRECTLY ON TOP OF the original. You can then drag that around the scene and place it where you need it. Once I realized that this duplication was actually placing a copy in the scene for me, I was simply able to delete the scripting there, and then change the color, with it only applying to the prefab.

I guess the long story short, is if your paddle is changing color when you change the prefab color, check and make sure you don’t have elements stacked on each other in the scene. I felt like such a noob making this mistake, but I guess it is a sign of progress that I was able to get it fixed after a little bit.

Loving the course and can’t wait to keep going!

-Tyler

Privacy & Terms