If your towers aren't being destroyed

Make sure you have your cast in the correct if-else nest:

    if (DeadActor == Tank)
    {
        Tank->HandleDestruction();
        if (APlayerController* Controller = Tank->GetPlayerController())
        {
            Tank->DisableInput(Controller);
            Controller->bShowMouseCursor = false;
        }
        // NOT here like I had it 
    }
    // but HERE where it actually goes
    else if (ATower* DestroyedTower = Cast<ATower>(DeadActor))
    {
        DestroyedTower->HandleDestruction();
    }
3 Likes

Privacy & Terms