Flasher Archive
[Previous] [Next] - [Index] [Thread Index] - [Previous in Thread] [Next in Thread]
Subject: | RE: FLASH: Typing action that's efficient |
From: | Paul Willoughby |
Date: | Thu, 28 Sep 2000 16:20:41 +0100 |
>>Michael Lessard wrote:
Does anyone know an efficient way to simulate typing in Flash on screen.
Hi Michael,
I've been thinking there's a real easy way to do this and your mail has
prompted me to get round to trying it out. You can do it with a little loop
and a text field that is *extremely* efficient and requires zero
animation/masking. There's no blinking cursor, but you could probably think
of a work around to simulate this. This method is also limited by the fact
that you could only use one font and colour unless you developed some
complex variation on this code. It goes a little something like this...
Create a movie clip with a text field on one layer and actions on the other.
In this example my text field is called "text" and the string I want to
typewriter effect is called "word".
Key Frame 1 actions:
Set Variable: "word" = "hello, how are you doing? Your future is rosy, but
beware dark haired dwarves!"
Set Variable: "i" = "1"
Comment: This sets your string and sets up a local index variable for the
loop.
Key Frame 2 actions:
Set Variable: "text" = text & Substring(word,i,1)
Comment:Picks out each letter of the string and adds it to the text already
in the text field
Key Frame 3 actions:
Set Variable: "i" = i+1
Go to and Play (2)
Comment: creates the looping action and makes sure you're always picking out
the next letter of the string
You might also want to add an If statement to check when the text is
finished typing. In keyframe 2 add something like (and this is pseudo
code)...
If(i >= Length(word))
go do sumink else
I hope this meets ya needs!
Paul
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
NudeGuru.com is proud to sponsor the Flasher list
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
IT'S THE ART OF MONEY, HONEY!
Tips and Advice from some of the most popular Flash
artists + industry power-brokers on how to hold onto
your rights, negotiate contracts and get full value
for your work.http://www.nudeguru.com from Franke James
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
To unsubscribe or change your list settings go to
http://www.chinwag.com/flasher or email helpchinwag [dot] com
Replies
RE: FLASH: Typing action that's efficien, Andy Mrozkowski
[Previous] [Next] - [Index] [Thread Index] - [Next in Thread] [Previous in Thread]