Beispiel #1
0
 void Update()
 {
     if (transform.hasChanged && transform.position != _previousPosition)
     {
         foreach (GPUInstancerManager manager in gPUIManagers)
         {
             if (manager != null)
             {
                 GPUInstancerAPI.SetGlobalPositionOffset(manager, transform.position - _previousPosition);
             }
         }
         _previousPosition    = transform.position;
         transform.hasChanged = false;
     }
 }