Amending a return; 1040X & revised 1040 show different amounts owed

So I'm amending a return from 2022 due to overpaid taxes from a repaid bonus in a different year (claim of right credit).  I initially owed and that amount was paid and accepted by the IRS.  When I go to amend the correct amount of refund is showing on the 1040X, but the new 1040 that is generated with the credit is now showing the refund to be net of the new amount owed to me and the amount that I paid with the original return.  Which figure will the IRS go by in processing the refund?   There is no where on the 1040X to indicate how I want my refund processed either by direct deposit or check.  The step by step instructions don't give the option for direct deposit.  So should I change this directly on the form?  Or are refunds from amended returns only returned by mail?  TIA