Example #1
0
 protected override void AssignToDropZone()
 {
     base.AssignToDropZone();
     if (_currentDropZone != null)
     {
         DropZone_Outbox drawer = _currentDropZone.GetComponent <DropZone_Outbox>();
         if (drawer != null)
         {
             if (commandInOutbox != null)
             {
                 commandInOutbox();
             }
         }
     }
 }
Example #2
0
    private IEnumerator PlaceObjectInOutbox(MovableObject obj)
    {
        if (_outbox == null)
        {
            _outbox = FindObjectOfType <DropZone_Outbox>();

            if (_outbox == null)
            {
                yield return(null);
            }
        }
        obj.transform.position = _outbox.gameObject.transform.position;
        obj.Select(false);

        yield return(new WaitForFixedUpdate());

        obj.Deselect(false);

        if (newObjectInOutbox != null)
        {
            newObjectInOutbox();
        }
    }
Example #3
0
 private void AssignReferences()
 {
     _outbox         = FindObjectOfType <DropZone_Outbox>();
     _slidableDrawer = FindObjectOfType <SlidableDrawer>();
     _drawers        = FindObjectsOfType <DropZone_Drawer>();
 }