How to take this thing off? I think this bike is from West Germany. What tool do I need and is there a screwing direction trick? Thanks! (I am taking this off to repaint)
That is called the bottom bracket and houses the bearings through which the crank axle sits. You'll need a specialist tool to remove it (see the small notches) and there are several different types on the market. Something like this might do it though?
A dirty hack is to use a hammer and drift, but it will marr the impact point on the lock ring.
You can use an old/rubbish flat screwdriver as a drift too, by putting the end into the corner on a notch.
Second option is to use a sliding lockjaw pliers around the whole lockring, because its wider than the BB you'll be able to get a grip. Marring the metal can still happen, so layers of cloth can help protect it.
Buying the right tool is an option, but depends if you're going to get value out of it.
Finally, consider replacing the entire BB with a modern cartridge bearing housing. That will use a common BB removal tool without a lockring. This way you can bang off the old one without worrying about refitting it. This will require different cranks too, your old cottered cranks won't fit.
For the unbolting directions a Sheldon Brown's bottom bracket cribsheet gives some information.
Unbolting the non-drive side is in almost all cases counterclockwise (seeing the lock ring I'm sure the cups aren't pressed in).
You may then extract the spindle and the bearings and have a deep look through the shell to the drive side to confirm whether the thread there is reverse (unbolting is then clockwise).