<PAGE>
EXHIBIT 23.4
[H.J. GRUY AND ASSOCIATES, INC. LETTERHEAD]
CONSENT OF H.J. GRUY AND ASSOCIATES, INC.
We hereby consent to the use of the name H.J. Gruy and Associates, Inc. and
references to H.J. Gruy and Associates, Inc. and to inclusion of and references
to our report, or information contained therein, dated February 24, 1999,
prepared for 3TEC Energy Corporation (Formerly Middle Bay Oil Company) in the
Registration Statement on Form S-2, for the filing dated June 2, 2000.
H. J. GRUY & ASSOCIATES, INC.
By: /s/ Sylvia Castilleja
------------------------
Sylvia Castilleja
Senior Reservoir Consultant
June 2, 2000
Houston, Texas