[Solved] Problem with Prefabs

So, I’m a little embarrassed, but I made a rather stupid mistake while playing around with the enemy prefabs and deleted my prefab.

This understandable provided an exception when I ran the game as the variable (in this case Enemy Prefab) was not assigned. The problem is that even though I reassigned the new prefab the error still occurs and so I can no longer spawn enemies.

I hope the description makes sense and thanks in advance.

~Thom

Hi @MooseLucky,

Could you pop a screenshot up of Unity with the error visible please.

Hi @Rob,

Thanks for commenting, but I managed to fix the issue. It was a slightly different bug (one in my code!) that was causing the issue.

The lesson here is to always test when you’ve added new code!!!

Apologies!

~Thom

1 Like

You are more than welcome, and I’m glad to hear you have it sorted now Thom :slight_smile: