dontlistentome :
The other factor to consider is the power supply. You can get decent performing cards for cheap, but these tend to be older cards. The problem there is that older gaming cards tend to use a lot of power. It's VERY difficult to find a gaming card with good performance AND it's cheap AND it uses low amounts of power.
The HD 7770 isn't as efficient as current generation cards, but it isn't
too bad in terms of power consumption, only having an 80 watt TDP. I believe it does require a 6-pin PCIe power cable to be connected though, so you may need to make sure your PSU has one of those.
As for the CPU, I'm not entirely sure. Judging by the information here...
https://support.hp.com/us-en/document/c01864941
...it looks like the highest processor that's officially supported is the Phenom II X4 B95, which appears to be nearly identical to the 955, only clocked slightly lower (more like a 945). Some 955s have a TDP of 95 watts, though others are 125 watts, which could be a problem.
Also, being an apparently OEM motherboard, it might just not support that processor. If you are getting it from a friend, perhaps they would let you test it first? I suspect an actual B95 might be more likely to work properly, but it's difficult to say for sure. It might also run hot and potentially overheat under load, depending on what kind of CPU cooler is installed.