diff --git a/Assets/Fungus/Dialog/Editor/ChooseEditor.cs b/Assets/Fungus/Dialog/Editor/ChooseEditor.cs index ce4a94f7..6b58107c 100644 --- a/Assets/Fungus/Dialog/Editor/ChooseEditor.cs +++ b/Assets/Fungus/Dialog/Editor/ChooseEditor.cs @@ -39,8 +39,10 @@ namespace Fungus bool showPortraits = false; // Only show portrait selection if... if (t.character != null && // Character is selected + t.character.portraits != null && // Character has a portraits field t.character.portraits.Count > 0 && // Selected Character has at least 1 portrait - t.chooseDialog.characterImage != null) // Selected Say Dialog has a character image + t.chooseDialog != null && // Say Dialog is selected + t.chooseDialog.characterImage != null) // Selected Say Dialog has a character image e { showPortraits = true; } diff --git a/Assets/Fungus/Dialog/Editor/SayEditor.cs b/Assets/Fungus/Dialog/Editor/SayEditor.cs index 90301dfa..fa2bbcfa 100644 --- a/Assets/Fungus/Dialog/Editor/SayEditor.cs +++ b/Assets/Fungus/Dialog/Editor/SayEditor.cs @@ -60,7 +60,9 @@ namespace Fungus bool showPortraits = false; // Only show portrait selection if... if (t.character != null && // Character is selected + t.character.portraits != null && // Character has a portraits field t.character.portraits.Count > 0 && // Selected Character has at least 1 portrait + t.sayDialog != null && // Say Dialog is selected t.sayDialog.characterImage != null) // Selected Say Dialog has a character image { showPortraits = true;