From 5c8f5f4214ddf73938b08411b2e75d19ca13c3f7 Mon Sep 17 00:00:00 2001 From: Christopher Date: Thu, 15 Sep 2016 15:33:58 +0100 Subject: [PATCH] Fixed Flowchart component being hidden by accident. --- Assets/Fungus/Flowchart/Scripts/Flowchart.cs | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/Assets/Fungus/Flowchart/Scripts/Flowchart.cs b/Assets/Fungus/Flowchart/Scripts/Flowchart.cs index 4dc6d5a9..aff19c12 100644 --- a/Assets/Fungus/Flowchart/Scripts/Flowchart.cs +++ b/Assets/Fungus/Flowchart/Scripts/Flowchart.cs @@ -871,15 +871,13 @@ namespace Fungus { if (hideComponents) { - IBlock[] blocks = GetComponents(); - foreach (IBlock block in blocks) + Block[] blocks = GetComponents(); + foreach (Block block in blocks) { - GameObject go = ((Block)block).gameObject; - - go.hideFlags = HideFlags.HideInInspector; - if (go != gameObject) + block.hideFlags = HideFlags.HideInInspector; + if (block.gameObject != gameObject) { - go.hideFlags = HideFlags.HideInHierarchy; + block.hideFlags = HideFlags.HideInHierarchy; } }