You say Explode() is called but ShowExplosion() sometimes isn’t. When you expect something to work but it doesn’t, it means there is a difference between your expectations and whats actually happening. What you should do then is test and confirm your expectations. When something never works, you can use Visual Studio breakpoints. When something “sometimes” doesn’t work, use logging and try to catch the bug in the act. So like someone else said, add logging messages between the lines in Explode(). Here I can do it for you even:
void AProjectile_Explosives::Explode(const TArray<AActor*>& toIgnore)
UE_LOG(LogTemp, Warning, TEXT("Explode() called"));
// Always printed!
if (GEngine) GEngine->AddOnScreenDebugMessage(-1, 5.f, FColor::Red, FString::Printf(TEXT("FUNCTION CALLED")));
UE_LOG(LogTemp, Warning, TEXT("Pre check 1"));
if (bExploded || Role < ROLE_Authority)
UE_LOG(LogTemp, Warning, TEXT("Post check 1"));
UE_LOG(LogTemp, Warning, TEXT("Pre check 2"));
if (ExplosionDamage > 0 && ExplosionRadius > 0 && DamageType)
UGameplayStatics::ApplyRadialDamage(this, ExplosionDamage, GetActorLocation(), ExplosionRadius, DamageType, toIgnore, nullptr, OwnerWeapon->GetWeaponOwner()->GetController());
UE_LOG(LogTemp, Warning, TEXT("Post check 2"));
UE_LOG(LogTemp, Warning, TEXT("Pre ShowExplosion()"));
UE_LOG(LogTemp, Warning, TEXT("Post ShowExplosion()"));
bExploded = true;
UE_LOG(LogTemp, Warning, TEXT("Explode() finished"));
Now catch it in the act. Try to get the grenade to not explode, while it should. Then check the log, did all the messages print as expected? If not, what messages are missing will give you some useful info. If they do all fire, it means ShowExplosion is called, but that function itself isn’t behaving like you expect.
Also, you should learn to not get hung up on arguments like “it used to work in 4.10”. Things can occur together but that doesn’t mean one implies the other. It only distracts you from finding the real issue. Ok, enough channeling Mr. Miyagi for one day.