If you get the job done, it's good code. Don't let anyone tell you otherwise. The people who shat on the Terraria source didn't write Terraria and they also likely never finished anything. It is insanely hard to genuinely finish a project it's much, much easier to be a critic.
So much easier in fact that, personally, if someone hasn't finished a project they genuinely aren't worth listening to. They don't know what it takes.
Code isn't going to be perfect absolutely everywhere. But what does perfect even mean? If the task is completed and does the job then how much "perfection" do you even need?
A genuine pro will always understand the context. It's why code reviews in their current form are really pointless because the interface encourages people to make a comment regardless. And because you only ever get a diff or a portion of the code as a commit you can never really understand the full context unless they genuinely take the time to do so, which they can't because the whole pipeline is designed so code reviews are shovelled through as quickly as possible.