Search Results

Search found 18 results on 1 pages for 'tweening'.

Page 1/1 | 1 

  • Is there a way to export all the images of my tweening effect in Flash?

    - by Paul
    i'm using Flash to create the animation of my character in 2D (i'm just beginning). Is it possible to make a tween effect of a character, and then automatically export all the images/frames? So far, it's a bit fastidious : i create my tweening effect, then i put a keyframe for each frame i want to copy and paste, then i select the movieclips and shapes and copy and paste them into another flash document, i position those clips at the exact same location as the previous image, then i erase the previous image and export the image... For 30 frames! Is there any faster way? Thanks

    Read the article

  • ActionScript Tweening Matrix Transform (big problem)

    - by TheDarkIn1978
    i'm attempting to tween the position and angle of a sprite. if i call the functions without tweening, to appear in one step, it's properly set at the correct coordinates and angle. however, tweening it makes it all go crazy. i'm using an rotateAroundInternalPoint matrix, and assume tweening this along with coordinate positions is messing up the results. works fine (without tweening): public function curl():void { imageWidth = 400; imageHeight = 600; parameters.distance = 0.5; parameters.angle = 45; backCanvas.x = imageWidth - imageHeight * parameters.distance; backCanvas.y = imageHeight - imageHeight * parameters.distance; var internalPointMatrix:Matrix = backCanvas.transform.matrix; MatrixTransformer.rotateAroundInternalPoint(internalPointMatrix, backCanvas.width * parameters.distance, 0, parameters.angle); backCanvas.transform.matrix = internalPointMatrix; } doesn't work properly (with tweening): public function curlUp():void { imageWidth = 400; imageHeight = 600; parameters.distance = 0.5; parameters.angle = 45; distanceTween = new Tween(parameters, "distance", None.easeNone, 0, distance, 1, true); angleTween = new Tween(parameters, "angle", None.easeNone, 0, angle, 1, true); angleTween.addEventListener(TweenEvent.MOTION_CHANGE, animateCurl); } private function animateCurl(evt:TweenEvent):void { backCanvas.x = imageWidth - imageHeight * parameters.distance; backCanvas.y = imageHeight - imageHeight * parameters.distance; var internalPointMatrix:Matrix = backCanvas.transform.matrix; MatrixTransformer.rotateAroundInternalPoint(internalPointMatrix, backCanvas.width * parameters.distance, 0, parameters.angle - previousAngle); backCanvas.transform.matrix = internalPointMatrix; previousAngle = parameters.angle; } in order for the angle to tween properly, i had to add a variable that would track it's last angle setting and subtract it from the new one. however, i still can not get this tween to return the same end position and angle as is without tweening. i've been stuck on this problem for a day now, so any help would be greatly appreciated.

    Read the article

  • ActionScript Bitmap Filter Tweening

    - by TheDarkIn1978
    i can't seem to tween any bitmap filters. here's my code: var dropShadow:DropShadowFilter = new DropShadowFilter(); mySprite.filters = [dropShadow]; var dropShadowTween:Tween = new Tween(dropShadow, "distance", Regular.easeOut, 4.0, 20, 2, true); what is my mistake? i've also tried the following but it doesn't work: var dropShadowTween:Tween = new Tween(mySprite.filters[0], "distance", Regular.easeOut, 4.0, 20, 2, true);

    Read the article

  • Tween Animation Cannot Start

    - by David Dimalanta
    Do you have any reasons why my tween code didn't run or work? I already add the tween engine onto the library folder under LibGDX project folder and "Order and Export" it under Java Build Path at the Properties menu. My first two classes ran correctly and workly but my third class didn't work. Here's the sequence: First class is the first screen. Fade animation works on the company's logo. Second class is the second screen. Fade animation for the loading screen works. Third class is the third screen. After the second screen, now calls for the third screen. Animation stopped or won't run since I want the black screen to fade out at the start when the menu is here. Can you check if I did right? Look carefully by comment lines for explanation. //-----[ Animation Setup ]----- Tween.registerAccessor(Sprite.class, new Tween_Animation()); // --> Tween_Animation.java Tween_Manager = new TweenManager(); // --> I initialized it the TweenManager and seems okay. cb_start = new TweenCallback() // --> I'll use this when I choose START and the menu will fade in black. { @Override public void onEvent(int arg0, BaseTween<?> arg1) { goTo(); } }; Tween // --> This is where I focused the problem. .to(black_Sprite, Tween_Animation.ALPHA, 3f) .target(1) .ease(TweenEquations.easeInQuad) .repeatYoyo(200, 2.5f) // --> I set the repeat for 200 times when I noticed that the animation won't work! .start(Tween_Manager);

    Read the article

  • box2d tween what am I missing

    - by philipp
    I have a Box2D project and I want to tween an kinematic body from position A, to position B. The tween function, got it from this blog: function easeInOut(t , b, c, d ){ if ( ( t /= d / 2 ) < 1){ return c/2 * t * t * t * t + b; } return -c/2 * ( (t -= 2 ) * t * t * t - 2 ) + b; } where t is the current value, b the start, c the end and d the total amount of frames (in my case). I am using the method introduced by this lesson of todd's b2d tutorials to move the body by setting its linear Velocity so here is relevant update code of the sprite: if( moveData.current == moveData.total ){ this._body.SetLinearVelocity( new b2Vec2() ); return; } var t = easeNone( moveData.current, 0, 1, moveData.total ); var step = moveData.length / moveData.total * t; var dir = moveData.direction.Copy(); //this is the line that I think might be corrected dir.Multiply( t * moveData.length * fps /moveData.total ) ; var bodyPosition = this._body.GetWorldCenter(); var idealPosition = bodyPosition.Copy(); idealPosition.Add( dir ); idealPosition.Subtract( bodyPosition.Copy() ); moveData.current++; this._body.SetLinearVelocity( idealPosition ); moveData is an Object that holds the global values of the tween, namely: current frame (int), total frames (int), the length of the total distance to travel (float) the direction vector (targetposition - bodyposition) (b2Vec2) and the start of the tween (bodyposition) (b2Vec2) Goal is to tween the body based on a fixed amount of frames: in moveData.total frames. The value of t is always between 0 and 1 and the only thing that is not working correctly is the resulting distance the body travels. I need to calculate the multiplier for the direction vector. What am I missing to make it work?? Greetings philipp

    Read the article

  • Blending animations for more character movements

    - by Noob Saibot
    I am making a hack n slash 3rd person game. And I want the character movements to be more dynamic not like fighting games where you have a moves list. I want to animate tons of different animations and have them "Tween" between each other? Because I want the controls to not be keyboard mouse. I want it to be all keyboard. that way you have up to 10 inputs (All your fingers) to blend and morph animations to create more fluid movements. In the end this will almost be similar to characters typing a phrase or string of keys rather than move forward mouse look click to melee. My question is. Has anyone done this before and would someone go about trying to tween lets say one for key on the keyboard excluding Tab, Caps, R+Shift, L+Shift, Enter, R+Ctrl, L+Ctrl, L+Alt, R+Alt, Windows Key, and Menu. So thats all the numbers, letters and punctuation keys. Thats 46 keys gives me a combination of 46P1 = 5502622159812088949850305428800254892961651752960000000000L (used Python) and with a minimum entry value of 2 keypresses shortening to half. This is not humanly possible to create so many inique animations in one lifetime. But I'm guessing there is a reason this hasn't been done already. Or if I just used 10 basic keys. Maybe ASDF SPACE (RIGHT HAND) 456+0 (LEFT HAND KEYPAD) it would give me 3,628,800 posible unique animations.

    Read the article

  • calculate camera up vector after glulookat()?

    - by carrots
    I'm just starting out teaching myself openGL and now adding openAL to the mix. I have some planets scattered around in 3D space and when I touch the screen, I'm assigning a sound to a random planet and then slowly and smoothly flying the "camera" over to look at it and listen to it. The animation/tweening part is working perfectly, but the openAL piece isn't quiet right. I move the camera around by doing a tiny translate() and gluLookAt() for every frame to keep things smooth (tweening the camera position and lookAt coords). The trouble seems to be with the stereo image I'm getting out of the headphones.. it seems like the left/right/up/down is mixed up sometimes after the camera rolls or spins. I am pretty sure the trouble is here: ALfloat listenerPos[]={camera->currentX,camera->currentY,camera->currentZ}; ALfloat listenerOri[]={camera->currentLookX, camera->currentLookY, camera->currentLookZ, 0.0,//Camera Up X <--- here 0.1,//Camera Up Y <--- here 0.0}//Camera Up Z <--- and here alListenerfv(AL_POSITION,listenerPos); alListenerfv(AL_ORIENTATION,listenerOri); I'm thinking I need to recompute the UP vector for the camera after each gluLookAt() to straighten out the audio positioning problem.. but after hours of googling and experimenting I'm stuck in math that suddenly got way over my head. 1) Am I right that I need to recalculate the up vector after each gluLookAt() i do? 2) If so, can someone please walk me though figuring out how to do that?

    Read the article

  • Zoom , pan inside a rectangle bound

    - by spark03
    I am building a site with some features of google map. I want to pan, zoom in out a map with tweening effect. But when I zoom the map(Movie clip) it zooms out of the rectangular boundary. I also want to wrap the map(when scrolled). How can I do all these?

    Read the article

  • Managing flash animations for a game

    - by LoveMeSomeCode
    Ok, I've been writing C# for a while, but I'm new to ActionScript, so this is a question about best practices. We're developing a simple match game, where the user selects tiles and tries to match various numbers - sort of like memory - and when the match is made we want a series of animations to take place, and when they're done, remove the tile and add a new one. So basically it's: User clicks the MC Animation 1 on the MC starts Animation 1 ends Remove the MC from the stage Add a new MC Start the animation on the new MC The problem I run into is that I don't want to make the same timeline motion tween on each and every tile, when the animation is all the same. It's just the picture in the tile that's different. The other method I've come up with is to just apply the tweens in code on the main stage. Then I attach an event handler for MOTION_FINISH, and in that handler I trigger the next animation and listen for that to finish etc. This works too, but not only do I have to do all the tweening in code, I have a seperate event handler for each stage of the animation. So is there a more structured way of chaining these animations together?

    Read the article

  • Looking for temporal upsampling / motion interpolation software

    - by timday
    I'm looking for something (prereably FOSS software) which can take an animation with N images as input, and which will output an animation with M frames, where M is in the range 2N to 5N or so. I believe the general technique is called "temporal upsampling" or possibly "inbetweening" (or "'tweening" for short). Note that it does need to make some effort to do motion tracking of things in the scene ("optical flow"); just fading ("dissolve") between keyframes isn't going to cut it. Googling "temporal upsampling" turns up any number of papers on the subject, but I've yet to discover any code/software (a gstreamer plugin would be perfect) I can just use to try the technique out. Any suggestions ? Additional information: "Motion interpolation" seems to be the more widely used name in the TV world for what I'm looking for. See this and the video here too. Interestingly, some cinephiles seem to hate what these technologies do to 24FPS film: e.g a comment "makes Gone With The Wind look like a soap opera shot on video".

    Read the article

  • Looking for temporal upsampling software

    - by timday
    I'm looking for something (prereably FOSS software) which can take an animation with N images as input, and which will output an animation with M frames, where M is in the range 2N to 5N or so. I believe the general technique is called "temporal upsampling" or possibly "inbetweening" (or "'tweening" for short). Note that it does need to make some effort to do motion tracking of things in the scene ("optical flow"); just fading ("dissolve") between keyframes isn't going to cut it. Googling "temporal upsampling" turns up any number of papers on the subject, but I've yet to discover any code/software I can just use to try the technique out. Any suggestions ?

    Read the article

  • as3 - controlling flicker when scaling up a button or movieclip

    - by sol
    This is a situation I run into a lot but never seem to find a good solution. I have movieclips that I scale up slightly on rollover, but if you hover over the edge of the movieclip it just sits there and flickers, continuously receiving mouseOver and mouseOut events. How do you deal with this? Again, it's usually a problem when tweening the scale of a movieclip or button. my_mc.addEventListener(MouseEvent.MOUSE_OVER, mOver); my_mc.addEventListener(MouseEvent.MOUSE_OUT, mOut); private function mOver(m:MouseEvent) { TweenLite.to(m.target, .2, { scaleX:1.1, scaleY:1.1} ); } private function mOut(m:MouseEvent) { TweenLite.to(m.target, .2, { scaleX:1, scaleY:1} ); }

    Read the article

  • iTunes Visualization -- What type of code is it written in and what does that code look like?

    - by Christopher Altman
    Being a web developer, I know how event driven user interfaces are written, but do not have insight into other families of code (embedded software like automotive software, automation software on assembly lines, drivers, or the crawling lower-thirds on CNN, etc.) I was looking at the iTunes visualizer (example) and am curious: What code is used to write the visualizer? Objective C? Does it use Core Animation? What type of abstraction does that library offer? What does the code look like? Is it a list of mathematical equations for producing the crazy graphics? Is it a list of key frames with tweening? Is there an array of images, fractals, worm holes, flowers, sparkles, and some magic mixes them together. Or something totally different? I am not looking for a tutorial, just an understanding of how something very different than web development works. Oh yah, I know iTunes is closed source, so all of this is conjecture.

    Read the article

  • JavaScript socket vs. Flash socket?

    - by Dr.Dredel
    Steve Jobs just posted this article on why Apple rejects Flash... http://www.apple.com/hotnews/thoughts-on-flash/ I agree that javascript and css can be used to replicate some of Flash's animation, though Flash does all sorts of scaling and tweening that is incredibly powerful, and I'm not sure that there's anything comparable in javascript, if there is, I certainly haven't seen it. However, my question is about the socket. Flash has an incredibly powerful openSocket class that allows you to connect to a server and have the server and the client talk back and forth to one another. As far as I know there is no equivalent class in Javascript. Am I mistaken? Is there some secret mystery Ajax class that replicates the openSocket? If not, then that feature alone makes Flash an invaluable tool. I'm interested in all answers though... and yes this IS a programming question! :)

    Read the article

  • array won't work actionscript 3

    - by steve
    I've tried everything. Arrays are quite simple so I don't know why this doesn't function: var menuList:Array = [menu_bag_mc,menu_chips_mc,menu_coke_mc,menu_cup_mc,menu_deodorant_mc,menu_fork_mc,menu_knife_mc,menu_lighter_mc,menu_milk_mc,menu_pill_mc,menu_rings_mc,menu_shampoo_mc,menu_spoon_mc,menu_straw_mc,menu_toothbrush_mc,menu_trashbag_mc,menu_water_mc]; function captureAllClicks(event:MouseEvent):void { trace(menuList.indexOf(event.target)); } stage.addEventListener(MouseEvent.CLICK, captureAllClicks); Every time I click on any of the items on the stage (which are all given the instance names listed above. each is a tweening movieclip containing a button) I get a trace of -1. WHY?!

    Read the article

  • Using TweenMax to fade in div with background pattern and z-index not working

    - by shibbydoo
    I'm trying to do this really simple fade using TweenMax for this div I have. Here's the css for the div .aboutBg { background:url(../images/pattern.jpg); top:0; right:0; left:0; bottom:0, position:fixed; border:10px solid red; z-index:10; } TweenMax.to('.aboutPage', 0.5, {autoAlpha:1}); What's happening is the border would fade in nicely but the patterned bg is not, it just pops up at the end of the tween. If I remove the z-index everything works, but I have to have set the z-index so it's on top of my other content. Also I'm not tweening the z-index, it's set before the tween, so I'm not sure why it's not fading correctly. Anyone has any idea? Thanks.

    Read the article

  • strings and textfields, AS3

    - by VideoDnd
    How do I get my text fields to populate correctly and show single digits? Description Each textfield receives a substring. This doesn't limit it's input, because the text fields shows extra numbers. See illustration. Ex A //Tweening method 'could substitute code with Tweener' import fl.transitions.Tween; import fl.transitions.easing.*; //Timer that will run a sec and repeat var timer:Timer = new Timer(1000); //Integer values var count:int = +220000000; var fcount:int = 0; //Events and starting timer timer.addEventListener(TimerEvent.TIMER, incrementCounter); addEventListener(Event.ENTER_FRAME, checkOdometerPosition); timer.start(); //Tween Variables var smoothLoop:int = 0; var originalYPosition:Number = 0; var upwardYPosition:Number = -99; //Formatting String function formatCount(i:int):String { var fraction:int = i % 100; var whole:int = i / 100; return ("0000000" + whole).substr(-7, 7) + "." + (fraction < 10 ? "0" + fraction : fraction); } //First Digit 'trigger set by using var upwardPosition as a constant' function checkOdometerPosition(event:Event):void{ if (seconds9.y <= upwardYPosition){ var toText:String = formatCount(fcount); //seconds9.firstDigit.text = formatCount(fcount); seconds9.firstDigit.text = toText.substr(9, 9); seconds9.y = originalYPosition; seconds8.firstDigit.text = toText.substr(8, 8); seconds8.y = originalYPosition; seconds7dec.firstDigit.text = toText.substr(7, 7); seconds7dec.y = originalYPosition; seconds6.firstDigit.text = toText.substr(6, 6); seconds6.y = originalYPosition; seconds5.firstDigit.text = toText.substr(5, 5); seconds5.y = originalYPosition; seconds5.firstDigit.text = toText.substr(4, 4); seconds5.y = originalYPosition; seconds3.firstDigit.text = toText.substr(3, 3); seconds3.y = originalYPosition; seconds2.firstDigit.text = toText.substr(2, 2); seconds2.y = originalYPosition; seconds1.firstDigit.text = toText.substr(1, 1); seconds1.y = originalYPosition; seconds1.firstDigit.text = toText.substr(1, 1); seconds1.y = originalYPosition; seconds0.firstDigit.text = toText.substr(0, 1); seconds0.y = originalYPosition; } } //Second Digit function incrementCounter(event:TimerEvent):void{ count++; fcount=int(count) if (smoothLoop < 9){ smoothLoop++; } else { smoothLoop = 0; } var lolly:String = formatCount(fcount-1); //seconds9.secondDigit.text = formatCount(fcount); seconds9.secondDigit.text = lolly.substr(9, 9); var addTween9:Tween = new Tween(seconds9, "y", Strong.easeOut,0,-222, .7, true); seconds8.secondDigit.text = lolly.substr(8, 8); var addTween8:Tween = new Tween(seconds8, "y", Strong.easeOut,0,-222, .7, true); seconds7dec.secondDigit.text = lolly.substr(7, 7); var addTween7dec:Tween = new Tween(seconds7dec, "y", Strong.easeOut,0,-222, .7, true); seconds6.secondDigit.text = lolly.substr(6, 6); var addTween6:Tween = new Tween(seconds6, "y", Strong.easeOut,0,-222, .7, true); seconds5.secondDigit.text = lolly.substr(5, 5); var addTween5:Tween = new Tween(seconds5, "y", Strong.easeOut,0,-222, .7, true); seconds4.secondDigit.text = lolly.substr(4, 4); var addTween4:Tween = new Tween(seconds4, "y", Strong.easeOut,0,-222, .7, true); seconds3.secondDigit.text = lolly.substr(3, 3); var addTween3:Tween = new Tween(seconds3, "y", Strong.easeOut,0,-222, .7, true); seconds2.secondDigit.text = lolly.substr(2, 2); var addTween2:Tween = new Tween(seconds2, "y", Strong.easeOut,0,-222, .7, true); seconds1.secondDigit.text = lolly.substr(1, 1); var addTween1:Tween = new Tween(seconds1, "y", Strong.easeOut,0,-222, .7, true); seconds0.secondDigit.text = lolly.substr(0, 1); var addTween0:Tween = new Tween(seconds0, "y", Strong.easeOut,0,-222, .7, true); } Ex A has 10 text objects, each with a pair of text fields. It’s move complex than Ex B, because it has a Y animation and pairs of numbers. The text objects are animated to create a scrolling effect. It moves vertically, and has a lead number and a catch up number contained in each symbol. See illustration for more description. The counters are set to 2,200,000.00, just to see if the numbers are populating. Ex B work fine! for example only //STRING SPLITTER COUNTER with nine individual text fields //Timer settings var delay:uint = 1000/100; var repeat:uint = 0; var timer:Timer; timer = new Timer(delay,repeat); timer.addEventListener(TimerEvent.TIMER, incrementCounter); timer.start(); //Integer values var count:int = 0; var fcount:int = 0; //Format Count function formatCount(i:int):String { var fraction:int = i % 100; var whole:int = i / 100; return ("0000000" + whole).substr(-7, 7) + "." + (fraction < 10 ? "0" + fraction : fraction); } //Split strings off to individual text fields function incrementCounter(event:TimerEvent) { count++; fcount=int(count+220000000) var toText:String = formatCount(fcount); mytext9.text = toText.substr(9, 9); mytext8.text = toText.substr(8, 8); mytext7dec.text = toText.substr(7, 7); mytext6.text = toText.substr(6, 6); mytext5.text = toText.substr(5, 5); mytext4.text = toText.substr(4, 4); mytext3.text = toText.substr(3, 3); mytext2.text = toText.substr(2, 2); mytext1.text = toText.substr(1, 1); mytext0.text = toText.substr(0, 1); } Here's a link to the files

    Read the article

  • substrings and multiple textfields, AS3

    - by VideoDnd
    How do I get my text fields to populate correctly and show single digits? Description Each textfield receives a substring. This doesn't limit it's input, because the text fields shows extra numbers. The counters are set to 2,200,000.00, just to see if the numbers are populating. Ex A is the one I'm trying to fix. Ex A the one I want to fix //Tweening method 'could substitute code with Tweener' import fl.transitions.Tween; import fl.transitions.easing.*; //Timer that will run a sec and repeat var timer:Timer = new Timer(1000); //Integer values var count:int = +220000000; var fcount:int = 0; //Events and starting timer timer.addEventListener(TimerEvent.TIMER, incrementCounter); addEventListener(Event.ENTER_FRAME, checkOdometerPosition); timer.start(); //Tween Variables var smoothLoop:int = 0; var originalYPosition:Number = 0; var upwardYPosition:Number = -99; //Formatting String function formatCount(i:int):String { var fraction:int = i % 100; var whole:int = i / 100; return ("0000000" + whole).substr(-7, 7) + "." + (fraction < 10 ? "0" + fraction : fraction); } //First Digit function checkOdometerPosition(event:Event):void{ if (seconds9.y <= upwardYPosition){ var toText:String = formatCount(fcount); //seconds9.firstDigit.text = formatCount(fcount); seconds9.firstDigit.text = toText.substr(9, 9); seconds9.y = originalYPosition; seconds8.firstDigit.text = toText.substr(8, 8); seconds8.y = originalYPosition; seconds7dec.firstDigit.text = toText.substr(7, 7); seconds7dec.y = originalYPosition; seconds6.firstDigit.text = toText.substr(6, 6); seconds6.y = originalYPosition; seconds5.firstDigit.text = toText.substr(5, 5); seconds5.y = originalYPosition; seconds5.firstDigit.text = toText.substr(4, 4); seconds5.y = originalYPosition; seconds3.firstDigit.text = toText.substr(3, 3); seconds3.y = originalYPosition; seconds2.firstDigit.text = toText.substr(2, 2); seconds2.y = originalYPosition; seconds1.firstDigit.text = toText.substr(1, 1); seconds1.y = originalYPosition; seconds1.firstDigit.text = toText.substr(1, 1); seconds1.y = originalYPosition; seconds0.firstDigit.text = toText.substr(0, 1); seconds0.y = originalYPosition; } } //Second Digit function incrementCounter(event:TimerEvent):void{ count++; fcount=int(count) if (smoothLoop < 9){ smoothLoop++; } else { smoothLoop = 0; } var lolly:String = formatCount(fcount-1); //seconds9.secondDigit.text = formatCount(fcount); seconds9.secondDigit.text = lolly.substr(9, 9); var addTween9:Tween = new Tween(seconds9, "y", Strong.easeOut,0,-222, .7, true); seconds8.secondDigit.text = lolly.substr(8, 8); var addTween8:Tween = new Tween(seconds8, "y", Strong.easeOut,0,-222, .7, true); seconds7dec.secondDigit.text = lolly.substr(7, 7); var addTween7dec:Tween = new Tween(seconds7dec, "y", Strong.easeOut,0,-222, .7, true); seconds6.secondDigit.text = lolly.substr(6, 6); var addTween6:Tween = new Tween(seconds6, "y", Strong.easeOut,0,-222, .7, true); seconds5.secondDigit.text = lolly.substr(5, 5); var addTween5:Tween = new Tween(seconds5, "y", Strong.easeOut,0,-222, .7, true); seconds4.secondDigit.text = lolly.substr(4, 4); var addTween4:Tween = new Tween(seconds4, "y", Strong.easeOut,0,-222, .7, true); seconds3.secondDigit.text = lolly.substr(3, 3); var addTween3:Tween = new Tween(seconds3, "y", Strong.easeOut,0,-222, .7, true); seconds2.secondDigit.text = lolly.substr(2, 2); var addTween2:Tween = new Tween(seconds2, "y", Strong.easeOut,0,-222, .7, true); seconds1.secondDigit.text = lolly.substr(1, 1); var addTween1:Tween = new Tween(seconds1, "y", Strong.easeOut,0,-222, .7, true); seconds0.secondDigit.text = lolly.substr(0, 1); var addTween0:Tween = new Tween(seconds0, "y", Strong.easeOut,0,-222, .7, true); } Ex A has 10 text objects, each with a pair of text fields. It’s move complex than Ex B, because it has a Y animation and pairs of numbers. The text objects are animated to create a scrolling effect. It moves vertically, and has a lead number and a catch up number contained in each symbol. See illustration for more description. Ex B work fine! for example only //STRING SPLITTER COUNTER with nine individual text fields //Timer settings var delay:uint = 1000/100; var repeat:uint = 0; var timer:Timer; timer = new Timer(delay,repeat); timer.addEventListener(TimerEvent.TIMER, incrementCounter); timer.start(); //Integer values var count:int = 0; var fcount:int = 0; //Format Count function formatCount(i:int):String { var fraction:int = i % 100; var whole:int = i / 100; return ("0000000" + whole).substr(-7, 7) + "." + (fraction < 10 ? "0" + fraction : fraction); } //Split strings off to individual text fields function incrementCounter(event:TimerEvent) { count++; fcount=int(count+220000000) var toText:String = formatCount(fcount); mytext9.text = toText.substr(9, 9); mytext8.text = toText.substr(8, 8); mytext7dec.text = toText.substr(7, 7); mytext6.text = toText.substr(6, 6); mytext5.text = toText.substr(5, 5); mytext4.text = toText.substr(4, 4); mytext3.text = toText.substr(3, 3); mytext2.text = toText.substr(2, 2); mytext1.text = toText.substr(1, 1); mytext0.text = toText.substr(0, 1); }

    Read the article

1