My bet would be to get the 8800GT. I've read that the GTS 512MB only performs about 15% better than the 8800GT which makes the 8800GT a better buy since the GTS costs more than 15% more.
To make it simple, the 8800GT is the best card for the price at the moment with the HD3870 and HD3850 right behind it. Also, personally I would get a non pre-clocked 8800GT such as this one:
http://www.newegg.com/Product/Product.aspx?Item=N82E16814125081
Hope that helped!