Search Unity

Replicating OnMouseEnter with two objects on 2D plane

Discussion in 'Scripting' started by pseudonym, Apr 3, 2009.

  1. pseudonym

    pseudonym

    Joined:
    Apr 23, 2006
    Posts:
    145
    Hallo,

    Is it possible to get the width and height of an object in the world translated into pixel width and height in screen coordinates?

    I'm trying to use a custom pointer object that allows players to pick things up using a game pad, so the first step is to register the equivalent of OnMouseEnter, but between two game objects.

    Could I be going about it in a different way?

    Thanks,

    James
     
  2. pseudonym

    pseudonym

    Joined:
    Apr 23, 2006
    Posts:
    145
    Yes I could, OnCollisionEnter - durrr
     
  3. pseudonym

    pseudonym

    Joined:
    Apr 23, 2006
    Posts:
    145