Exemplo n.º 1
0
        /// <summary> 
        /// Returns the total height to draw the blackboard variables.
        /// <param name="blackboard">The target blackboard to calculate the height.</param> 
        /// <returns>The required height to draw all variables in the blackboard.</returns> 
        /// </summary>
        public static float GetHeight (InternalBlackboard blackboard) {
            if (blackboard == null)
                return 0f;

            float height =    blackboard.GetFloatsSize() * c_OneLineHeight 
                            + blackboard.GetIntsSize() * c_OneLineHeight
                            + blackboard.GetBoolsSize() * c_OneLineHeight
                            + blackboard.GetStringsSize() * c_OneLineHeight
                            + blackboard.GetVector3sSize() * c_OneLineHeight
                            + blackboard.GetRectsSize() * c_TwoLinesHeight
                            + blackboard.GetColorsSize() * c_OneLineHeight
                            + blackboard.GetQuaternionsSize() * c_OneLineHeight
                            + blackboard.GetGameObjectsSize() * c_OneLineHeight
                            + blackboard.GetTexturesSize() * c_OneLineHeight
                            + blackboard.GetMaterialsSize() * c_OneLineHeight
                            + blackboard.GetObjectsSize() * c_TwoLinesHeight
                            + blackboard.GetDynamicListsSize() * c_OneLineHeight
                            + blackboard.GetFsmEventsSize() * c_OneLineHeight;
            return height;
        }