Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Emergency yield wait help!

Discussion in 'Editor & General Support' started by Toomber, Feb 21, 2017.

  1. Toomber

    Toomber

    Joined:
    Feb 20, 2017
    Posts:
    3
    Hi All, excuse this emergency, but we are tackling our 1st project for a client and we have a problem with our lovely Google cardboard VR experience that we have nearly finished and looks great!

    Raycasts not always detecting tagged object. It seems random. Sometimes detecting, sometimes not. When the raycast is hitting an object, the object lights up, but sometimes it doesn't, can someone hlep us with this issue?

    Many thanks
     
  2. DroidifyDevs

    DroidifyDevs

    Joined:
    Jun 24, 2015
    Posts:
    1,724
    Perhaps the raycast isn't always hitting the object? Why not use RaycastHit.gameObject.name in Debug.Log to see what the raycast is hitting?
     
    Toomber likes this.
  3. Toomber

    Toomber

    Joined:
    Feb 20, 2017
    Posts:
    3
    That is great thanks. we are delivering to iphones. do you think this might have something to do with it?
     
  4. DroidifyDevs

    DroidifyDevs

    Joined:
    Jun 24, 2015
    Posts:
    1,724
    No, I don't. Raycasts will work exactly the same on any platform. If it doesn't work in the Editor, it won't work on Windows or an iPhone.