I’m trying to add a new actor, inheriting from a class called ABaseNineSliceActor. I already have 10 or so other classes inheriting from this class just fine.
In the new class, called AFixedWindow, I’m trying to define the constructor, so I can initialize the components it needs. Basic stuff. However, for an unknown reason I’m now getting a link error stating that the constructor has already been defined. It must be in the generated code, since there are no other mentions of the class name in the solution. I get the same problem when I make a new empty class with a different name - I’m at a loss here.
I attempted just leaving the constructor for what it is and creating the component at runtime using NewObject<>, RegisterComponent() and AttachComponent(), but querying the component in a subsequent call throws an access violation (even IsValid() throws an access violation, kind of defeating its point).
.h:
#pragma once
#include "BaseNineSliceActor.h"
#include "FixedWindow.generated.h"
UCLASS()
class PROJECT_API AFixedWindow : public ABaseNineSliceActor
{
GENERATED_BODY()
public:
AFixedWindow();
}
.cpp:
#include "Project.h"
#include "FixedWindow.h"
AFixedWindow::AFixedWindow()
{
}
So… help?