Guessing those are K-Line Alcos. Kooljock gave the right answer. Made that mistake many times. Just connect the wire currently connected to the center rail to the outer rail and the wire currently connected to the outer rail to center rail.
I saw your separate post about upgrading these units. Electric Railroad (ERR) components are available from 3rd Rail trains to convert your locos from conventional control to Lionel Train Master Command Control (TMCC). Not a cheap endeavor if you're going t pay someone to do the work, especially if you want diesel railsounds, directional lighting, and electrocouplers in the powered unit and dummy. Could easily be $300. Plus you'll need the remote and the TMCC Command Base which, on the used market, will likely set you back another $150. Legacy bases and remotes are even more.
If you're going to build a O Gauge empire, all that might not be a bad way to go. If you're simply looking to have a few engines for seasonal use, I'd suggest looking into simpler and lower cost options before pursuing an upgrade.
One would engines from the MTH family using its DCS but instead of going full DCS, use DCS "lite" (my term) with the Remote Commander. Simple set up.
Second option would be Lionel's Lionchief Plus with or without Bluetooth. Lionel made the Alco FAs like yours recently in LC+. Comes with a dedicated remote control or you can use the LC universal remote. With LC+, there's no computer to connect to the track; all electronics are on board in the engine.