How can I create/customize my own console commands in C++?

Sorry, I didn’t how to recreate something like stat startfile and I kinda panic I see the word threadsafe and dumps in that thing.

You might want to ask a very senior level programming dude for that architecture.