Opening, Closing, Keeping door open at proximity

Hi. I made an animation for a door. The door opens from frames 1 to 20 and closes from 20 to 40. I also did a trigger cube, which means that when the player get's in that cube (close to door) The door opens but closes just after.

I'd like to make the door open when the player enters the Trigger-cube, stay open while he's in, and close when he get's out.

Please help, THANK YOU!

Split the animation in open and close. You can do that in the fbx importer settings. Then play the open animation on trigger enter and the closing animation on trigger exit.