On page 27, the specification states that “a restaurant does not accept new customers in the last 3 ticks of their opening time.”
This sentence seems a bit ambiguous to me.
One possible interpretation of “in the last 3 ticks” would be that the restaurant only rejects customers that it is asked to accept during those ticks. EVENT groups, however, are already accepted or rejected three evenings before the event, and REGULAR groups are associated with their restaurant even earlier. Under this interpretation, the rule would therefore not apply to these groups. EVENT groups explicitly choose and reserve their restaurant three evenings before the event.
Even if this interpretation is too specific, the word “new” could also be interpreted as meaning that REGULAR groups are not new customers and therefore are not affected by this rule.
Currently, I implemented it so that the Browsing Service only excludes restaurants for CASUAL groups if they would order/arrive within the last three ticks of the restaurant’s opening time.
For EVENT groups, the Browsing Service considers a restaurant if the visitingTick is anywhere within the restaurant’s opening time, including the last three ticks. This is also how I understood the Browsing Service description, since for EVENT groups it only says that the restaurant must “be open at the visitingTick of the eventEvening”.
REGULAR groups do not use the Browsing Service and simply arrive at their predetermined restaurant at their visitingTick.
However, I am also not sure whether the “last 3 ticks” rule is supposed to be considered by the Browsing Service at all. For CASUAL groups, the Browsing Service description only states that the restaurant has to be “currently open”.
If the last-three-ticks rule is not supposed to be checked by the Browsing Service, then a CASUAL group could potentially select a restaurant and produce a successful Restaurant Decision log, but then be rejected by the restaurant because it no longer accepts new customers. In my current implementation, such a restaurant would not be considered by the Browsing Service at all, so the group could instead select another restaurant or produce a Restaurant No Decision log. The specification distinguishes these two restaurant-decision logs explicitly.
So I would like to clarify whether my current interpretation is correct:
Does the “last 3 ticks” rule only affect CASUAL groups during restaurant selection, while EVENT groups may still have a visitingTick in those last three ticks and REGULAR groups simply arrive as usual? Or should the rule be handled somewhere after the Browsing Service has already selected the restaurant?