Search Unity

Question Setting position relative to another object in a different gameobject

Discussion in 'Editor & General Support' started by lz7cjc, Nov 23, 2021.

  1. lz7cjc

    lz7cjc

    Joined:
    Sep 10, 2019
    Posts:
    535
    Hi
    I am trying to match up my camera/player to a hospital that i bought. The player is at the top level of the hierarchy and the hospital is in its own folder.

    I also need to move the hospital to a position within another bought asset; meadows.

    So I added a cube to act as a marker but because it sits at a different level of the hierarchy the relative positions of parent objects means I can't do this

    What is the best way to position groups of assets and objects?

    thanks
     
  2. Kurt-Dekker

    Kurt-Dekker

    Joined:
    Mar 16, 2013
    Posts:
    38,674
    I'm not sure I follow the above. Why can't you just move the hospital where you want on the other asset and save the scene? That's the usual workflow in Unity.
     
  3. lz7cjc

    lz7cjc

    Joined:
    Sep 10, 2019
    Posts:
    535
    yes i think you have got it despite the confused post - not sure how to describe it
    the size and intricacies of both sets of assets in the editor makes this impossible as I end up either getting a grey screen or else am looking at walls. I also have something weird going on when I focus on some of my assets; it doesn't take me to the object but to a place far removed from where it sits
    What I would like to do is find a suitable place in the meadow for my hospital then move where my player sits (Which is at the same level as the meadow and the hospital in the hierarchy, to this spot. I can select both the player and hospital and I then want these both centred around my spot in the meadow.

    Hope that makes sense as it is doing my head in!
    thanks

    (I have followed some tutorials on placing objects but none cover this particular problem)