Animation Scripting

Hello I have made an animation for a door in unity and I’m wondering how to make it so that if i push the button a second time it will reverse the animation so that it closes the door. I am not that great at scripting and all I could so is make it so that when i click on the door the animation plays

Any idea how to do this?

Just make a closing animation for your door, its one of the simplest things you can do. I do not think there is a “reverse” component in Unity unless you set the animation to “Ping-Pong” and pause it at certain points to simulate a door opening and closing.