Nowadays, marine scientists are making use of the Kadomtsev-Petviashvili (KP)-category equations in their investigations from the Straits of Georgia and Gibraltar to the Adriatic Sea, North Sea and South China Sea. In fluid mechanics and other fields, the (3+1)-dimensional B-type KP equations have attracted a good size of recent research. For a generalized (3+1)-dimensional variable-coefficient B-type KP equation for the nonlinear waves in fluid mechanics, with symbolic computation, we obtain a variable-coefficient-dependent auto-Backlund transformation, along with two variable-coefficient-dependent families of the shock-wave-type solutions. (C) 2015 Elsevier Ltd. All rights reserved.