# \[CPP\] Why doesn't my Broadcast work / Why the delegate is not being called?

**URL:** <https://forums.unrealengine.com/t/cpp-why-doesnt-my-broadcast-work-why-the-delegate-is-not-being-called/1910136>\
**Category:** C++\
**Tags:** event-dispatcher, unreal-engine, question\
**Created:** [June 20, 2024, 11:30am UTC](https://forums.unrealengine.com/t/cpp-why-doesnt-my-broadcast-work-why-the-delegate-is-not-being-called/1910136 "2024-06-20T11:30:56Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![blAddddDe](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@blAddddDe](https://forums.unrealengine.com/u/blAddddDe)\
**Post date:** [June 20, 2024, 11:30am UTC](https://forums.unrealengine.com/t/cpp-why-doesnt-my-broadcast-work-why-the-delegate-is-not-being-called/1910136/1 "2024-06-20T11:30:56Z")

</div>

### There's a delegate:

 ![image](https://d3kjluh73b9h9o.cloudfront.net/original/4X/d/f/3/df33f04a4b4bc4876d5a0b25527a42ca87b1d259.png)

#### I add a function to it in another actor:

 ![image](https://d3kjluh73b9h9o.cloudfront.net/original/4X/b/9/4/b947c411cb1128ad0b69c19c8bf789563dc47933.png)

#### And call it accordingly (the call is made from the component in which the delegate was declared).

 ![image](https://d3kjluh73b9h9o.cloudfront.net/original/4X/d/a/4/da46fa0795e5612816a07e2c1678e239e464b57c.png)

but when this delegate is called, the `UpdateWorldMarker` function is not called

## thx for help

---

<div class="post-metadata">

**Author:** ![gh0stfase1](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/gh0stfase1/32/1194639_2.png) [@gh0stfase1](https://forums.unrealengine.com/u/gh0stfase1)\
**Post date:** [June 20, 2024, 2:03pm UTC](https://forums.unrealengine.com/t/cpp-why-doesnt-my-broadcast-work-why-the-delegate-is-not-being-called/1910136/2 "2024-06-20T14:03:40Z")

</div>

Are you certain that you’re falling into the block of code where AddDynamic is executing?

---

<div class="post-metadata">

**Author:** ![blAddddDe](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@blAddddDe](https://forums.unrealengine.com/u/blAddddDe)\
**Post date:** [June 20, 2024, 2:16pm UTC](https://forums.unrealengine.com/t/cpp-why-doesnt-my-broadcast-work-why-the-delegate-is-not-being-called/1910136/3 "2024-06-20T14:16:50Z")

</div>

![image](https://d3kjluh73b9h9o.cloudfront.net/original/4X/0/9/4/094865e468896d83fda786d9a94cb4de28d5fe88.png)  
 ![image](https://d3kjluh73b9h9o.cloudfront.net/original/4X/b/4/5/b4542ccc9287d7b865f72e87056dfeb718b7de57.png)

But, i have message in the log:  
`[2024.06.20-14.13.39:564][397]LogOutputDevice: Error: Ensure condition failed: this->IsBound() [File:D:\UE_4.27\Engine\Source\Runtime\Core\Public\Delegates/DelegateSignatureImpl.inl] [Line: 1028]`

---

<div class="post-metadata">

**Author:** ![blAddddDe](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@blAddddDe](https://forums.unrealengine.com/u/blAddddDe)\
**Post date:** [June 20, 2024, 2:50pm UTC](https://forums.unrealengine.com/t/cpp-why-doesnt-my-broadcast-work-why-the-delegate-is-not-being-called/1910136/4 "2024-06-20T14:50:32Z")

</div>

I understand. A very stupid mistake.

## Header file before:

```auto
protected:
	virtual void BeginPlay() override;

	void UpdateWorldMarker(FName QuestID, FQuestData QuestData);

```

## Header file after:

```auto
protected:
	virtual void BeginPlay() override;
       
    UFUNCTION()
	void UpdateWorldMarker(FName QuestID, FQuestData QuestData);

```

I forgot that DYNAMIC\_MULTICAST delegates must have functions labeled UFUNCTION().  
😅

Thanks for help.

---

<div class="post-metadata">

**Author:** ![gh0stfase1](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/gh0stfase1/32/1194639_2.png) [@gh0stfase1](https://forums.unrealengine.com/u/gh0stfase1)\
**Post date:** [June 20, 2024, 3:00pm UTC](https://forums.unrealengine.com/t/cpp-why-doesnt-my-broadcast-work-why-the-delegate-is-not-being-called/1910136/5 "2024-06-20T15:00:33Z")

</div>

Nice work. Dang UFUNCTION gets you every time.

---

<div class="post-metadata">

**Author:** ![blAddddDe](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@blAddddDe](https://forums.unrealengine.com/u/blAddddDe)\
**Post date:** [June 20, 2024, 7:05pm UTC](https://forums.unrealengine.com/t/cpp-why-doesnt-my-broadcast-work-why-the-delegate-is-not-being-called/1910136/6 "2024-06-20T19:05:16Z")

</div>

That’s right 🥲

---

<div class="post-metadata">

**Author:** ![system](https://d3kjluh73b9h9o.cloudfront.net/original/4X/7/1/3/713c9d3f58553f0de89543d76a8a3a2779dc9fa4.png) [@system](https://forums.unrealengine.com/u/system)\
**Post date:** [July 20, 2024, 7:05pm UTC](https://forums.unrealengine.com/t/cpp-why-doesnt-my-broadcast-work-why-the-delegate-is-not-being-called/1910136/7 "2024-07-20T19:05:35Z")

</div>

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