Forum rules - please read before posting.

Running "In Scene" ActionLists from an ActionList Asset deletes default values

edited November 2021 in Engine development

I just investigated an error in my game and found out that if you run an ActionList from an ActionList Asset, the default values for parameters that are specified in the ActionList to run get deleted.

To be more specific: I have an ActionList Asset called "Cutscene_Divider" that has a parameter "Next Cutscene" which runs the ActionList specified as a parameter. I use this to control where to go next if the player skips a cutscene when several cutscenes are played in a cue. I use to specify characters as parameters in cutscenes, but if the cutscene is run by the "Cutscene_Divider" ActionList all those paramters are cleared and no characters speak, walk, etc anymore.

I basically could use a workaround by using "ActionList: Set parameter" with "Change own?" set in all the cutscenes, but I don't think this is the intended way to do this. Setting default values for ActionList parameters is a powerful feature that I use extensively throughout the project.

PS: Forgot to say: Unity 2018.4.36f1, AC 1.74.2


  • edited November 2021

    Thanks for the report, I will attempt a recreation.

    Is it your intent for "Cutscene_Divider" to pass on its parameters to "Next Cutscene", or otherwise how are "Next Cutscene"'s parameters intended to be set?

    Can you share some screenshots to show the way these ActionLists are set up and being called? When the "Next Cutscene" parameter is used in the ActionList: Run Action, what is the Action's Run mode set to?

  • Ok, this is what I do:
    I call the "Cutscene_Divider" ActionList Asset from a cutscene that is in my scene with the next cuscene to run as a parameter:

    This is the "Cutscene_Divider" ActionList Asset:

    This is the cutscene (in scene) that is called by the "Cutscene_Divider" ActionList:

    The problem here is that the pre-defined parameters (Cotenachere, Dr.M and Techniker) of this cutscene got overwritten with null (or emptied so to say) and the cutscene does not work anymore. You can't set parameters when using the "ActionList: Run" Action from within a ActionList Asset, so I would guess the parameters should not be emptied.

  • Thanks for the details.

    You can't set parameters when using the "ActionList: Run" Action from within a ActionList Asset

    Normally, you can. When the ActionList it references is itself a parameter, however, it cannot provide parameter fields because they're unknown.

    I suspect this is a case of the Action's UI not matching the behaviour. If you temporarily unassign the "Next Cutscene" parameter from Cutscene_Divider's ActionList: Run Action, is its Run mode set to Set Parameters And Run? If so, change it to Run Only, and then re-assign the parameter.

    That should prevent it from modifying the parameters until an official fix.

  • Yes, it works. Thanks for the clue! But unassigning the parameter was not enough, Run Mode was still not showing up. I had to assign a random cutscene, then Run Mode was visible and I could change the value from "Set Parameters And Run?" to "Run Only", then switching back to the parameter and now it is working as intended.

    I remember a point in time where an AC update messed up all ActionList: Run actions by changing the Run Mode from "Run Only" to "Set Parameters And Run?", which caused exactly this: Overwriting default values of ActionList parameters. I had to edit those Actions in the whole project back then. I guess I missed some ActionList Assets and now I am stumbling over it again.

  • In a backup/duplicate, try this alternative to the ActionRunActionList script file - it should resolve the issue without having to change anything:

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.