Changing rotation of prefab
Hey I have a player and I want to shoot bullets. But my problem is that the bullet does not have the correct rotation and it's pointing always upwards to y direction. I'm instantiating the bullet with this:
BulletController newBullet = Instantiate(bullet, firePoint.position, firePoint.rotation) as BulletController;
newBullet.speed = bulletSpeed;
The firePoint is my spawnpoint for my bullet. And everytime if I change the rotation of the firePoint or the bullet manually from the inspector, the bullet is moving to the wrong direction. So I want just change the rotation not the direction. I don't know why it's so complicated.
EDIT: I have already tried it with the empty gameobject, like it's discribed here but didn't work https://forum.unity.com/threads/prefab-rotation-after-instantiating.452647/
Your answer
Follow this Question
Related Questions
How to make an object shoot a projectile? 4 Answers
Projectile disappears instantly after appearing. 1 Answer
Instantiating prefabs, and making them move. (Projectiles) 0 Answers
instantiate a prefab not working 0 Answers
Instantiating A Prefab on my Character Troubles,Instantiating a Prefab 2 Answers