Hello, I have a JavaScript that I use to change the text color of a 3D Text and it will be used to close the application later. Here is the code:
function OnMouseEnter()
{
renderer.material.color = Color.red;
}
function OnMouseExit()
{
renderer.material.color = Color.white;
}
function OnMouseUp()
{
}
This script is a component of a 3D text. I also have 3 .c4d files on my project. Each one contains a model (it’s a bear) and a animation (made in Cinema 4D). The 2 animations are: Idle (like breathing) and death. I used the idle .c4d file to put the bear on the scene and the animation that was on that .c4d. On the other .c4d file, there is other animation, a death animation. What I want is that when “OnMouseUp()” occurs, the animation from the second .c4d (death) starts and then the application quit.
I know I close the aplication with “Application.Quit();”, what I want to know is how to create the stuff I texted here before.
Thanks in advance.