# FMOD Viking Village tutorial - Footsteps script

**URL:** <https://qa.fmod.com/t/fmod-viking-village-tutorial-footsteps-script/14520>\
**Category:** Unity\
**Created:** [April 1, 2019, 11:24pm UTC](https://qa.fmod.com/t/fmod-viking-village-tutorial-footsteps-script/14520 "2019-04-01T23:24:09Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Astrix](https://avatars.discourse-cdn.com/v4/letter/a/8e7dd6/32.png) [@Astrix](https://qa.fmod.com/u/Astrix)\
**Post date:** [April 1, 2019, 11:24pm UTC](https://qa.fmod.com/t/fmod-viking-village-tutorial-footsteps-script/14520/1 "2019-04-01T23:24:10Z")

</div>

Hey guys,

So I am learning FMOD integration with Unity and am working on the Viking Village. I am following this [tutorial](https://www.youtube.com/watch?v=DI72MHPfh0k) and I used the script that was mentioned in the description of the video. I created a new script called Footsteps.cs and copy pasted the script. I just changed the Sand to Grass in the entire script and when i built it, i got the following error;

CS0019 Operator ‘==’ cannot be applied to operands of type ‘ParameterInstance’ and ‘\<null\>’

Here is the line it is referencing to

```
if (m_EventPath != null)

{

FMOD.Studio.EventInstance e = FMODUnity.RuntimeManager.CreateInstance(m_EventPath);

e.set3DAttributes(FMODUnity.RuntimeUtils.To3DAttributes(transform.position));

SetParameter(e, "Wood", m_Wood);

SetParameter(e, "Dirt", m_Dirt);

SetParameter(e, "Grass", m_Grass);

SetParameter(e, "Water", m_Water);

e.start();

e.release();//Release each event instance immediately, there are fire and forget, one-shot instances.

}

}
```

---

<div class="post-metadata">

**Author:** ![Eneco](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/eneco/32/6046_2.png) [@Eneco](https://qa.fmod.com/u/Eneco)\
**Post date:** [April 2, 2019, 1:48pm UTC](https://qa.fmod.com/t/fmod-viking-village-tutorial-footsteps-script/14520/2 "2019-04-02T13:48:55Z")

</div>

Which version of FMOD and the FMOD - Unity integration package are you using?

---

<div class="post-metadata">

**Author:** ![cameron-fmod](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/cameron-fmod/32/261_2.png) [@cameron-fmod](https://qa.fmod.com/u/cameron-fmod)\
**Post date:** [April 7, 2019, 11:34pm UTC](https://qa.fmod.com/t/fmod-viking-village-tutorial-footsteps-script/14520/3 "2019-04-07T23:34:29Z")

</div>

In the Footsteps.cs you will need to edit line 204.

From:

```auto
    if(parameter == null)

```

To:

```auto
    if(!parameter.isValid())

```

---

<div class="post-metadata">

**Author:** ![ellelalala](https://avatars.discourse-cdn.com/v4/letter/e/b9bd4f/32.png) [@ellelalala](https://qa.fmod.com/u/ellelalala)\
**Post date:** [April 13, 2023, 2:07am UTC](https://qa.fmod.com/t/fmod-viking-village-tutorial-footsteps-script/14520/4 "2023-04-13T02:07:46Z")

</div>

How did you get the script into unity? Did you just copy paste it into the Scripts folder?
