예제 #1
0
        protected override void Awake()
        {
            position = GetComponent <Position>();
            if (position == null)
            {
                position = gameObject.AddComponent <Position>();
            }

            base.Awake();

            PositionRegistry.RegisterInstance(position);
        }
예제 #2
0
 protected void Awake()
 {
     PositionRegistry.RegisterInstance(this);
 }