Converting a Character BP to C++ issue

I have changed the code to C++ and when I want to play the game it crashes and I get this log:

LoginId:7f1954aa48f3b72074483186587734dd
EpicAccountId:a7c699fd79ea44a0a8b8fad01e31dc3a

Access violation - code c0000005 (first/second chance not available)

UE4Editor_Engine!AActor::AttachToComponent() [d:\build++ue4+release-4.15+compile\sync\engine\source\runtime\engine\private\actor.cpp:1489]
UE4Editor_MyProject8_7091!AMannequin::UnPossessed() [c:\users\pavle\onedrive\documents\unreal projects\myproject8\source\myproject8\character\mannequin.cpp:77]
UE4Editor_Engine!APlayerController::UnPossess() [d:\build++ue4+release-4.15+compile\sync\engine\source\runtime\engine\private\playercontroller.cpp:1190]
UE4Editor_Engine!APlayerController::Possess() [d:\build++ue4+release-4.15+compile\sync\engine\source\runtime\engine\private\playercontroller.cpp:768]
UE4Editor_Engine!AGameModeBase::FinishRestartPlayer() [d:\build++ue4+release-4.15+compile\sync\engine\source\runtime\engine\private\gamemodebase.cpp:1241]
UE4Editor_Engine!AGameModeBase::RestartPlayerAtPlayerStart() [d:\build++ue4+release-4.15+compile\sync\engine\source\runtime\engine\private\gamemodebase.cpp:1194]
UE4Editor_Engine!AGameModeBase::RestartPlayer() [d:\build++ue4+release-4.15+compile\sync\engine\source\runtime\engine\private\gamemodebase.cpp:1149]
UE4Editor_Engine!AGameModeBase::HandleStartingNewPlayer_Implementation() [d:\build++ue4+release-4.15+compile\sync\engine\source\runtime\engine\private\gamemodebase.cpp:974]
UE4Editor_Engine!AGameModeBase::execHandleStartingNewPlayer() [d:\build++ue4+release-4.15+compile\sync\engine\source\runtime\engine\classes\gameframework\gamemodebase.h:47]
UE4Editor_CoreUObject!UFunction::Invoke() [d:\build++ue4+release-4.15+compile\sync\engine\source\runtime\coreuobject\private\uobject\class.cpp:4525]
UE4Editor_CoreUObject!UObject::ProcessEvent() [d:\build++ue4+release-4.15+compile\sync\engine\source\runtime\coreuobject\private\uobject\scriptcore.cpp:1318]
UE4Editor_Engine!AActor::ProcessEvent() [d:\build++ue4+release-4.15+compile\sync\engine\source\runtime\engine\private\actor.cpp:678]
UE4Editor_Engine!AGameModeBase::HandleStartingNewPlayer()
UE4Editor_Engine!UWorld::SpawnPlayActor() [d:\build++ue4+release-4.15+compile\sync\engine\source\runtime\engine\private\levelactor.cpp:723]
UE4Editor_Engine!ULocalPlayer::SpawnPlayActor() [d:\build++ue4+release-4.15+compile\sync\engine\source\runtime\engine\private\localplayer.cpp:240]
UE4Editor_Engine!UGameInstance::StartPlayInEditorGameInstance() [d:\build++ue4+release-4.15+compile\sync\engine\source\runtime\engine\private\gameinstance.cpp:319]
UE4Editor_UnrealEd!UEditorEngine::CreatePIEGameInstance() [d:\build++ue4+release-4.15+compile\sync\engine\source\editor\unrealed\private\playlevel.cpp:3420]
UE4Editor_UnrealEd!UEditorEngine::PlayInEditor() [d:\build++ue4+release-4.15+compile\sync\engine\source\editor\unrealed\private\playlevel.cpp:2515]
UE4Editor_UnrealEd!UEditorEngine::StartQueuedPlayMapRequest() [d:\build++ue4+release-4.15+compile\sync\engine\source\editor\unrealed\private\playlevel.cpp:1215]
UE4Editor_UnrealEd!UEditorEngine::Tick() [d:\build++ue4+release-4.15+compile\sync\engine\source\editor\unrealed\private\editorengine.cpp:1522]
UE4Editor_UnrealEd!UUnrealEdEngine::Tick() [d:\build++ue4+release-4.15+compile\sync\engine\source\editor\unrealed\private\unrealedengine.cpp:391]
UE4Editor!FEngineLoop::Tick() [d:\build++ue4+release-4.15+compile\sync\engine\source\runtime\launch\private\launchengineloop.cpp:3025]
UE4Editor!GuardedMain() [d:\build++ue4+release-4.15+compile\sync\engine\source\runtime\launch\private\launch.cpp:166]
UE4Editor!GuardedMainWrapper() [d:\build++ue4+release-4.15+compile\sync\engine\source\runtime\launch\private\windows\launchwindows.cpp:134]
UE4Editor!WinMain() [d:\build++ue4+release-4.15+compile\sync\engine\source\runtime\launch\private\windows\launchwindows.cpp:210]
UE4Editor!__scrt_common_main_seh() [f:\dd\vctools\crt\vcstartup\src\startup\exe_common.inl:264]
kernel32
ntdll

How to fix this issue ?

I have fixed the problem. I have coppied wrong code inside Mannaquin and Gun Class !!!

Privacy & Terms