# Attach Event Instance to object without rigid body

**URL:** https://qa.fmod.com/t/attach-event-instance-to-object-without-rigid-body/17185
**Category:** Unity
**Created:** [May 11, 2021, 4:16pm UTC](https://qa.fmod.com/t/attach-event-instance-to-object-without-rigid-body/17185 "2021-05-11T16:16:14Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![CrisPDS](https://avatars.discourse-cdn.com/v4/letter/c/ccd318/32.png) [@CrisPDS](https://qa.fmod.com/u/CrisPDS)
#### Post date: [May 11, 2021, 4:16pm UTC](https://qa.fmod.com/t/attach-event-instance-to-object-without-rigid-body/17185/1 "2021-05-11T16:16:14Z")

</div>

Hi there,

I would like to have some 3D event instances playing in some parts of the environment, and I need to use event instances instead of the event emitter component, since I have one script that needs to play different events (as far as I know the emitter component can only play one event, right?).

However the function AttachInstanceToGameObject takes a RigiBody or RigidBody2D, can I pass NULL if I am not using a rigid body? or there are any alternatives?

Many thanks

---

<div class="post-metadata">

### Author: ![CrisPDS](https://avatars.discourse-cdn.com/v4/letter/c/ccd318/32.png) [@CrisPDS](https://qa.fmod.com/u/CrisPDS)
#### Post date: [May 12, 2021, 10:54am UTC](https://qa.fmod.com/t/attach-event-instance-to-object-without-rigid-body/17185/2 "2021-05-12T10:54:20Z")

</div>

It would be great to have some light on this. On my side I’ve tried to pass a null RigidBody and it works just fine.

---

<div class="post-metadata">

### Author: ![richard\_simms](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/richard_simms/32/261_2.png) [@richard\_simms](https://qa.fmod.com/u/richard_simms)
#### Post date: [May 18, 2021, 2:36am UTC](https://qa.fmod.com/t/attach-event-instance-to-object-without-rigid-body/17185/3 "2021-05-18T02:36:38Z")

</div>

The `AttachInstanceToGameObject` function is overloaded with three possible parameters - Rigidbody, 2DRigidbody, and indeed no Rigidbody. You don’t need to pass any rigidbody and it should work fine.

---

<div class="post-metadata">

### Author: ![CrisPDS](https://avatars.discourse-cdn.com/v4/letter/c/ccd318/32.png) [@CrisPDS](https://qa.fmod.com/u/CrisPDS)
#### Post date: [May 18, 2021, 9:02am UTC](https://qa.fmod.com/t/attach-event-instance-to-object-without-rigid-body/17185/4 "2021-05-18T09:02:13Z")

</div>

Thanks for your answer. Perhaps I don’t have the latest version, in my case if I don’t pass anything I get an error. I’ll update to the latest version and try it again.  
Thanks for the explanation 🙂
