상속: SSTUFieldManipulationData
예제 #1
0
        public static SSTUFieldManipulationData createNew(ConfigNode node, PartModule module)
        {
            SSTUFieldManipulationData fieldData;
            FieldType type;

            type = (FieldType)Enum.Parse(typeof(FieldType), node.GetStringValue("fieldType", "field"), true);
            switch (type)
            {
            case FieldType.FIELD:
                fieldData = new SSTUFieldData(node, module);
                break;

            case FieldType.EVENT:
                fieldData = new SSTUEventData(node, module);
                break;

            case FieldType.ACTION:
                fieldData = new SSTUActionData(node, module);
                break;

            default:
                fieldData = new SSTUFieldData(node, module);
                break;
            }
            return(fieldData);
        }
예제 #2
0
 public static SSTUFieldManipulationData createNew(ConfigNode node, PartModule module)
 {
     SSTUFieldManipulationData fieldData;
     FieldType type;
     type = (FieldType)Enum.Parse(typeof(FieldType), node.GetStringValue("fieldType", "field"), true);
     switch (type)
     {
         case FieldType.FIELD:
             fieldData = new SSTUFieldData(node, module);
             break;
         case FieldType.EVENT:
             fieldData = new SSTUEventData(node, module);
             break;
         case FieldType.ACTION:
             fieldData = new SSTUActionData(node, module);
             break;
         default:
             fieldData = new SSTUFieldData(node, module);
             break;
     }
     return fieldData;
 }