Changes made on GameSurface.java and GameSurfaceView.java, tested in a game itself.