Forum rules - please read before posting.

Inventory pickup common sound

Hello,

I am lookint into the proper way to have a common sound whenever an item is added to the inventory. is there a way to do that via the AC UI?

Comments

  • You can do this by creating an ActionList asset that uses parameters, which gets run whenever you want to add an item.

    Parameters let you "recycle" commonly-used Actions by changing their fields at runtime - see this tutorial.

    Create a new ActionList asset, and define a single "Inventory item" parameter in its Properties box.  Then, when you create an Inventory: Add or remove Action, you can assign this parameter as the new item to add.  Follow it up with a Sound: Play one-shot to play the sound.

    Then, instead of running a new Inventory: Add or remove Action each time you want to add an item, use an ActionList: Run Action to run this new asset.  In each instance, you'll be able to define the value of the Inventory item parameter - and in turn, the item to be added.  You can use the Actions Manager to search your game for all occurences of a given Action.
  • Hello Chris,

    Sounds good! Thanks for the information that is clear ;)

    Best regards
    Joao Garin
Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Welcome to the official forum for Adventure Creator.