Editor crashes every time I try to open my project

I was trying to implement some new functionality for the final challenge and I have apparently introduced a null pointer error. The problem is that it caused the editor to crash right away and now the editor crashes every time I try to open my project.

Is there any way to save/ fix my project??

I have looked online and it said to delete the Binaries, Build, Intermediate, Saved and .vs folders. Then I had my project rebuild them all. I tried deleting the class that is causing the error in windows explorer, but no effect. I tried to moved the level files out of the directories but this had no effect on the problem either.

I find it hard to believe that my project is completely destroyed by this but I don’t know what I can do.

Any help would be appreciated.

Regards

Jason

PS: here is the crash stack if it makes a difference, UPickUpManager is the new class that it appears broke everything.

LoginId:8a72df0f4837b2aba33b0989393c0a5c
EpicAccountId:251efc5e0c8e473698a5877dd6a6f350

Unhandled Exception: EXCEPTION_ACCESS_VIOLATION reading address 0x0000000000000250

UE4Editor_Building_Escape!AActor::ForEachComponent_Internal<UPrimitiveComponent,0,0,<lambda_0969dfbe9fb46aa1f25407a1c0a97296> >() [F:\Program Files\Epic Games\UE_4.27\Engine\Source\Runtime\Engine\Classes\GameFramework\Actor.h:3006]
UE4Editor_Building_Escape!UPickUpManager::UPickUpManager() [F:\Unreal Projects\Building_Escape\Source\Building_Escape\PickUpManager.cpp:14]
UE4Editor_CoreUObject
UE4Editor_CoreUObject
UE4Editor_CoreUObject
UE4Editor_CoreUObject
UE4Editor_Core
UE4Editor_Core
UE4Editor_Projects
UE4Editor_Projects
UE4Editor
UE4Editor
UE4Editor
UE4Editor
UE4Editor
UE4Editor
UE4Editor
kernel32
ntdll

The error indicates the code is in the PickUpManager, around line 14. Open VS Code or other editor of choice, and review the code there. Make changes to have null checks or comment out for now. Recompile and if it builds ok, you should be able to launch the editor.

I have opened the code (I am using Visual Studio 2019) and commented out that line but under the build menu there is no option to recompile.

it’s just build, or CTRL+SHIFT+B

It was an issue with visual studio finding parts of the project but I fixed it by right the project file and tell it to rebuild the visual studio files. So now I can built which I have done but it still crashes when I try to launch the editor.

For reference I have the same crash report but the code for the file is now:

#include "PickUpManager.h"

// Sets default values for this component's properties
UPickUpManager::UPickUpManager()
{
	// Set this component to be initialized when the game starts, and to be ticked every frame.  You can turn these features
	// off to improve performance if you don't need them.
	PrimaryComponentTick.bCanEverTick = true;

}


// Called when the game starts
void UPickUpManager::BeginPlay()
{
	Super::BeginPlay();

}


// Called every frame
void UPickUpManager::TickComponent(float DeltaTime, ELevelTick TickType, FActorComponentTickFunction* ThisTickFunction)
{
	Super::TickComponent(DeltaTime, TickType, ThisTickFunction);

}

Also this is the build log from Visual Studio:

Build started…
1>------ Skipped Build: Project: UE4, Configuration: BuiltWithUnrealBuildTool Win32 ------
1>Project not selected to build for this solution configuration
2>------ Build started: Project: Building_Escape, Configuration: Development x64 ------
2>Creating makefile for Building_Escape (no existing makefile)
2>Parsing headers for Building_Escape
2> Running UnrealHeaderTool “F:\Unreal Projects\Building_Escape\Building_Escape.uproject” “F:\Unreal Projects\Building_Escape\Intermediate\Build\Win64\Building_Escape\Development\Building_Escape.uhtmanifest” -LogCmds=“loginit warning, logexit warning, logdatabase error” -Unattended -WarningsAsErrors -abslog=“C:\Users\Dragon\AppData\Local\UnrealBuildTool\Log_UHT.txt” -installed
2>LogInit: Display: Loading text-based GConfig…
2>Reflection code generated for Building_Escape in 4.2932966 seconds
2>Building Building_Escape…
2>Using Visual Studio 2019 14.29.30133 toolchain (C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.29.30133) and Windows 10.0.19041.0 SDK (C:\Program Files (x86)\Windows Kits\10).
2>Building 16 actions with 4 processes…
2> [1/16] Default.rc2
2> [2/16] SharedPCH.Engine.ShadowErrors.cpp
2> [3/16] PickUpManager.cpp
2> [4/16] Building_Escape.cpp
2> [5/16] Grabber.gen.cpp
2> [6/16] Grabber.cpp
2> [7/16] OpenDoor.gen.cpp
2> [8/16] WorldPosition.cpp
2> [9/16] Building_EscapeGameModeBase.cpp
2> [10/16] OpenDoor.cpp
2> [11/16] WorldPosition.gen.cpp
2> [12/16] PickUpManager.gen.cpp
2> [13/16] Building_EscapeGameModeBase.gen.cpp
2> [14/16] Building_Escape.init.gen.cpp
2> [15/16] Building_Escape.exe
2> Creating library F:\Unreal Projects\Building_Escape\Binaries\Win64\Building_Escape.lib and object F:\Unreal Projects\Building_Escape\Binaries\Win64\Building_Escape.exp
2> [16/16] Building_Escape.target
2>Total time in Parallel executor: 42.83 seconds
2>Total execution time: 49.30 seconds
========== Build: 1 succeeded, 0 failed, 0 up-to-date, 1 skipped ==========

Try removing the binaries and intermediate folders and then double-click the uproject file.

YAY It opened without crashing. Thanks for your help!

1 Like

You are most welcome. Glad this worked.

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.

Privacy & Terms