top | item 37018809 (no title) netheril96 | 2 years ago I think the point of header generation is not to save compilation time, but to save developer time. Saving them from writing the same thing twice, in header and in implementation. discuss order hn newest maccard|2 years ago It's not that sort of header generation, it's a straight up code generator. You can write #include "MyClass.gen.h" UCLASS() class UMyClass : public UObject { GENERATED_BODY() public: UPROPERTY(BlueprintReadWrite, EditAnywhere ) float MyFloat = 1.f; UPROPERTY() APlayerController* MyPc; }; in a header, and you get garbage collection, serialisation, script binding, editor UI out of the generated code. 8n4vidtmkvmk|2 years ago Exactly this. I already have to wait 3 to 10 minutes for compiles. Can't imagine header generation will add substantially more.
maccard|2 years ago It's not that sort of header generation, it's a straight up code generator. You can write #include "MyClass.gen.h" UCLASS() class UMyClass : public UObject { GENERATED_BODY() public: UPROPERTY(BlueprintReadWrite, EditAnywhere ) float MyFloat = 1.f; UPROPERTY() APlayerController* MyPc; }; in a header, and you get garbage collection, serialisation, script binding, editor UI out of the generated code.
8n4vidtmkvmk|2 years ago Exactly this. I already have to wait 3 to 10 minutes for compiles. Can't imagine header generation will add substantially more.
maccard|2 years ago
8n4vidtmkvmk|2 years ago