Compiling issue with Toon Tanks

Hello

I’m currently busy with the Toon Tanks section of the Unreal C++ course. I’m in a section where I click on the Tank Pawn to open a separate window and it keeps giving me compiler issues at the bottom and I’m not sure why or what to do to fix it. Any ideas?

Also, in the same window, I accidentally closed the viewport, how to I get it back?

Thank you.





Could you copy and paste the full error message please?

Hi

That’s the thing, when I compile from VS Code, it says compile complete but when I double click on the Pawn Tank by itself and the separate window appears, it gives me these compiler errors at the bottom in red. I’m not sure what to do about it.

It says Internal Compiler error and it won’t let me select anything in the viewport. I hope that makes sense.



That sounds like you have blueprint components of the same name before compiling. You should delete the blueprint ones first.

Okay, the error messages have disappeared but it still won’t let me select the Spring Arm or Camera component in the viewport. The viewport just flashes orange when I try to select it.

If you create a new blueprint, does it work as you expect?

I seem to have accidentally deleted my Tank Pawn blueprint class. Is there anyway to get that back or will I have to start over again?

It was where I circled it but I pressed force quit by mistake.

You may find an autosave within the Saved folder.

Hi

So I got the Pawn Tank back but I’m still having an issue. If I select the Spring Arm to adjust the angle (As is demonstrated in the video) It still won’t do anything. The details aren’t there either and everything from VS Code has compiled. I don’t have any error messages either. Did I miss something somewhere?

Thank you


It’s an odd bug. Often commenting out the UPROPERTY, compiling, uncommenting, compiling; fixes that.

I’ve just tried it. Didn’t seem to work.

Would you mind sending me your project using the following link?

https://gdev.tv/projectupload

Please use File > Package Project > Zip Up Project within Unreal as this will ensure only required files are zipped up and things like the Binaries are excluded.

Hi

Yeah, will do.

Hello @DanM

Did you manage to take a look at the project regarding the camera and spring arm not selecting?

Thank you

Sorry, I don’t get a notification when the file gets uploaded so I just forgot about this.

I’ve just tried some things now and commenting out the components compiling, uncommenting and compiling, seemed to work.

For clarity, the following is what I commented out

// PROPERTY(VisibleAnywhere, BlueprintReadOnly, Category = "Components", meta = (AllowPrivateAccess = "true"))
// USpringArmComponent *SpringArm;
// UPROPERTY(VisibleAnywhere, BlueprintReadOnly, Category = "Components", meta = (AllowPrivateAccess = "true"))
// UCameraComponent *Camera;


APawnTank::APawnTank()
{
//    SpringArm = CreateDefaultSubobject<USpringArmComponent>(TEXT("Spring Arm"));
//    SpringArm->SetupAttachment(RootComponent);

//    Camera = CreateDefaultSubobject<UCameraComponent>(TEXT("Camera"));
//    Camera->SetupAttachment(SpringArm);
}

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

Privacy & Terms