In this case, no matter how good the teacher is, he won't remember. He confiscated your cheat sheet and read your student ID card. Maybe this is the normal practice, because after all, it seems unreasonable for him not to accept your cheat sheet. He looked at your student ID card, maybe it was a hint and a warning! Another possibility is to prepare for the worst. He won't tell you that you are registered, but you are already registered.
The university relies on its own consciousness, reading carefully before the exam. In fact, the general exam is not that difficult!
Good luck!