It seems to be a problem with the way you handle the idle flag. Well, I didn't read your code carefully, I suggest right away: restart from scratch :) concerning the keys handler. Here's what I'd do:
Well, basicly do the following:
set idle to true
check all possible keys - and set idle to false if the user makes any action
in the end ask if idle is still true and play the idle animation if required.
idle=1 if keydown(walk) if jumping=0 if walking=0 walking =1 animate joe,walk_seq endif idle=0 swimming=0 whatever=0 isbored=0 endif moveentity joe,0,0,1 endif if keyhit(jump) if jumping=0 jumping =1 animate joe,jump_seq jump_force#=1.1 isbored=0 idle=0 swimming=0 whatever=0 walking=0 endif endif if jumping=1 jump_force=jump_force- .1 if jump_force < -1.1 then jumping=0 ; add collision check! endif if idle=1 if isbored=0 animate joe,idle_seq isbored=1 endif endif translateentity joe,0,gravity#+jump_force#,0 ; gravity
Well, basicly do the following:
set idle to true
check all possible keys - and set idle to false if the user makes any action
in the end ask if idle is still true and play the idle animation if required.