I believe the issue has to do with what client is used when establishing connectivity to Server B from Server A rather than how you order your protocol order on the server itself.
The first hint comes from Choosing a Network Protocol: Enabling the Protocol (highlighting mine):
The protocol must be enabled on both the client and server to work.
The server can listen for requests on all enabled protocols at the
same time. Client computers can pick one, or try the protocols in
the order listed in SQL Server Configuration Manager.
I suspect most clients determine the desired order of the protocols being used rather than delegate that to the server.
Further digging through MS documentation yields this interesting note in the Client Protocols Properties (Order Tab) article:
These settings (e.g. Order) are not used by Microsoft .NET SqlClient. The protocol
order for .NET SqlClient is first TCP, and then named pipes, which
cannot be changed.
As we can see for the .NET SqlClient, if TCP/IP is an enabled protocol on the server and the .NET SqlClient is being used, it doesn't matter what you do, you're getting a TCP/IP connection. So with this client in particular the protocol specified on the server most definitely doesn't matter.
With these examples, I think it's pretty clear that the client you're using to connect to a server has more bearing on the protocol being used rather than the connection protocol ordering on the server itself.
In your specific case, if you really want to use Named Pipes instead of TCP/IP, you may be able to force it via a Client Alias:
You would need to create this alias on Server A for Server B. Just note that aliases come with their own headaches (e.g. you've now got another thing to manage whenever you deal with connectivity changes on Server B), but as a workaround, it may do the trick.
Also of note, Named Pipes can become problematic on slow connections where the same issues are not as impacting via TCP/IP connections, which is likely why most clients gravitate toward the TCP/IP protocol by default.