Ejemplo n.º 1
0
 public void CompleteVariableSetup(float previousVariableHeight)
 {
     spawnHeight += previousVariableHeight;
     if (variableGeneratorSourceType == VariableGeneratorSourceType.Component)
     {
         if (propertyCount > 0 && !propertyListComplete)
         {
             if (currentProperty < propertyCount - 1)
             {
                 currentProperty++;
                 rComponent.NextVariable(0, currentProperty, true, 0);
             }
             else
             {
                 propertyListComplete = true;
                 CompleteVariableSetup(0);
             }
         }
         else if (fieldCount > 0 && !fieldListComplete)
         {
             if (currentField < fieldCount - 1)
             {
                 currentField++;
                 rComponent.NextVariable(1, currentField, true, 0);
             }
             else
             {
                 fieldListComplete = true;
                 CompleteVariableSetup(0);
             }
         }
         else
         {
             spawnHeight          += 2; //add space for bottom line
             contentRect.sizeDelta = new Vector2(contentRect.sizeDelta.x, spawnHeight);
             if (variableGeneratorSourceType == VariableGeneratorSourceType.Component)
             {
                 rComponent.CompleteComponentSetup(spawnHeight);
             }
         }
     }
 }