My Event Engine can do this. You can select a certain code or all codes. Feel free to take a look at the code and use what you want.
In this example, the light will turn on if a selected user inputs their code. Light turns back off when door is locked.
