# Why can't we have 2 different wildcard types in a Macro?

**URL:** <https://forums.unrealengine.com/t/why-cant-we-have-2-different-wildcard-types-in-a-macro/603517>\
**Category:** Blueprint\
**Tags:** unreal-engine, UE5-0, Blueprint, question\
**Created:** [July 13, 2022, 12:28am UTC](https://forums.unrealengine.com/t/why-cant-we-have-2-different-wildcard-types-in-a-macro/603517 "2022-07-13T00:28:43Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![HappyKat100](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@HappyKat100](https://forums.unrealengine.com/u/HappyKat100)\
**Post date:** [July 13, 2022, 12:28am UTC](https://forums.unrealengine.com/t/why-cant-we-have-2-different-wildcard-types-in-a-macro/603517/1 "2022-07-13T00:28:43Z")

</div>

Hi - I’m trying to write a Macro in a Macro Library that has 2 wildcard inputs. I want each to be unique depending on what I plug in, however whatever I plug into the first wildcard, also changes the second wildcard (and visa versa) to that same type. Can I not have two different wildcard types?

Let’s say I want my ‘Object To Rotate’ to be a Capsule Component and my ‘Target Object’ to be a Static Mesh, why doesn’t this work? Right now, if I plug the Capsule Component into Object To Rotate then the Target Object changes to the Capsule Component type too??!?

How do I solve this?

![image](https://d3kjluh73b9h9o.cloudfront.net/original/4X/7/2/8/72829f7dbb3b5bbb134f8ee1b369a5199578802e.png)

---

<div class="post-metadata">

**Author:** ![Roy\_Wierer.Seda145](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/roy_wierer.seda145/32/906551_2.png) [@Roy\_Wierer.Seda145](https://forums.unrealengine.com/u/Roy_Wierer.Seda145)\
**Post date:** [July 13, 2022, 12:33am UTC](https://forums.unrealengine.com/t/why-cant-we-have-2-different-wildcard-types-in-a-macro/603517/2 "2022-07-13T00:33:03Z")

</div>

That is odd… Haven’t encountered this before but it sure does not sound intentional.  
Option B is to set TargetObject to a class deriving from UObject? In your case a type of UPrimitiveComponent sounds OK because it works with static, skeletal meshes and shapes like UCapsuleComponent.

- Macros should also be avoided when possible. I use the inheritance hierarchy pages in the docs to figure out what parent class I can use for these situations:  
[UCapsuleComponent | Unreal Engine Documentation](https://docs.unrealengine.com/4.27/en-US/API/Runtime/Engine/Components/UCapsuleComponent/)

---

<div class="post-metadata">

**Author:** ![HappyKat100](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@HappyKat100](https://forums.unrealengine.com/u/HappyKat100)\
**Post date:** [July 13, 2022, 2:35am UTC](https://forums.unrealengine.com/t/why-cant-we-have-2-different-wildcard-types-in-a-macro/603517/3 "2022-07-13T02:35:23Z")

</div>

Thank you! Using Primitive component worked a treat!

---

<div class="post-metadata">

**Author:** ![jerry7](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@jerry7](https://forums.unrealengine.com/u/jerry7)\
**Post date:** [October 31, 2023, 10:35am UTC](https://forums.unrealengine.com/t/why-cant-we-have-2-different-wildcard-types-in-a-macro/603517/4 "2023-10-31T10:35:33Z")

</div>

I have same problem.  
I have two different array type (int and float array), but I can’t plug them into pins at same time.

Anyone knows how to solve it?  
Thanks!

---

<div class="post-metadata">

**Author:** ![medwil](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@medwil](https://forums.unrealengine.com/u/medwil)\
**Post date:** [September 12, 2024, 4:53pm UTC](https://forums.unrealengine.com/t/why-cant-we-have-2-different-wildcard-types-in-a-macro/603517/5 "2024-09-12T16:53:25Z")

</div>

I have the same problem. This bug defeats the purpose of mathematical macros in most cases for me.  
 ![image](https://d3kjluh73b9h9o.cloudfront.net/original/4X/c/4/d/c4db2d8bbb173c883e6a18823dc384bb0c7f316a.png)

 ![image](https://d3kjluh73b9h9o.cloudfront.net/original/4X/7/2/a/72a393ee484df7866eb0e6f0d16c66d029d9ca56.png)

---

<div class="post-metadata">

**Author:** ![Reahreic](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/reahreic/32/911691_2.png) [@Reahreic](https://forums.unrealengine.com/u/Reahreic)\
**Post date:** [October 28, 2025, 11:56am UTC](https://forums.unrealengine.com/t/why-cant-we-have-2-different-wildcard-types-in-a-macro/603517/6 "2025-10-28T11:56:57Z")

</div>

The only solution I’ve come up with is to abandon BP macros and use C++ Blueprint Function Libraries with custom thunks instead. Which is a whole other can of poorly documented worms.
