Yeah cause of time_step and slow fps my.animation probably almost never becomes between 80 and 85.

I would use a variable your entity skill as check (make non-zero when you need to call the function and make zero again when you call the function).

But it seems EpsiloN's idea is cleaner so try that first.

ps: is it only for 1 entity?:
Code:
if(button_pressed == 1 && my.animation > 80)
{
  button_pressed = 0;
  ...
}


Last edited by Reconnoiter; 01/22/16 11:13.