I'd like to have a keypad in a map of mine as an easter egg. The setup isn't too crazy:
Now hopefully you've followed thus far. My problem is that this method doesn't allow me to have a button hit multiple times in a row or even more than once in the sequence. The code I have in mind has 6 twice in a row and 3 scattered 3 times.
If it helps, here is a picture. Also, I know that you can use AddOutput to give a specific number of uses to an output, so there's that. I just don't know exactly how that would help me.
- I have the 2fort keypad model from sfm_beta
- there's a func_button for each of the 12 buttons on the pad. The star symbol resets the pad and the hash/pound symbol enters it.
- I also have 3 ambient_generics and a logic_relay. The sounds are for a press, error, and success. The relay is if the code is entered correctly.
- Each button plays a sound when pressed, whether locked or not. Only the first button in the code starts unlocked. When a locked button is pressed the logic_relay is locked.
- star and pound enable the relay. The pound symbol will first try to trigger it though.
- the first button in the code will unlock the next button and lock itself and that one will do the same, etc.
- if the pound button is pressed and it is locked, it will play an error sound.
Now hopefully you've followed thus far. My problem is that this method doesn't allow me to have a button hit multiple times in a row or even more than once in the sequence. The code I have in mind has 6 twice in a row and 3 scattered 3 times.
If it helps, here is a picture. Also, I know that you can use AddOutput to give a specific number of uses to an output, so there's that. I just don't know exactly how that would help me.
