C++ Blueprint Event with Parameter

Add const keyword. Maybe it’s a reason.

UFUNCTION(BlueprintImplementableEvent, Category = "GlobalEvents")
void SpawnLevelActor(const FString &ClassName);

Hi, i want to make a simple event in C++ that can be used in a blueprint like the “Mouse X” event that have the “Axis Value” parameter.
I work in version 4.6.1


I’ve tried many variations of UFUNCTION(BlueprintImplementableEvent) or UFUNCTION(BlueprintNativeEvent)
but non if my tryouts have worked - The event is not visible in my blueprint

If i do something like that, without a parameter, it works and i can find it in the blueprint.

UFUNCTION(BlueprintImplementableEvent, Category = "GlobalEvents")
void SpawnLevelActor();


If i change it to something like that it is not visible in the blueprint anymore.
I want it to be a real event node, not a function.

UFUNCTION(BlueprintImplementableEvent, Category = "GlobalEvents")
void SpawnLevelActor(FString &ClassName);

My goal is generally:
I want firing an event from c++ and passing some parameters to it - In a blueprint i want do something when this event has been fired, include the use of the parameters that i’ve passed from c++.
Maybe my general understanding of how i should make it is wrong - Any help would be much appreciated.

Second time i feel dumb :slight_smile: Thx, it works exactly as it should. I everytime came across such simple mistakes - Have you maybe a good documentiation where i can find such things with example code. I came from unity and they have a very good documentation with many example code, for unreal i didn’t found anything similar except the API documentation, without example code.

Thx. I also already found this platform, i guess i need a bit more time to know where to find things.

I’m using this link, to search for answers: https://docs.unrealengine.com/latest/INT/Search/index.html
Forums and AnswerHub is a good place to start searching.
Wiki also have code examples: A new, community-hosted Unreal Engine Wiki - Announcements - Unreal Engine Forums