обязательно было

had to

→ обязательно
phrase Uncommon #22,802
had to Used with an infinitive to express past necessity; in questions, it often sounds like a reproach: “Did you have to…?”
RU: Тебе обязательно было так грубо отвечать?
EN: Did you have to answer so rudely?

Обязательно было меня приносить в жертву?

Was it really necessary to sacrifice me?

— Три идиота (2009)

Обязательно было кричать, да?

Did you have to shout?

— Сказание о принцессе Кагуя (2013)

Обязательно было так орать?

Was it necessary to yell like that?