ActionScript 2.0 :: Text Class - Reverse And Erase Itself On Call?
May 24, 2007
I found this awesome text effect class. Can anyone give me any ideas on how I would go about making this work multi-line? I'd also like it to reverse and erase itself on call.
Im building a pretty simple drawing board in flash, i got this code from this forum and it works fine (there is more to it but this is the drawing part)[code]This works fine. But i want to be able to erase the drawings, step by step this is ths tricky part, ive looked everywhere(ok not everywhere) but in a whole lot of places but the only thing i found is how i could delete everything with removeChild and that in not what i want. Maybe i need to change the function abowe? Please help me to get in the right direction. What should i read about /look at?
I have a dynamic textfiled on stage and I am appending some lines of text each time in a new line with " ", so it like expand downwards.(it just currently serves me as a trace output online so I can check something)
what I would like to do is when that textfield reaches certain height that the first line at the top of the textfield gets deleted as a new one appers on the bottom and so on...
I have a textfield, and I put the field legend inside it. I want the text "type your name" to be erase once user click inside the textfield. How can I do that? And the reverse, if the text was lived empty show again "type your name"?
i spent alot of time and created an animation all in code, something like 200 lines long- so i wont post it on here unless one request. Now i want to run this animation in reverse...and I don't exactly know how to do this. Well i have some clue but have no idea of how to execute:
Choice 1-I i guess there is always the grunt work and copy paste and just plug in the opposite of everything i did...but yea that would take some time...
Choice 2- I guess i can attempt to create a class to house this animation and then some how play in reverse?? - if so how?
Choice 3- have some kind of wrestle with frames and have it run as a frame animation- then i can use prevFrame and nextFrame?
Anyone care to shed some light on my dilemma- because i don't even know if this is possible and/or my solutions are even valid
So I have this mc: this.slidingMenu it's a mc of a ring shaped menu, which turn around when 2 button get clicked. When the button on the right, mc goes forward until stop(), when the button on the left mc goes reverse until the stop(). In the first case i use gotoanplay, and everything goes fine. For the second I use prevFrame, like this:
i've got an inheritance chain of AS2 classes set up where i have an array in the 'child' class that i'd like to be able to access from the 'parent' class:
bottomClass.as -'parent' topClass.as -'child'
my question/dilemma is: how can the parent access the properties of a child class...is this even possible, or am i just looking at it wrong?
i've got an inheritance chain of AS2 classes set up where i have an array in the 'child' class that i'd like to be able to access from the 'parent' class:
bottomClass.as -'parent' topClass.as -'child'
my question/dilemma is: how can the parent access the properties of a child class...is this even possible,
so i'm now working on a mp3 player, and i got stucked with something. so here's my problem: i've a got bar (songBar) on which it will appear the artist and the song name(artist_txt). what i want is when de title_txt width is larger than the songBar.width, the text to scroll from right to left, and when the tween is finished to scroll from left to right(all this tween has to be a loop). if the width of artist_txt is smaller or equal to the songBar.width then artist_txt is aligned in the center of the songBar. all i'm trying to code it's just what you see in winamp player.
while working with a server side script (php or aspx) which returns some data(from the database) can we call it in a sub-class or do we have to make the calls in the document class itself?
I need to call the class into to my control as file. The problem I'm getting now is this error. "environmentTab.lightsButton.addEventListener(MouseEvent.CLICK, selectLights);" environmentTab is a instance name of a movie clip that is on the stage of my .
How can I run function of the main document class from a class of a MovieClip? I usually just used MovieClip(parent).function(), but now my MovieClip has another parent. Or what do I have to pass to the MovieClip class when creating the MovieClip to acess the main document class?
Lets say I have a Main Document Class called Main. I also have a child class called childClass that call a function from the Main class and is also imported in the Main class. How should I call the function? I tried this , but when calling the function, it's getting me error.
I have a Document class that instantiates a class named Other. I need to call a function in the Other class from the Document class.I'm getting this error: Call to a possibly undefined method OtherFunction through a reference with static type Other.I have read online that you need to use make the functions static or use a getter function but I'm unclear how to do that. I haven't been able to make it work and I feel like i'm missing something fundemental with this problem.below are simplified versions of the classes.
I have a document class called Main.as In the class constructor I have the following listener:
enter code here var listeningFORModeChangeToStudent:Sprite = new Sprite; listeningFORModeChangeToStudent.addEventListener(TellAllModeChangeToStudent.STUDENT,exp); addChild(listeningFORModeChangeToStudent);
[code]....
In a third class I make a call to the despatcher in the previous class:
enter code here var ThisTellAllModeChangeToStudent:TellAllModeChangeToStudent = new TellAllModeChangeToStudent; ThisTellAllModeChangeToStudent.tellAllModeChangeToStudent();
I have trace statements in eveything and from this I know the despatcher in TellAllModeChangeToStudent is being called.The problem is that the listener in the main.as is not calling the function exp.I cant see why and I dont know how to check if the listener is actually seeing the dispatch event?
Main is my doccument class . how can i call Main.Caller
package { import flash.display.Sprite; import flash.events.Event; public class Main extends Sprite { public function Main():void { if (stage) init(); else
I have a class, my document class, called SilkRoadTweeter. as I also have a class called User.as In my User class I need to call a method called nonce() I have tried this, trace(SilkRoadTweeter(root).nonce()); But I get the error, TypeError: Error #1009: Cannot access a property or method of a null object reference.
They are located in the same package and are both importing each other. I am trying to call a function from Class2 within Class1, but I don't know the syntax. I tried: Class2.godoThisThingNow(); But it gave me an error 1061, call to an undefined method. What's the proper syntax for this, and is it even possible in AS3?
From my LoadXML class I am trying to call a method, named onBackgrLoad, which sits inside the Main class. I made the method onBackgrLoad public. Inside the LoadXML class in the method ParseData I added an event listener. This is supposed to call onBackgrLoad but it doesnt work
I'm trying to call a function in one child class (Circle.as) from another child class (Wedge.as). Circle.as is instantiated by the document class (Tree.as), and Wedge.as is instantiated by Circle.as. How do I do this? This is my code:
Tree.as package com.treediagram { public class Tree extends MovieClip {
[code]....
How to call a function in a Class from another Class?but it was a bit hard to follow as it relates to my problem. One of the solutions worked, but was commented as being bad form, and another did not work, so I want to make sure I structure my code properly.
I'm Trying to make a very simple E mail form using textinput boxes and sending variables to php.Thing is that my erase button stops functioning once I hit the Submit button.[code]
I'm Trying to make a very simple E mail form using textinput boxes and sending variables to php.Thing is that my erase button stops functioning once I hit the Submit button.here are the scripts for Submit and Erase:
Submit script: on (release) { name = _parent.mailer.name.text;[code].....