protected override ReplacingAstVisitor[] PostProcessPipeline(ReplacingAstVisitor[] pipeline, BooUpdateContext context)
 {
     Replace(pipeline, typeof(DepricatedComponentPropertyGetterReplacer), new UnityScriptDepricatedComponentPropertyGetterReplacer(context));
     Replace(pipeline, typeof(MemberReferenceRemover), new UnityScriptMemberReferenceRemover(context));
     Replace(pipeline, typeof(MethodSignatureChanger), new MethodSignatureChanger(context));
     Replace(pipeline, typeof(StringBasedAddComponentReplacer), new StringBasedAddComponentReplacer(context));
     return pipeline;
 }
Exemplo n.º 2
0
 private static void Replace(DepthFirstVisitor[] pipeline, Type type, ReplacingAstVisitor replacement)
 {
     for (int i = 0; i != pipeline.Length; i++)
     {
         if (type.IsInstanceOfType(pipeline[i]))
         {
             pipeline[i] = replacement;
             break;
         }
     }
 }
 private static void Replace(DepthFirstVisitor[] pipeline, Type type, ReplacingAstVisitor replacement)
 {
     for (int i = 0; i != pipeline.Length; i++)
     {
         if (type.IsInstanceOfType(pipeline[i]))
         {
             pipeline[i] = replacement;
             break;
         }
     }
 }