void TextureFieldContainerEditor::initMethod(InitPhase ePhase)
{
    Inherited::initMethod(ePhase);

    if(ePhase == TypeObject::SystemPost)
    {
        //Fill in all of the editable types
        UInt32 NumTypes(FieldContainerFactory::the()->getNumTypes());
        UInt32 FoundTypes(0);
        FieldContainerType* type;
        for(UInt32 i(0) ; FoundTypes<NumTypes; ++i)
        {
            type = FieldContainerFactory::the()->findType(i);
            if(type != NULL)
            {
                ++FoundTypes;
                if(type->isDerivedFrom(TextureBaseChunk::getClassType()))
                {
                    _EditableTypes.push_back(type);
                    FieldContainerEditorFactory::the()->setDefaultEditor(type,
                                                                         &getClassType());
                    FieldContainerEditorFactory::the()->setEditorType(type,
                                                                      &getClassType(),
                                                                      "Texture");
                }
            }
        }
    }
}
void GenericMultiFieldEditor::initMethod(InitPhase ePhase)
{
    Inherited::initMethod(ePhase);

    if(ePhase == TypeObject::FactoryPost)
    {
        //Fill in all of the editable types
        UInt32 NumTypes(TypeFactory::the()->getNumTypes());
        DataType* type;
        for(UInt32 i(0) ; i<NumTypes; ++i)
        {
            type = dynamic_cast<DataType*>(TypeFactory::the()->findType(i));
            if(type != NULL &&
                *type != FieldTraits<AttachmentMap>::getType() &&
                *type != FieldTraits<ChangedFunctorCallback>::getType())
            {
                _EditableTypes.push_back(type);
                FieldEditorFactory::the()->setEditorType(type, &getClassType(), "GenericMultiField");
                FieldEditorFactory::the()->setMultiDefaultEditor(type, &getClassType());
            }
        }
        FieldEditorFactory::the()->removeEditorType(&FieldTraits<MaterialMap>::getType(), "GenericMultiField");
        FieldEditorFactory::the()->removeMultiDefaultEditor(&FieldTraits<MaterialMap>::getType());
    }
}
void GenericFieldContainerEditor::initMethod(InitPhase ePhase)
{
    Inherited::initMethod(ePhase);

    if(ePhase == TypeObject::FactoryPost)
    {
        //Fill in all of the editable types
        UInt32 NumTypes(FieldContainerFactory::the()->getNumTypes());
        UInt32 FoundTypes(0);
        FieldContainerType* type;
        for(UInt32 i(0) ; FoundTypes<NumTypes; ++i)
        {
            type = FieldContainerFactory::the()->findType(i);
            if(type != NULL)
            {
                ++FoundTypes;
                _EditableTypes.push_back(type);
                FieldContainerEditorFactory::the()->setEditorType(type, &getClassType(), "Generic");
            }
        }
    }
}
void FCPtrFieldEditor::initMethod(InitPhase ePhase)
{
    Inherited::initMethod(ePhase);

    if(ePhase == TypeObject::FactoryPost)
    {
        //Fill in all of the editable types
        UInt32 NumTypes(TypeFactory::the()->getNumTypes());
        FieldType* type;
        for(UInt32 i(0) ; i<NumTypes; ++i)
        {
            type = dynamic_cast<FieldType*>(TypeFactory::the()->findType(i));
            if(type != NULL &&
               (type->getClass() == FieldType::PtrField ||
               type->getClass() == FieldType::ChildPtrField))
            {
                _EditableTypes.push_back(&type->getContentType());
                FieldEditorFactory::the()->setEditorType(&type->getContentType(), &getClassType(),
                                                         "FieldContainerPtr");
            }
        }
    }
}
IParamBlock2* plResponderCmd::CreatePB(int idx)
{
    hsAssert(NumTypes() == 1, "Can't auto-create the pb for a cmd with multiple types");
    IParamBlock2 *pb = CreateParameterBlock2(GetDesc(), nil);
    return pb;
}