A directed polymer is allowed to branch, with configurations determine
d by global energy optimization and disorder. A finite-size scaling an
alysis in 2D shows that, if disorder makes branching more and more fav
orable, a critical transition occurs from the linear scaling regime fi
rst studied by Huse and Henley (Phys. Rev. Lett., 54, (1985) 2708) to
a fully branched, compact one. At criticality clear evidence is obtain
ed that the polymer branches at all scales with dimension (d) over bar
(c) and roughness exponent zeta(c) satisfying ((d) over bar(c) - 1)/ze
ta(c) = 0.13 +/- 0.01, and energy fluctuation exponent omega(c) = 0.26
+/- 0.02, in terms of longitudinal distance.