Fork me on GitHub
Not signed in (Sign In)

Welcome, Guest

Want to take part in these discussions? Sign in if you have an account, or apply for one below

    • CommentAuthorleadbased
    • CommentTimeJul 13th 2011
     
    I am trying to attach a library item to act as my particle and I cannot seem to make it work. Please offer a suggestion if you've got one

    var initEmitter:Emitter2D = new Emitter2D();
    initEmitter.counter = new Blast( 10000 );
    initEmitter.addInitializer( new ColorInit( 0x000000, 0x000000 ) );
    initEmitter.addInitializer( new AlphaInit( 1, 1 ) );
    initEmitter.addInitializer(new SharedImage(new PixelArt()));
    initEmitter.addInitializer( new ScaleImageInit(10, 10));
    initEmitter.addInitializer( new Lifetime( 1 ) );
    initEmitter.addInitializer( new Position( new BitmapDataZone( webUrl, 50, 50 ) ) );
    initEmitter.addAction( new Age( Quadratic.easeInOut ) );
    initEmitter.addAction( new TweenToZone( new BitmapDataZone( cellNumber, 50, 50) ) );
    • CommentAuthorRichard
    • CommentTimeJul 15th 2011
     
    The code you've posted looks fine. Are you using the BitmapRenderer? The DisplayObjectRenderer won't work with the SharedImage initializer.