Iphone 3GS sudden shut down problem?

I just purchased used iPhone 3GS from a fella, problem is whenever i play any game after some minute it suddenly shut down, even battery is fully charge.
iPhone 3GS, 32G, SU, old BR, 5.1

please help me out, what's possibility the cause of this issue?

Don't play the games, delete the apps/

Most likely it's your hard drive or corrupted app. Delete the game and other apps you don't use then Double click home button a d clean the running apps from bottom and hold the power button and home button till your phone shuts down then wait 5 minute to be dropped from tower and turn your device on. Try it again if it happens again then your facing hardware malfunction

Take it to the shop to get fixed same thing happened to me

  • Why won't my iphone 4s shut down? Everytime I go to turn my Iphone 4s ( Running IOS7 ) off it just boots back up after 1-2 seconds, I have cleaned the dock connections and have done the resets etc. I have noticed if it is below 20% battery it will stay off but any % over 20 it just turns back on, Anyone help me on this please! Also to add if plugged into the charger it will turn off fine.
  • Why does my iPhone shut down? When I touch my screen a little hard and let my finger stay there for some seconds, some white and black lines appear and then the whole iPhone shuts down. After some seconds the apple logo appears and the mobile turns on again. Can someone please tell me why this happens, and what I can do about it?
  • Why does my iphone shut down automatically? I have a iphone 3 and everytime i text play you tube the phone turns off. I have turned all the internet off to save battery. It is only 16gb and I have loads off apps and maybe it would be worth removing some as that would help with. Is it the battery maybe it needs replacing or i could need a different charger. When you put in in to charge its on fourty percent wthf. I need my phone for everyday use. Does this happen to any one else?
  • Why does my Iphone shut down at 20%? When I first got my Iphone 5, it would usually keep running until it got to about 8% battery. However, these past couple of weeks I'm starting to notice that it shuts down at around 20%.Is there a way to fix this problem?