attempting to reference a deleted function error while compiling c++

Warning: Starting HotReload took  0.2s.
CompilerResultsLog: New page: Compilation - 2018. márc. 31. 0:24:33
CompilerResultsLog: Creating makefile for hot reloading FPSTemplate (.uproject file is newer)
CompilerResultsLog: Compiling game modules for hot reload
CompilerResultsLog: Performing 3 actions (4 in parallel)
CompilerResultsLog: Module.FPSTemplate.gen.cpp
CompilerResultsLog: Error: C:\Program Files\Epic Games\UE_4.19\Engine\Source\Runtime\CoreUObject\Public\UObject/Class.h(671) : error C2280: 'FSurfaceTypeProperties &FSurfaceTypeProperties::operator =(const FSurfaceTypeProperties &)': attempting to reference a deleted function
CompilerResultsLog: Error: E:\UnrealProjects\deletethis\FPSTemplate\Source\FPSTemplate\BaseSingleton.h(28) : note: compiler has generated 'FSurfaceTypeProperties::operator =' here
CompilerResultsLog: Error: C:\Program Files\Epic Games\UE_4.19\Engine\Source\Runtime\CoreUObject\Public\UObject/Class.h(1020) : note: see reference to function template instantiation 'bool CopyOrNot<CPPSTRUCT>(CPPSTRUCT *,const CPPSTRUCT *,int32)' being compiled
CompilerResultsLog:         with
CompilerResultsLog:             CPPSTRUCT=FSurfaceTypeProperties
CompilerResultsLog:         ]
CompilerResultsLog: Error: C:\Program Files\Epic Games\UE_4.19\Engine\Source\Runtime\CoreUObject\Public\UObject/Class.h(1019) : note: while compiling class template member function 'bool UScriptStruct::TCppStructOps<FSurfaceTypeProperties>::Copy(void *,const void *,int32)'
CompilerResultsLog: Error: E:\UnrealProjects\deletethis\FPSTemplate\Intermediate\Build\Win64\UE4Editor\Inc\FPSTemplate\BaseSingleton.gen.cpp(41) : note: see reference to class template instantiation 'UScriptStruct::TCppStructOps<FSurfaceTypeProperties>' being compiled
CompilerResultsLog: Error: E:\UnrealProjects\deletethis\FPSTemplate\Source\FPSTemplate\BaseSingleton.h(28) : note: 'FSurfaceTypeProperties &FSurfaceTypeProperties::operator =(const FSurfaceTypeProperties &)': function was implicitly deleted because a data member 'FSurfaceTypeProperties::KnifeDecal' has either no appropriate copy assignment operator or overlo
ad resolution was ambiguous
CompilerResultsLog: Error: E:\UnrealProjects\deletethis\FPSTemplate\Source\FPSTemplate\BaseSingleton.h(27) : note: see declaration of 'FSurfaceTypeProperties::KnifeDecal'
CompilerResultsLog: ERROR: UBT ERROR: Failed to produce item: E:\UnrealProjects\deletethis\FPSTemplate\Binaries\Win64\UE4Editor-FPSTemplate-6418.dll
CompilerResultsLog: Total build time: 63,39 seconds (Local executor: 0,00 seconds)
LogMainFrame: MainFrame: Module compiling took 63.875 seconds
Warning: HotReload failed, recompile failed

The project was working in ue4.15 but I wanted to upgrade to 4.19.
I’m using a template with a fairly large amount of code. Tried to change things while got some error messages. Now in VS I get only error in Class.h wich is outside the template project.
The odd thing sometimes VS shows 3 error message and other time it shows 3000+ errors but I don’t change anything.

Maybe someone could be a true wizard hero and save me :slight_smile: