C++ debugging for packaged game


I have packaged my game for android as well as windows. The game goes on till main menu but as soon as I open a level the game crashes.

So I need to know how do I debug the game so that I can find the error in code. I have tried Debug Game for Win64 and ARM by attaching to process , and I am getting an array index out of bounds but I am not able to find where in the actual code this error is.

What exactly does the error message say, in its entirety?

So I managed so far to debug the project and wirk out the game on windows as a platform.
There was an error in code as something was not being initialized at the right time.

But I am targeting android. I have made an apk , installed it on my device but the game crashes after splash screen.
A FirstPersonTemplate project is wirking fine on my device.
So how do I debug the apk using Visual Studio 2015

I follwed this link but without success ->

An error is displayed saying" Unexpexted GDB output from command:target-select remite :5039.

Also this error"android command’ failed to execute" was also displayed when I was trying todebug the apk.