enum class CurrentTileType : char
{
NONE,
BLOCKING_TILE,
STRONG_BLOCKING_TILE,
GROUPED_BLOCKING_TILE
};
UCLASS()
class PROJECTTAP_API ATilesManager : public AActor
{
GENERATED_BODY()
TArray<class ABlockingTile*> activatedBlocks;
TArray<class AGroupedBlockingTile*> activatedGroupedBlocks;
class AStrongBlockingTile* prevStrongBlockingTile;
bool isMousePressed = false;
unsigned char size_limit{ 3 };
unsigned char grouped_size_limit{ 6 };
CurrentTileType currentTileType{ CurrentTileType::NONE };
void UpdateGroupedBlockingTiles();
void SetBlockingTileCurrent();
void SetStrongBlockingTileCurrent();
void SetGroupedBlockingTileCurrent();
void DeactivateBlockingTiles();
void DeactivateGroupedBlockingTiles();
public:
void AddTile(ABlockingTile* tile);
void AddTile(AStrongBlockingTile* tile);
void AddTile(AGroupedBlockingTile* tile);
void DeactivateStrongBlockingTile();
void SetEnableSwipeCheck(bool b);
// Sets default values for this actor's properties
ATilesManager();
// Called when the game starts or when spawned
virtual void BeginPlay() override;
// Called every frame
virtual void Tick( float DeltaSeconds ) override;
};
I’m mostly sure it’s some code in the class above that’s causing the problem.
vs2013 crashes in the following place when I try to launch the editor with F5
UObject::UObject()
{
FObjectInitializer* ObjectInitializerPtr = FTlsObjectInitializers::Top();
UE_CLOG(!ObjectInitializerPtr, LogUObjectGlobals, Fatal, TEXT("%s is not being constructed with either NewObject, NewNamedObject or ConstructObject."), *GetName());
FObjectInitializer& ObjectInitializer = *ObjectInitializerPtr;
check(!ObjectInitializer.Obj || ObjectInitializer.Obj == this);//crashes
const_cast<FObjectInitializer&>(ObjectInitializer).Obj = this;
const_cast<FObjectInitializer&>(ObjectInitializer).FinalizeSubobjectClassInitialization();
}