You can create context menu entries either for all file types, for specific file types (e.g. ".txt") or for folders.
In case you want the shell menu for all types of files, you could do it this way:
1) Under \HKEY_CLASSES_ROOT\*\shell\ Create a key "Compare with Total Commander" (or something like that)
2) Beyond that newly created key, create another key called "command"
3) As a default value for that key, set your command line. E.g. "C:\Program Files (x86)\Total Commander 9\totalcmd.exe" /S=C %1
So it should look like this:
Image:
https://cdn1.imggmi.com/uploads/2019/4/10/d70ccd5703de914d6877be9a57196c6c-full.png
And the result in Windows explorer will then be like this:
Image:
https://cdn1.imggmi.com/uploads/2019/4/10/6c39e13976a4973b591ce67dc20d3f64-full.png
But be aware: a shell context menu entry can only relate to 1 file (i.e. the one you selected) while your Total Commander call actually expects 2 Params (since you want to compare 2 files). In other words: with my suggested solution you'll have to select the 2nd file manually within the Total Commander Comparison Screen