you could give the doors an instance variable "DoorName" and give each door a unique name, then give the switches an instance variable to hold the name of the door that each one opens.
when the player clicks a switch, have a condition that picks the door with the name contained in the switch's variable...