Build error caused by BlueprintCallable - no storage class or type specifier, class UObject has no member BeginPlay/tick

I have a cpp class which, as a protected method has:

	UFUNCTION(BlueprintCallable)
	virtual uint32 generateAllowedTilesReferences();

on building, i receive the following errors:

  • class UObject has no member “BeginPlay”
  • Class UObject has no member “Tick”
  • this declaration has no storage class or specifier

After trial and error, i identified the problem in “BlueprintCallable”.

By removing it, the build process completes with success.

What is happening here ?

Full .h file as reference :

#pragma once

#include "CoreMinimal.h"
#include "GameFramework/Actor.h"
#include "BaseTile.h"

#include "BaseMapGenerator.generated.h"

UCLASS(Blueprintable)
class CPPTEST_API ABaseMapGenerator : public AActor
{
	GENERATED_BODY()
	
public:	
	// Sets default values for this actor's properties
	ABaseMapGenerator();
	
protected:
	// Called when the game starts or when spawned
	virtual void BeginPlay() override;
	UPROPERTY(EditAnywhere, Category = "Map Properties|Setup")
	int size = 8;

	UPROPERTY(EditAnywhere, Category = "Map Properties|Tiling")
	float tilePadding = 0.05;

	UFUNCTION(BlueprintCallable)
	virtual uint32 generateAllowedTilesReferences();

	
public:	
	// Called every frame
	virtual void Tick(float DeltaTime) override;

	UFUNCTION(BlueprintPure)
	FORCEINLINE int getSize() const { return size; }

	UFUNCTION(BlueprintPure)
	FORCEINLINE float getTilePadding() const { return tilePadding; }


};

just for future readers:

the problem was that uint32 is not supported by blueprints.

changing uint32 to int32 solved the issue.