To replace the Walbro carburetor on an AGM-30 gas engine, first, ensure the engine is off and cool. Disconnect the fuel lines and any linkages attached to the carburetor, noting their positions for reassembly. Remove the mounting screws or bolts securing the carburetor to the engine. Install the new carburetor by reversing the disassembly steps, ensuring all connections are secure before starting the engine.