for some reasons we are using GUITextures for visible cursors in our MultiTouch project. I would like to add a trail function to this cursors (think about moving your mouse around the screen and leaving a decent trail behind). While the built-in trail renderer works sweetly for GO, i did not found a simple method to assign a trail to/with a GUITexture. Parenting a GO to the texture prefab won’t work (different screencoords). Any idea how/what could i do?
The trail renderer uses 3D space and GUITextures use viewport space, so that won’t really work. I’d recommend using a small plane in 3D space for the cursor instead of a GUITexture.
i was allmost sure that i will get this response Well, i was thinking about doing that, since the GUItexture thingie is really limiting some possibilities (animations etc. on cursors)… But i am not sure what problems i will facing by using a 3d GO for cursor stuff. The convenience of the GUITextures is that they are allways staying on top of your scene and facing the camera. If i am gong with the 3d-space i will have to take care in every single composition about the “depth” placement of the cursor. I was hoping to find another way maybe by translating the World coordinates of the trail renderer to screen-coordinates and restricting the “movement” of the trail rendere to 2d space…
GUITextures are really 3D objects as well, actually (everything in Unity is). It’s quite simple to make an object always face the camera with a small script (see the wiki), and there are various techniques to make them always on top (a camera that just renders the cursor, shaders, etc.).