From which I must assume that you are one of the people that need to be told, via legislation, rather than common sense, how to behave.But legislation exists to help ensure that everybody does and that there will be consequences for those who do not. It is there to ensure that the majority are protected from the minority who won't play by the rules (and such a minority has to be expected).
In the case of Covid, failure to comply is not something that will only potentially affect the transgressor. It is something that will potentially affect others, possibly very many others.
The law is there to deal with the idiots and the anti-social, The government is the state legislature. It is their duty to legislate and to protect all. The duty of the citizen is to obey the law and thereby to protect his fellow citizen. Merely issuing friendly advice in the vain hope and expectation that it will be heeded is complete folly, even more so when the safety and wellbeing of millions is at stake.
Where there are those who decline to play by the rules - Yes, they are at fault. But so is the government that fails to ensure the protection of the majority.
At least we have cleared that up.
ETA a further thought occurs. It was General David Ramsbottom who said, after his underhand "resignation" from the post of HM Inspector of Prisons (he discovered that he had "resigned" when he read about it in the newspaper) "just because it is written down does not mean it is going to happen"