On a form, Transaction.MailingAddress will pull in the head office address if the invoice is for a branch that has a head office (e.g if the Name Code is something like “BRCH.HOFF”, the address will come from the Name “HOFF.”)
If there is a per-transaction address, that will be preferred, so one way would be to click the Mail checkbox and enter the branch address.
If you always want the branch address, modify the form to use
Lookup(Transaction.SequenceNumber, "Transaction.MailingAddress")
This will bypass the head office address lookup. It will give the per-transaction address if there is one, otherwise it will look up the address from the Name record associated with the transaction.