private void touchEndedHandler(object sender, MetaGestureEventArgs metaGestureEventArgs)
 {
     int id;
     var touch = metaGestureEventArgs.Touch;
     if (touch.InputSource == this) return;
     if (!map.TryGetValue(touch.Id, out id)) return;
     endTouch(id);
 }
 private void touchMovedhandler(object sender, MetaGestureEventArgs metaGestureEventArgs)
 {
     int id;
     TouchHit hit;
     var touch = metaGestureEventArgs.Touch;
     if (touch.InputSource == this) return;
     if (!map.TryGetValue(touch.Id, out id)) return;
     if (!gesture.GetTargetHitResult(touch.Position, out hit)) return;
     moveTouch(id, processCoords(hit.RaycastHit.textureCoord));
 }
Esempio n. 3
0
 private void touchEndedHandler(object sender, MetaGestureEventArgs metaGestureEventArgs)
 {
     if (Time.time - TouchTime < 300)
     {
         this.ExitContactZone();
     }
     TouchTime = 0;
 }
Esempio n. 4
0
 private void touchBeganHandler(object sender, MetaGestureEventArgs metaGestureEventArgs)
 {
     if (TouchTime == 0)
     {
         TouchTime = Time.time;
         this.EnterContactZone();
     }
 }
 private void touchBeganHandler(object sender, MetaGestureEventArgs metaGestureEventArgs)
 {
     var touch = metaGestureEventArgs.Touch;
     if (touch.InputSource == this) return;
     map.Add(touch.Id, beginTouch(processCoords(touch.Hit.RaycastHit.textureCoord), touch.Tags).Id);
 }
Esempio n. 6
0
 private void OnTouchEvent(object sender, MetaGestureEventArgs e)
 {
     shouldSpawn = true;
     spawnCoords = camera.ScreenToWorldPoint(new Vector3(e.TouchPoint.Position.x, e.TouchPoint.Position.y, camera.farClipPlane));
 }
Esempio n. 7
0
 void OnTouchEnded(object sender, MetaGestureEventArgs e)
 {
     if (((MetaGesture)sender).State == Gesture.GestureState.Ended) shouldSpawn = false;
 }
Esempio n. 8
0
 private void touchMovedhandler(object sender, MetaGestureEventArgs metaGestureEventArgs)
 {
     var touch = metaGestureEventArgs.Touch;
     if (this.appeared && !this.collided && !this.resetting)
     {
         Vector3 positionTouched = Camera.main.ScreenToWorldPoint(touch.Position);
         positionTouched.z = 0;
         this.transform.position = positionTouched;
     }
 }
Esempio n. 9
0
 private void touchEndedHandler(object sender, MetaGestureEventArgs metaGestureEventArgs)
 {
     TouchTime = 0;
 }
Esempio n. 10
0
 private void touchBeganHandler(object sender, MetaGestureEventArgs metaGestureEventArgs)
 {
     if (TouchTime == 0)
     {
         TouchTime = Time.time;
     }
 }