Strings and USTRUCT

Hey all,

Trying to use a USTRUCT. It seems fine for variables, except when I try to use a FString, FName or Char. Does anyone know if I’m just missing something?

It doesn’t cause a crash, it just gives the error saying it expects a “;”, other variables are working properly.

struct FBodyInformation

		FName limbName; //Says it is expecting ";" here when using FName or FString
		uint32 limbHealth;
		uint32 attackType;



Try initializing those properties from the ctor. Just add the following into the struct:

#if CPP
        FBodyInformation() :

That should do the trick ^^

Hey, thanks for the suggestion. Just got back into the office today to try it but it turns out when adding a Struct I can’t just Compile from within the editor, I have to close the editor and re-compile through Visual Studio.

Yes that is correct, some changes require the editor to fully reload. Those are normally related to types and properties.