Пример #1
0
        void CheckSelections(MoverioTouchpadEventArgs mieArgs)
        {
            Collider target = GetFirstAffectedTarget();

            SelectionControllerEventArgs args = new SelectionControllerEventArgs(mieArgs);

            args.Device      = ControllerType.GyroMouse;
            args.IsConflict  = false;
            args.PointerPx   = GetScreenPoint();
            args.PointerPos  = EPSONcamera.transform.position;
            args.PointerQuat = EPSONcamera.transform.rotation;

            if (target != null)
            {
                target.SendMessage("Selected", args, SendMessageOptions.DontRequireReceiver);
            }
            else
            {
                SelectionEventArgs seArgs = new SelectionEventArgs(args);
                seArgs.Type = SelectionEventArgs.SelectionEventType.Selected;

                MessageBroker.BroadcastAll("OnSelected", seArgs);
            }
        }