action player_walk()
{
while (1)
{
if(key_w)
{
c_move(my,nullvector,vector(0,3 * time_step,0),GLIDE);
}
if(key_a)
{
my.pan += 3 * time_step;
}
if (key_s)
{
c_move(my,nullvector,vector(0,-3 * time_step,0),GLIDE);
}
if(key_d)
{
my.pan -= 3 * time_step;
}
else
{
ent_animate(my,"stand",stand_perc,ANM_CYCLE);
stand_perc = 3 * time_step;
}
wait (1);
}
}