Forum rules - please read before posting.

Dialogue with Sound



  • Thanks for the info.  I will let you know if I need more.
  • edited April 2016
    The warning you're getting is just due to your having a duplicated player prefab in both scenes, and should be expected.

    As for the main issue, I'm not able to recreate it.  Could it be due to your connection to git?

    If, after the audio connections are broken, you re-make a connection and try again, is it lost once again or is it then retained?

    The audio files ought to be re-connected in SpeechManager’s RestoreTranslation function after the text-gathering process.  Try putting a Debug.Log in there to check that it's being successfully run, e.g.:

    if (line.customAudioClip != null)
      Debug.Log ("Restore audio file: " + + " to line " + line.lineID);
      Debug.Log ("No audio file for line " + line.lineID);

    Try placing that just before the break; and re-gather your text.  Do the logs appear in the console?
  • I did what you told me with the following result:

    Some lines have customAudioClip != null and are assigned properly is suppose.
    Some lines have customAudioClip == null which result in the else case.

    I did some modification but I have no clue what is the difference between the lines which are restored and the others...

    The only thing i did find out is that the lines which are broken are in both scenes, in dialogues in actionList files. I can't see any pattern here...
  • Again, what if you re-gather after fixing a connection?  Also, is git perhaps contributing to this?

    Assuming you put this just before the break;, then that would suggest the customAudioClip variable of the tempLine is also null.  The tempLines are created in the function below: BackupTranslations().  Try running another Debug.Log in that function to see if they are being correctly assigned their customAudioClip fields in the first place.  Something like this just after the tempLines.Add:

    if (line.customAudioClip != null) Debug.Log ("Backed up line " + line.lineID + ", with audio clip: " +;
  • Sorry for the late answer I was buzy the last days, I added the code line but every single audio seems to be backuped.

    The problem seems GIT related, because if i Gather texts Unity will continue to display the right audio files at any state. GIT on the other hand looks directly into the files and for any reason the SpeechManager has lost all connections on file level. Never the less while Unity is running in the memory there seem to be the right connections at any point. If you close Unity (and save your project) or just save it. It will write the state (with connections) back to the SpeechManager file.

    This is only a issue if you Gather Texts and directly commit to a GIT repository without any further action in Unity. If you want we can call me on Skype and I can show you via desktop sharing if you can't reproduce this behavior
  • edited May 2016
    No need for a share, I understand OK.  However, if it's GIT related, I'm not sure what can be done on the AC side of things.  This could be more to do with Unity than anything, though if you have a suggestion I'm all ears.
  • Yes I understand that this is mainly not in your hands... now that I understand that there is a problem it is not a problem anymore... just don't commit right after gathering texts ;)
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.