I have an airplane model that I want to attach a missile to. In the hierarchy, I have an airplane object with the motion script attached, and children to this are:
* the airplane model hierarchy
* a collider hierarchy
* a weapons system empty
I dragged the missile prefab to the weapons system empty: this works when dragging the airplane around in the editor. But when the game is played, the missile just drops to the ground with its own gravity, separate from the airplane. What is wrong? Can this object not have a rigidbody?
I tried:
* adding a joint
* deactivating my missile script
* using a standard game object instead of a prefab
However, the missile still wants to use its own coordinates instead of remaining attached to the airplane. I plan to detach the missile later when it must be shot.
![Airplane with prefab attached][1]![Airplane with prefab missile bouncing off][2]
[1]: /storage/temp/117394-unity-2018-05-22-07-57-23.jpg
[2]: /storage/temp/117396-unity-2018-05-22-07-57-39.jpg
↧