Rod Singleton added 10 points for the Bobcats (7-6), who snapped a three-game losing streak to the Wildcats.
Weber State trailed 72-64 with 1 minute to play before rallying to within 74-72 with 10 seconds left. Hughey scored six points during the 8-2 run. After Montana State added a free throw, the Wildcats had a chance to tie it at the buzzer, but Bamforth's 3 was off line.
The Bobcats trailed 34-33 at halftime but opened the second half with a 13-8 run and led the rest of the way.