Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
1
Question by Woutor · Jun 02, 2010 at 09:28 AM · gameobjectparentchildpivot

change pivot of parent game object

I would like to change the pivot location of a GameObject. I have created a Prefab from several GameObjects and the pivot of the prefab is set to the origin of the scene. I would like to change the pivot point, how should I proceed?

What I would like is for the children objects to stay in the same place and be able to move the pivot of the parent object around.

Comment
Add comment · Show 3
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Peter G · Jun 02, 2010 at 11:37 AM 0
Share

Do you mean you want to move the pivot in local or world space? When you call translate or any position function, the object is moved at the pivot.

avatar image Woutor · Jun 02, 2010 at 12:57 PM 0
Share

I have a stack of wine glasses as GameObjects. These are ordered under a WineGlassStack parent. When the location of this WineGlassStack is set to (0,0,0) I want the lowest glass be placed on top of it, so I can easily put it on a table. I found out that you can select all childs and move them to the correct position in the stack space. The only problem is that you can only move them with the mouse which is not accurate. When I set the location in the Inspector it places the first selected item only.

avatar image cregox · Jun 06, 2012 at 08:08 PM 0
Share

related: http://answers.unity3d.com/questions/7664/changing-the-pivot-point-of-meshes.html

1 Reply

· Add your reply
  • Sort: 
avatar image
6
Best Answer

Answer by Mike 3 · Jun 02, 2010 at 01:08 PM

Move the parent (via the inspector) so that the children are in the right place the if the pivot was 0, 0, 0

Then, unparent the children, set the parent to 0,0,0, and reparent

Comment
Add comment · Show 4 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image cregox · Jun 06, 2012 at 07:59 PM 0
Share

I really don't get why this simply works! o_O

avatar image Jonesy19 · Feb 26, 2014 at 09:42 PM 0
Share

Thank you! Very simple solution to an annoying problem. :)

avatar image raarchaeon · Apr 20, 2014 at 06:05 AM 0
Share

Great solution! But finding the "right place" is kinda manual, so its not very accurate. Is there no other automated way?

avatar image cregox · Apr 21, 2014 at 07:15 PM 0
Share

@raarchaeon yes, check my comment on the question. There's a link.

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

3 People are following this question.

avatar image avatar image avatar image

Related Questions

Make a simple tree 1 Answer

how do I get reference to a parent or a child? 2 Answers

How to check parent value instead name value(more details in post) 3 Answers

How to set pivot point to the parent 1 Answer

Display Name Above Object 2 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges