topical media & game development

talk show tell print

professional-flex-code-15-CustomEffect.ax

professional-flex-code-15-CustomEffect.ax [swf] flex


  package
  {
    import mx.effects.Effect;
    import mx.effects.EffectInstance;
    
    public class @ax-professional-flex-code-15-CustomEffect extends Effect {
            
            // Define scaleTo parameter
      public var scaleTo:Number;
  
      public function @ax-professional-flex-code-15-CustomEffect(targetObj:Object = null)         {
        super(targetObj);
        instanceClass= professional_flex_code_15_CustomEffectInstance;            
      }
     
      // override getAffectedProperties() and 
      // pass the properties effected 
      override public function getAffectedProperties():Array         {
        return ["scaleX,scaleY"];
      }
          
    // (AE) Override initInstance()
    //  override protected function initInstance(inst:EffectInstance):void{
    //    super.initInstance(inst);
    //    professional_flex_code_15_CustomEffectInstance(inst).scaleTo = scaleTo;  
    //  }   
    }
  }
  


(C) Æliens 04/09/2009

You may not copy or print any of this material without explicit permission of the author or the publisher. In case of other copyright issues, contact the author.