UE4 获得GameMode

//获得当前游戏模式
	//UGameplayStatics::GetGameMode(this);
	ACarDemoGameModeBase* CarGamemode;
	//转成自己定义的GameMode类
	CarGamemode=Cast<ACarDemoGameModeBase>(UGameplayStatics::GetGameMode(this));

猜你喜欢

转载自blog.csdn.net/m0_37981386/article/details/83242337
UE4