I start the implicit activity in this way:
Intent launchIntent = context.getPackageManager().getLaunchIntentForPackage(miniGameSceneStatus.getPackageName());
context.startActivity(launchIntent);
If this activity finish I receive a broadcast, but if the activity crashes I can't see anything except it returns to the first activity without any problem.
Is there any way to know what is happening in the second activity?
Wrap up your code with null check before to get context and miniGameSceneStatu and your activity will not get crashed.
Check camera permission before to do any action