~$10 part at any auto parts store.
It's not a "pressure gage" per se, it reads mid-scale if oil pressure is above ~8 psi.
In other words, it's a pressure switch.
Typically acts as you described AT IDLE. If it's doing it at higher RPM, I'd make sure that switch gets replaced BEFORE you buy the truck.
Could be as simple as a loose connector on the pressure switch too.
I've seen it happen when the vehicle has a low idle problem. In that case, the oil pressure switch wasn't bad, the pressure was simply low due to low idle rpm.