2D Toolkit Forum
2D Toolkit => Support => Topic started by: juts on May 12, 2013, 12:53:37 am
-
I've got a scene set up using TK2DCamera with an ortho size of 512. I have a sprite thats 1280x3000 that scrolls off the screen by incrimenting its transform.position.y. For some reason when the sprite is fully off the screen OnBecameInvisible is never triggered. The code for it is below, it never gets called.
void OnBecameInvisible()
{
Debug.Log("it got herre");
enabled = false;
}
Any Ideas?
-
Haha... nevermind. The unity editor thinks its a camera and because i had it open in a scene view it was never 'invisible". Silly renderer.
-
Glad you've sorted it out, and thanks for sharing the info.