Tick the checkbox Limit submissions by input values. Two new boxes will show up: Current Value and Maximum Value. Current Value will be updated with every form submission. You don’t need to change anything about it, not now, not ever. In the Maximum Value box, type the maximum number of seats available at the event. (Of course, this feature can be used for other purposes, as well.)
The participants limitation is now set up. In addition, make sure that form users will type in this field the total number of people they are registering through the form. To do this, use the Field Label and Instructions, that can be adjusted in the Edit Field panel as well. Have the label say How many people do you want to register for the event? and the instructions This is the total number of participants, that includes yourself.
With this feature enabled, a line of instructions will show up anyway, indicating the maximum accepted value; in other words, the number of seats left. This line can be changed in Settings → Translations.
When the maximum number of participants is reached, form users will not be able to add new attendees to the event.