Search Unity

Detecting transform changes made within the editor

Discussion in 'Scripting' started by ivincent, Mar 26, 2012.

  1. ivincent

    ivincent

    Joined:
    Jan 16, 2012
    Posts:
    16
    I'm sure this has been asked before, but is there any way to update a game objects position in script if the game object transform has been changed in the Editor. I want to modify a game object while the game is running using the inspector but the game object still believes it's position is the original position before the change was made.
     
    probitaille likes this.
  2. probitaille

    probitaille

    Joined:
    May 5, 2015
    Posts:
    34
    I want to do the same thing.

    Is there a solution?
     
  3. Yash987654321

    Yash987654321

    Joined:
    Oct 22, 2014
    Posts:
    729
    You can save the position in floats at start and load it in awake now compare both of them. If they are not same means the position of the object has been edited!