Unity Spain

Post Antiguos => General (Antiguo) => Mensaje iniciado por: xcqoax en Agosto 13, 2015, 02:08:06 AM

Título: ayuda con mostrar texto
Publicado por: xcqoax en Agosto 13, 2015, 02:08:06 AM
Hola saludos, tengo un problema. deseo que tocar un objeto (trigger) me muestre un texto en pantalla. cree el uitext y lo ancle a dicho objeto pero no consigo que cuando yo entre al trigger se muestre dicho objeto y cuando salga desaparezca. al objeto (trigger) le puse el script. agradecere mucho su ayuda.

function OnTriggerEnter (col:Collider)

{

GetComponentInChildren(GUIText).enabled=true;

} 

function OnTriggerExit (col:Collider)

{

GetComponentInChildren(GUIText).enabled=false;

}

Título: ayuda con mostrar texto
Publicado por: ramunda en Agosto 13, 2015, 10:31:22 AM
[quote author=xcqoax" data-ipsquote-contapp="forums" data-ipsquote-contenttype="forums" data-ipsquote-contentclass="forums_Topic" data-ipsquote-contentid="15961" data-ipsquote-contentcommentid="101518">Hola saludos, tengo un problema. deseo que tocar un objeto (trigger) me muestre un texto en pantalla. cree el uitext y lo ancle a dicho objeto pero no consigo que cuando yo entre al trigger se muestre dicho objeto y cuando salga desaparezca. al objeto (trigger) le puse el script. agradecere mucho su ayuda.

function OnTriggerEnter (col:Collider)

{

GetComponentInChildren(GUIText).enabled=true;

} 

function OnTriggerExit (col:Collider)

{

GetComponentInChildren(GUIText).enabled=false;

Sólo texto | Texto con Imágenes