I have tinkering with the Lost in Space robot. in my Chariot. What I want is the mouth part to blink while the wav is played.
I can get the wav to play and but in guess I need towork on the timeset to be shorter.
On the mouth I have the texture being changed to red like in the image and back to grey. I think I need to make a mesh
behind the mouth part that I can make red/black. The robot body also rotates so a rotating mesh inside the robot will not work.
void Chariot::TextureChange()
{
if ((MainExternalMeshVisual != 0) & (blinkstate==1))
oapiSetTexture (MainExternalMeshVisual,5,red_tex);
if ((MainExternalMeshVisual != 0) & (blinkstate==0))
oapiSetTexture(MainExternalMeshVisual,5,normal_tex);
}