|MadSci Network: Engineering|
There are resistors that can be used for your stated pupose. They are called Force Sensing Resistors (FSR). You can design you door so as it opens, a spring applies increasing pressure to your resistor.
websites about Force Sensing Resistors (FSR):
There are some other approaches you can take.
1) Use a potentiometer (variable resistor) that has shaft that turns. Mount the body to one side of the hinge and the shaft to the other side of the hinge. You can get these many places including Radio Shack.
2) Use polarized film and a white LED and a light sensitive resistor. Use two pieces of polarized film (PF). One attaches to one side of the hinge and the second to the other side of the hinge. As the two pieces of PF rotate with respect to each other, the amount of light they transmit varies. I picked a white LED as the transmitter because the light is easy to see. The light sensitive resistor is called cadmium sulfide (CdS) cell. click photonics link photonics lookup
Once you pick your approach, if you want help with a circuit, let me know.
Try the links in the MadSci Library for more information on Engineering.