How can I disable cheats for a controller without having to recreate the client controller? I need to leave it disabled by default, since this starts enabled by default.
// Fill out your copyright notice in the Description page of Project Settings.
#include "CheatActivation.h"
#include "GameFramework/GameSession.h"
#include "GameFramework/GameModeBase.h"
#include "Runtime/Engine/Public/TimerManager.h"
#include "Kismet/GameplayStatics.h"
void UCheatActivation::SetCheatActivation(APlayerController* Controlador, AGameModeBase* CurrentGameMode)
{
if (CurrentGameMode != NULL && Controlador != NULL)
{
CurrentGameMode->AllowCheats(Controlador);
Controlador->EnableCheats();
}
}
There isn’t a Disable Cheats or Disallow Cheats();