help using Online panel

Posted by user542011 
help using Online panel
February 12, 2011 04:08AM
I am trying to learn how to use FlashEff 2.0 with ActionScript. I'm a bit confused and thought the Online panel would help - but I am getting errors.

First - can the code generated from the Online panel be used in a regular Flash AS3 project? Or can it ONLY be used in a Flex project? I don't know Flex and am using it in Flash.

Second (if the code generated by the Online panel can be used in Flash projects) I am getting compile errors after copy pasting the following code from the panel:

import com.jumpeye.flashEff2.symbol.stripes.FESStripesNo2;

var fe:FlashEff2Flex = new FlashEff2Flex();
this.addChild(fe);
fe.target =myInstance

var pattern0:FESStripesNo2 = new FESStripesNo2();
pattern0.preset=5;
pattern0.waveThickness=2;
pattern0.groupDuration=1.1;
pattern0.tweenDuration=1.5;
pattern0.tweenType='Strong';
pattern0.easeType='easeInOut';

fe.showTransition=pattern0

My MovieClip is named "myInstance" and I have dragged both the FlashEff2 code component and the FESStripesNo2 filter to the library.

However, I am getting the following errors:

Scene 1, Layer 'Layer 2', Frame 2, Line 6 1046: Type was not found or was not a compile-time constant: FlashEff2Flex.
Scene 1, Layer 'Layer 2', Frame 2, Line 6 1180: Call to a possibly undefined method FlashEff2Flex.

What am I doing wrong?
Re: help using Online panel
February 14, 2011 07:40AM
In your code instead of FlashEff2Flex component write FlashEff2Code and drag in the library the FlashEff2Code component.
import com.jumpeye.flashEff2.symbol.stripes.FESStripesNo2;

var fe:FlashEff2Code= new FlashEff2Code();
this.addChild(fe);
fe.target =myInstance

var pattern0:FESStripesNo2 = new FESStripesNo2();
pattern0.preset=5;
pattern0.waveThickness=2;
pattern0.groupDuration=1.1;
pattern0.tweenDuration=1.5;
pattern0.tweenType='Strong';
pattern0.easeType='easeInOut';

fe.showTransition=pattern0
Sorry, you do not have permission to post/reply in this forum.