My enemy sits in the first waypoint and doesn’t move. The code is correct and the speed was set to 2f?
Make sure the enemy prefab and the waypoint both share space on the Z-Axis. I had the same problem because I forgot to reset transform on my prefabs. Took forever to figure it out.
Brilliant that was the smartest solution for the stupid mistake. It did work beautifully. Thanks for the fast answer. If u were close to woodbridge I would invite you to a cup of capuccino or whatever u like:blush:
This helped. I had the same problem. Thank you.
Thanks Steven I didn’t know anyone can have the same problem. Have a nice day:wink:
To All attendants of this course, if anyone lives in Suffolk England and likes to meet to and help each other please let me know
I spent quite some time on this lol. This thread saved me. Have a great day as well.
Still having the same problem. Code is dead on, with what’s shown in the course, waypoints are prefabbed and hooked up correctly, everything’s correct on the Z-Axis and the enemy ship still just teleported to the first waypoint and sits there. What am I missing?
For anyone who is also having the same problem I figured it out. When I set up my game I didn’t have the enemies/player moving on 0 for the Z axis, they are on -2. When using the code from the lesson, using Vector2 resets the enemy to 0 on the Z axis and stops the waypoints from working properly. If you simply change it to Vector3 instead of Vector2 it will also grab the Z axis value from the waypoint and it will work properly. Hopefully this helps someone.
OH GOD DAMNIT YOU ARE A LIFE SAVER! Thank you John I was ripping my hair out over this!