THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 21/08/2009 at 02:47, xxxxxxxx wrote:
User Information:
Cinema 4D Version: 10.5
Platform: Mac ;
Language(s) : C.O.F.F.E.E ;
---------
Hi, please excuse the extreme beginner question, but I am trying to make a pluggin that updates only when the animation is playing. I've tried this:-
main(doc,op)
{
var number,on_off,coffee_tag,store_t,sec,last_time;
doc->SetFps( 25 );
coffee_tag=op->GetFirstTag();
while(coffee_tag)
{if(instanceof(coffee_tag, CoffeeExpressionTag)) break;
coffee_tag=coffee_tag->GetNext();
}
if(!coffee_tag) return;
if(!(coffee_tag#ID_USERDATA:2)) return;
// GET TIME
var t = doc->GetTime();
var sec = t->GetSecond();
if (sec == last_time)return;
number=coffee_tag#ID_USERDATA:1;
println (number);
{
last_time == sec;
}
}
but no joy, any pointers would be greatly appreciated.
Many regards Conor