while(1)
{
wait(1);
if(joy_force.y)
{
c_move (my, vector(6*time_step,0,0), nullvector, GLIDE);
wait (1);
}
if (joy_force.x)
{
my.pan += 8*time_step;
}
if (!joy_force.y)
{
idle_percent = (idle_percent +2*time_step)%100;
ent_animate(me,"stand",idle_percent,ANM_CYCLE);
}
else
{
ent_animate(me,"walk",walk_percent,ANM_CYCLE);
walk_percent += 10 * time_step;
}
if (joy_2 && joy_force.y)
{
ent_animate(me,"run",run_percent,ANM_CYCLE);
run_percent = 7* time_step;
}
}