OnClick events not working (SOLVED)

Did you set the DefaultClickTraceChannel?
Works no problem in a quick project.

in cpp of controller in beginplay

void AMyPlayerController::BeginPlay() {
	bEnableClickEvents = true;
	bShowMouseCursor = true;
	bShowMouseCursor = true;
	DefaultClickTraceChannel = ECollisionChannel::ECC_Visibility;
}

Also make sure you have your custom player controller set in the project settings game mode!


1 Like