im scripting thecnical animation that can be change for a couple of different things…exemple
this is a majic casting from the ground…
var Time:float=0.01;
var Scaling:float=0.1;
var Scaling:float=0.1;
function Cast(){
for(var i=0; i<Multiplie;i++){
transform.localScale.y+=Scaling;
transform.localPosition.y+=Pos;
yield WaitForSeconds(Time*Time.deltaTime);
}
if(Back)
{
yield WaitForSeconds(BackTime);
for(var iy=0; iy<Multiplie;iy++)
{
transform.localScale.y-=Scaling;
transform.localPosition.y-=Pos;
yield WaitForSeconds(Time*Time.deltaTime);
}
}
}
the things is that im changing the vars depend of the majic that is casted…and i have a lot…so in my first computer yield run faster than my other one, when i play it on lower graphics and resolution it runing more faster again…when i have a lot of particles(particle emitter mostly)it runing slower but, when i use a mathf.lerp for some animation or even a simple rotation in the update or late update funtion…no matter what happen it runing at the same times and if i have a million of particle exemple…it will do the same but just lagging and skipping some frame around but the yield keep runing out slowly? i cant realy transfert my other animation in the update cuz i cant hold it and its so complicated…is there a way of fixing this?