Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
  Advanced Search
  HOME    TRACKER    Flash








Matrix Effect


ei..can anyone help me make a matrix effect ...just like in this site...does it have any AS that will make it randomly appear...? thanks!




KirupaForum > Flash > Flash 8 (and earlier) > Flash MX
Posted on: 06-11-2003, 02:48 PM


View Complete Forum Thread with Replies

Sponsored Links:

Matrix Effect Ez Way
Hi to all

I have added one more tutorial in my website

i.e matrix effect

visit :http://www.flashcircle.com

bye

have a good day

View Replies !    View Related
Matrix Effect
Hi,
Anybody please tell me how to do matrix effect with script in flash 5.

dhananjay

View Replies !    View Related
Matrix Effect
Hi, all. Does anybody know some text effect making the matrix random number? First, it raining down, and then some of them have one text that glows raining down too. I need an expert help here to make my swf looks real like in the movie. Anybody? ( A question also a challenge for all the gurus )

View Replies !    View Related
A Different Look At The Matrix Effect By Pom
One of my favourites. I was playing around with the original one from the kirupaLab by pom. and i came up with this . the ripple effect on the chain is tweened (check the large mc in the middle of the stage) i was wondering whether it could be scripted coz i tthink that would involve duplicating the thing while its moving and is there a way to make the foremost letter glow?

View Replies !    View Related
A Different Look At The Matrix Effect By Pom
One of my favourites. I was playing around with the original one from the kirupaLab by pom. and i came up with this . the ripple effect on the chain is tweened (check the large mc in the middle of the stage) i was wondering whether it could be scripted coz i tthink that would involve duplicating the thing while its moving and is there a way to make the foremost letter glow?

View Replies !    View Related
Matrix Effect
i want to know how to do the matrix effect, and hten have some letters be highlighted to show my site logo. Does anyone know how to do this, where to find a tutorial, and/or what i should read up about to do this

thanx in advance

View Replies !    View Related
Matrix Effect
could anyone find me a matrix text effects,I would be grateful.

View Replies !    View Related
Matrix Effect
im doing a movie, and for the intro i would like a matrix effect, i have checked the different sites that provides tutorials and cannot find any tutorials.

I would appreciate any help on this one.
Im a noob aswell. So plz if u can explain detailed )..

Thanks for a great community.

View Replies !    View Related
Does Anyone Know The Matrix Effect?
Does anyone know how to do the Matrix effect where like, the camera spins and zooms around the object??

View Replies !    View Related
Matrix Effect
I posted this in "Other" but it never got answered.

I have a question. I'm making a very simple flash intro with the Matrix effect from Kirupa lab. But there are two problems.

1) It goes on forever, I tried to make it only around 100 frames by making text then making it fade out and continuing the text without the first three layers, but it would still go on forever. How can I make it go on only for only 100 frames then let the letters(the matrix letters) slow down and eventually fade?

2) after a while of the intro going on, the matrix letters start overlapping each other and looking like crap. So basically, see above and that's what I really need help with

View Replies !    View Related
Matrix Effect....
hey there guys.. yeah , ive seen the matrix sample in the kirupa lab... but im not really sure what's going on...... so if one of you guys would be kind enough to explain to me what's going on with the codes and stuff... then that would be greatly appreciated. hehe thanks !

View Replies !    View Related
A Different Look At The Matrix Effect By Pom
One of my favourites. I was playing around with the original one from the kirupaLab by pom. and i came up with this . the ripple effect on the chain is tweened (check the large mc in the middle of the stage) i was wondering whether it could be scripted coz i tthink that would involve duplicating the thing while its moving and is there a way to make the foremost letter glow?

View Replies !    View Related
A Different Look At The Matrix Effect By Pom
One of my favourites. I was playing around with the original one from the kirupaLab by pom. and i came up with this . the ripple effect on the chain is tweened (check the large mc in the middle of the stage) i was wondering whether it could be scripted coz i tthink that would involve duplicating the thing while its moving and is there a way to make the foremost letter glow?

View Replies !    View Related
Matrix Effect
i want to know how to do the matrix effect, and hten have some letters be highlighted to show my site logo. Does anyone know how to do this, where to find a tutorial, and/or what i should read up about to do this

thanx in advance

View Replies !    View Related
The Matrix Bitstream Effect
Hi,
I just finished working through the Matrix Bitstream Effect tutorial(http://www.flashkit.com/tutorials/Sp...-152/index.php) and i cant get the numbers to show up randomly. Heres a link to what my effect came out looking like: http://www.angelfire.com/oz/alw111/alw111.htm Thanks
This is the most helpfull flash website ive found

View Replies !    View Related
Matrix Effect - Stopping The Mc
Hi there

I'm trying to implement the 'raining text' effect which appeared on this site in the 'Movies > Flash Effects' section.

However, the movie on the site loops incessantly. I'm guessing that I'd need a loop or a timer to stop the movie Matrix effect.

The code in the main timeline is set up as follows:

Frame 1

removeMovieClip("Line" add (_currentframe+1));

Frame 2

duplicateMovieClip("Line1", "Line" add (_currentframe), _currentframe);
setProperty("Line" add (_currentframe), _x, random(550));
removeMovieClip("Line" add (_currentframe+1));

Frame 3

duplicateMovieClip("Line1", "Line" add (_currentframe), _currentframe);
setProperty("Line" add (_currentframe), _x, random(550));
removeMovieClip("Line" add (_currentframe+1));

Frame 4-25 (same as above)



My question is this:

What code would I need - and on which frame would it go - to say, have this movie clip last for just 3 or 4 seconds (a loop or a timer is fine)

Thanks in advance for your time.

Regards

Rob

View Replies !    View Related
Matrix Text Effect Help
Hey guys, Im creating a matrix themed website and I was going to animate the buttons so that you get the green streak glow that goes across it when your mouse goes over it. Are there any tutz about this or similar to this, or anything at all that could help me with it? Im fairly new to flash but Ive created a few buttons before and Im not afraid to learn.

View Replies !    View Related
Matrix Effect As Background
Hi everyone,
I have done a matrix effect, but i have a problem. It is in front of the my logo.
How do i put it as a background, so it will be behind the logo?

Here is the script that i have used:

minLines = 35;
maxLines = 35;
minScale = 10;
maxScale = 50;

theMatrix = createEmptyMovieClip('MatrixCode',1);
curLines = 0;

theMatrix.onEnterFrame = function(){

if(curLines <= maxLines){
curLines++;

codeLine = this.createEmptyMovieClip('codeLine',curLines);

var ranScale = Math.round(Math.random() * (maxScale-minScale)) + minScale;
codeLine._xscale = codeLine._yscale = ranScale;

my_text_mc.swapDepths(_root.getNextHighestDepth()) ;

codeLine._x = Math.random() * Stage.width;

codeLine.speed = (codeLine._xscale)/6;

codeLine.myCodes = [];
numPods = 0;
while(codeLine._height < Stage.height){
numPods++;

pod = codeLine.attachMovie('one_pod','pod'+numPods, numPods);
codeLine.myCodes.push(pod);

pod._y -= (pod._height+2) * numPods;

pod.the_one.Neo.text = chr(Math.round(Math.random() * 27) + 96);
}

codeLine.ind = 0;

codeLine.delay = codeLines.myCodes.length;

codeLine.onEnterFrame = function(){

this._y += this.speed;

if(this._y - this._height >= Stage.height) {

maxLines++;

this.removeMovieClip();
}

this.curCode = this.myCodes[this.ind];

if(this.curCode._currentframe == 1) this.curCode.play();

if(this.ind < this.myCodes.length and this.delay != 0){

this.ind++;

this.delay--;
} else {

this.ind = 0;

this.delay = this.myCodes.length;
}
}
}
}

View Replies !    View Related
The Matrix Effect Reversed?
Hi Guys,

I followed a tutorial to get the effect from the film the matrix which looks great, but i really want it to go the other way!! SO it starts at the bottom of the screen and goes up! I cant seem to adjust the code have to make it happen and wondered whether anyone would know how to do it??:


Code:
// Initialize variables.
maxLines = 40; // Maximum number of lines at once.
minScale = 10; // Minimum scale of a line.
maxScale = 100; // Maximum scale of a line.
// Create an empty Movieclip to hold the Matrix.
theMatrix = createEmptyMovieClip('MatrixCode',-99);
curLines = 0; // Keeps track of the current number of lines.
// ----------------------
// Generating the Matrix.
// ----------------------
theMatrix.onEnterFrame = function(){
// Check that the current number of lines is less than the maximum allowed.
if(curLines <= maxLines){
curLines++; // Increment the number of lines.
// Create a new line.
codeLine = this.createEmptyMovieClip('codeLine',curLines);
// Generate a random scale for the line.
// This simulates lines at different distances.
var ranScale = Math.round(Math.random() * (maxScale-minScale)) + minScale;
codeLine._xscale = codeLine._yscale = ranScale;
// Position the line at a random X location.
codeLine._x = Math.random() * Stage.width;
// Determine line speed based on the distance.
codeLine.speed = (codeLine._xscale)/20;
// ---------------------------------------------
// Creating a line of multiple pods (characters)
// ---------------------------------------------
codeLine.myCodes = []; // Array to store individual pods.
numPods = 0; // Number of pods.
while(codeLine._height < Stage.height){
numPods++; // Increment the number of pods.
// Attach a single pod to the line of code.
pod = codeLine.attachMovie('one_pod','pod'+numPods,numPods);
codeLine.myCodes.push(pod); // store pod.
// Position pod above the last one (vertical lines)
pod._y -= (pod._height+30) * numPods;
// Choose a random Matrix character.
// Character Codes for lower case letters are between 96 & 123
pod.the_one.Neo.text = chr(Math.round(Math.random() * 27) + 96);
}
// ----------------------------
// Initialize the white pulse.
// ----------------------------
// Store pod position to start at.
codeLine.ind = 0;
// Store delay between pulses.
codeLine.delay = codeLines.myCodes.length;
// ------------------------------------
// Animating each line of code.
// ------------------------------------
codeLine.onEnterFrame = function(){
// -------------------------------
// Vertical animation of the line.
// -------------------------------
// Every frame make the line move down by it's speed.
this._y += this.speed;
// Check if the line of code has animated off the Stage
if(this._y - this._height >= Stage.height) {
// Yes, so allow an additional line to be generated.
maxLines++;
// Remove this line and free memory.
this.removeMovieClip();
}
// ----------------------------
// Animating the white pulse.
// ----------------------------
// Get next pod to affect.
this.curCode = this.myCodes[this.ind];
// If the pod is not currently animating, start its animation.
if(this.curCode._currentframe == 1) this.curCode.play();
// Check if we have reached the end of the line.
if(this.ind < this.myCodes.length and this.delay != 0){
// No, then move on to next character.
this.ind++;
// Decrease the delay before next pulse.
this.delay--;
} else {
// Yes, then reset the character position.
this.ind = 0;
// Reset the delay before next pulse.
this.delay = this.myCodes.length;
}
}
}
}
Thanks for you help


oh yeah the FLA is here http://www.clickfire.biz/jay/matrix.zip

View Replies !    View Related
Matrix Effect Problem
Hello everyone,
I have created the matrix effect through a tutorial.
It works fine, the only problem that i have is that i want the the effect to be behind the text that i have put on. This is all done by using flash 9. How do i do that?
This is the action script:


maxLines = 50;
minScale = 10;
maxScale = 80;

theMatrix = createEmptyMovieClip('MatrixCode',1);
curLines = 0;

theMatrix.onEnterFrame = function(){

if(curLines <= maxLines){
curLines++;

codeLine = this.createEmptyMovieClip('codeLine',curLines);

var ranScale = Math.round(Math.random() * (maxScale-minScale)) + minScale;
codeLine._xscale = codeLine._yscale = ranScale;

codeLine._x = Math.random() * Stage.width;

codeLine.speed = (codeLine._xscale)/10;

codeLine.myCodes = [];
numPods = 0;
while(codeLine._height < Stage.height){
numPods++;

pod = codeLine.attachMovie('one_pod','pod'+numPods,numPo ds);
codeLine.myCodes.push(pod);

pod._y -= (pod._height+2) * numPods;

pod.the_one.Neo.text = chr(Math.round(Math.random() * 27) + 96);
}

codeLine.ind = 0;

codeLine.delay = codeLines.myCodes.length;

codeLine.onEnterFrame = function(){

this._y += this.speed;

if(this._y - this._height >= Stage.height) {

maxLines++;

this.removeMovieClip();
}

this.curCode = this.myCodes[this.ind];

if(this.curCode._currentframe == 1) this.curCode.play();

if(this.ind < this.myCodes.length and this.delay != 0){

this.ind++;

this.delay--;
} else {

this.ind = 0;

this.delay = this.myCodes.length;
}
}
}
}

Thanks for the help.

View Replies !    View Related
Matrix Effect Problem...
Hey guys, i'm new to this board but i hope someone can help me out.

I have the attached matrix code running in scene 1 of my swf. However when i switch to scene 2 i cannot get it to stop!!! any ideas on a script i can put at the end of scene 1 to stop it?

Thanks
Roman

View Replies !    View Related
Matrix Text Effect
A little experiment...

Comments?

View Replies !    View Related
Matrix Effect In Flash
Can u create the matrix effect in mx??? And if yes, how???

View Replies !    View Related
Matrix Text Effect
A little experiment...

Comments?

View Replies !    View Related
Matrix Text Effect?
Some years ago Lee posted a file (I think it was on his blog, but I can't find it) which created the Matrix text effect (where the letters of a word cycle randomly). Does anyone happen to have it lying around or have AS3 code to do this?
Thanks much.

View Replies !    View Related
Ray Of Light And Matrix Bit Stream Effect
No matter how hard I try to figure it out, it never works, so I only settle down with the Ripple effect or other ordinary masking techniques, anyone care to teach me, how to use the effects????

View Replies !    View Related
THE MATRIX CODE EFFECT....and Its Problems
hi there,

yesterday, I tried to make my own Matrix Code Effect with Flash. It worked so far, but then I realised, it's not so easy to animate the letters.

After testing some examples, where the letters began to fall down, the FPS began to stock and everything slowed down. The reason: The bigger the letters, the slower the animation will be. Don't you think so, too?

My Questions to you:

1.) What are the typical characteristics of a "matrix code effect" design?
2.) How can I make my code so fast without getting slower or losing FPS?
3.) Any other Tips?


Greetings

Martin

View Replies !    View Related
Matrix Style Text Effect
Hi, Thanks for helping. I have not been to the site in a while, so if I missed a thread that has already been posted please point the way. Here is the code I copied from the .fla I want to understand.
(I still learning scripting)

function dropStart() {
if (Math.random()>0.9) {
this._visible = true;
this.onEnterFrame = drop;
}
}
function drop() {
// create a trail...
trailName = "trail"+trail;
trail++;
attachMovie("katakana", trailName, trail);
_root[trailName]._x = this._x;
_root[trailName]._y = this._y;
_root[trailName].kata_txt.text = this.kata_txt.text;
_root[trailName].fader_color = new Color(_root[trailName]);
_root[trailName].col = 0xEEFFCC;
_root[trailName].onEnterFrame = fadeTrail;
//
//create a new character at the start of the trail...
this.kata_txt.text = String.fromCharCode(Math.floor(Math.random()*26)+9 7);
this._y += 10;
if (this._y>400) {
this._x = Math.round(Math.random()*550);
this._y = 0;
}
}
function fadeTrail() {
this.col -= 0x101010;
this.fader_color.setRGB(this.col);
if (this.col<0x303030) {
this.removeMovieClip();
if (trail>1000) {
trail = 100;
}
}
}
trail = 100;
for (i=0; i<20; i++) {
newName = "char"+i;
attachMovie("katakana", newName, i);
_root[newName]._x = Math.round(Math.random()*550);
_root[newName].onEnterFrame = dropStart;
_root[newName]._visible = false;
}

.................................................. ...................

this._visible = true;
does "this" refer to the function?

function drop()....that really confuses me.
Can someone please explain.....
trailName = "trail"+trail;
trail++;
and........
_root[trailName]._x = this._x;
_root[trailName]._y = this._y;
_root[trailName].kata_txt.text = this.kata_txt.text;
_root[trailName].fader_color = new Color(_root[trailName]);
_root[trailName].col = 0xEEFFCC;
_root[trailName].onEnterFrame = fadeTrail;

I still have more questions, but this is a great start. Any help is greatly appretiated. Thanks Folks!!!!!!

View Replies !    View Related
Matrix Console Text Effect...
Hey everyone,

I was just wondering how I can make a simple sci-fi matrix looking console text effect saying something like "Mission Objective... Location : Unknown" in the bottom left corner of the screen... Soemthign like CSI.. James bond movies show. If anyone has an FLA or a tutorial for it, I'd really appreciate it! Thank you guys!

View Replies !    View Related
Matrix Text Effect Problem
Hey all,
I'm trying to create a matrx text effect for the background of a gallery. I found a great example from ilyaslamasse (pom) aka ilyas usal,
and modified the actionscript to what i wanted. only problem: no matter what i try, it ends up using 100% of the CPU after mere seconds. as you can see, this would be a problem in the long-run.

for my first keyframe i have:

Code:
/***Author: Ilyas USAL (pom)
Title: The Matrix has you...
Date: 06/06/2003
Version: 2 -- Japanese characters, and it fades from white to green
***/
// To make it run smoother
_quality = "LOWEST";

// String containing all the characters available in the font
letters_str = "unrealtournament,;:!?./$" ;
length_num = letters_str.length ;
for the next layer and kayframe i have:

Code:
/*** Functions ***/
// fade out and remove clip when _alpha inferior to 10 - no parameters
function fadeToBlack(){
this._alpha -= 5;
if (this._alpha < 10){
delete this.onEnterFrame;
this.removeMovieClip();
}
};
// color fade from white to the original color
function whiteToGreen(){
this._alpha -= 5;
if (this.rb < 2 && this.gb < 2 && this.bb < 2){
this.rb = this.gb = this.bb = 0;
delete this.onEnterFrame;
}
else {
this.rb *= .9;
this.gb *= .9;
this.bb *= .9;
}
var trans = {rb:this.rb , gb:this.gb , bb:this.bb};
this.col.setTransform(trans);
};
// Create a new clip with a letter in it
// x: _x position ; y: _y position ; size: size of the letter
MovieClip.prototype.createLetter = function (x,y,size){
// Create and position the new clip
var mc = this.createEmptyMovieClip("letter"+this.dep,this.dep++);
mc._x = x;
mc._y = y;
// Create a new TextField in the clip
mc.createTextField("t",0,0,0,size,size);
// Choose a random letter
var myChar = letters_str.charAt(random(length_num));
mc.t.text = myChar;
// Create the TextFormat, format the text and embed the font
var tf = new TextFormat();
tf.size = size;
tf.font = "Katakana";
tf.selectable = false;
tf.color = "0x00ff00";
mc.t.setTextFormat(tf);
mc.t.embedFonts = true;
// Letter goes from white to green
mc.rb = mc.gb = mc.bb = 255;
mc.col = new Color (mc) ;
mc.col.setTransform({rb:255 , gb:255 , bb:255});
mc.onEnterFrame = whiteToGreen;
};
// Create a trail of letters
function createTrail(){
// Create new clip and position it randomly
var clip = this.createEmptyMovieClip("trail"+i,i++);
clip._x = Math.round(random(Stage.width)/20)*20;
clip._y = clip.y = -20;
// Choose a random size for the letters, and set the spacing
var size = random(20)+15;
clip.spacing = size ;
// onEnterFrame, create a new letter that will wade out.
// if we're at the bottom of the screen, fade out the whole trail
clip.onEnterFrame = function(){
this.y += this.spacing;
this.createLetter(0,this.y,size);
if (this.y > Stage.height) this.onEnterFrame = fadeToBlack;
};
};
and for the final layer and keyframe i have:

Code:
// Create a new trail every 100 milliseconds
setInterval(this,"createTrail",100);
here's a sample i exported: matrix swf


any help?

View Replies !    View Related
Matrix Effect Not Working In MX 2004
****Update****** I partially figured out what was causing this not to working MX 2004. See code changes below. Flash 7 did not know how to handle the undefined variables (+this.dep, this.dep++) or (+i,i++) in the createEmptyMovieClip. Had to change then to this.getNextHighestDepth(). However this is causing the color change routine not to work since there is no true depth number assigned. Setting up a trace to view color change the color change returns undefined. The script does not seem to know which instance of the MC to apply the color change to since there are multiple dynamic MC’s

If someone knows how to correct this it would be a big help!!
*******
I have been playing with the different examples of the Matrix code effect when I found the one created by Ilyas USAL (pom) who I see posts to this forum in the past. So I am hoping POM sees this or someone who know POM will let him or her know I could use some advice on how to get this to work with MX 2004.

Here is the original code:
Layer 1 Frame 1

// To make it run smoother
_quality = "MEDIUM";

// String containing all the characters available in the font
letters_str = "abcdefghijkl1234567890,;:!?./$" ;
length_num = letters_str.length ;


Layer 2 Frame 1

/*** Functions ***/
// fade out and remove clip when _alpha inferior to 10 - no parameters
function fadeToBlack(){
this._alpha -= 5;
if (this._alpha < 10){
delete this.onEnterFrame;
this.removeMovieClip();
}
};
// color fade from white to the original color
function whiteToGreen(){
this._alpha -= 3;
if (this.rb < 2 && this.gb < 2 && this.bb < 2){
this.rb = this.gb = this.bb = 0;
delete this.onEnterFrame;
}
else {
this.rb *= .9;
this.gb *= .9;
this.bb *= .9;
}
var trans = {rb:this.rb , gb:this.gb , bb:this.bb};
this.col.setTransform(trans);
};
// Create a new clip with a letter in it
// x: _x position ; y: _y position ; size: size of the letter
MovieClip.prototype.createLetter = function (x,y,size){
// Create and position the new clip
//var mc = this.createEmptyMovieClip("letter"+this.dep,this.d ep++); old code
var mc = this.createEmptyMovieClip("letter",this.getNextHig hestDepth()); New code
mc._x = x;
mc._y = y;
// Create a new TextField in the clip
mc.createTextField("t",0,0,0,size,size);
// Choose a random letter
var myChar = letters_str.charAt(random(length_num));
mc.t.text = myChar;
// Create the TextFormat, format the text and embed the font
var tf = new TextFormat();
tf.size = size;
tf.font = "Katakana";
tf.selectable = false;
tf.color = "0x00ff00";
mc.t.setTextFormat(tf);
mc.t.embedFonts = true;
// Letter goes from white to green
mc.rb = mc.gb = mc.bb = 255;
mc.col = new Color (mc) ;
mc.col.setTransform({rb:255 , gb:255 , bb:255});
mc.onEnterFrame = whiteToGreen;
};
// Create a trail of letters
function createTrail(){
// Create new clip and position it randomly
//var clip = this.createEmptyMovieClip("trail"+i,i++); old code
var clip = this.createEmptyMovieClip("trail"this.getNextHighe stDepth()); new code
clip._x = Math.round(random(Stage.width)/10)*10;
clip._y = clip.y = -10;
// Choose a random size for the letters, and set the spacing
var size = random(10)+15;
clip.spacing = size ;
// onEnterFrame, create a new letter that will wade out.
// if we're at the bottom of the screen, fade out the whole trail
clip.onEnterFrame = function(){
this.y += this.spacing;
this.createLetter(0,this.y,size);
if (this.y > Stage.height) this.onEnterFrame = fadeToBlack;
};
};

Layer 3 Frame 1

// Create a new trail every 100 milliseconds
setInterval(this,"createTrail",100);


I like the simplicity of the code and I have a good understanding of how it is working. I have even made changes to get different effects and have embedded it in other flash movies I have played with to see if I could.

The problem is as follows. If I set my publish environment to Flash player 6 and actionscript 1.0 everything works fine. If I change the publish environment to Flash player 7 and actionscript 1.0 or 2.0 then the effect no longer functions correctly. There appears to be some variable or element that needs to be change. The Flash 7 compiler does not seem to parse the code in the same way the Flash 6 compiler is.

I get random single characters but no trailing characters. I slowed the timing down so I could see what was happening and everything but the colored characters is appearing. Stepping through the code revealed that the function whiteToGreen() does not appear to be working correctly or being called correctly.

Looking for someone with more knowledge in this than me. Hopefully the author will see this and know how to correct it.

Thanks
Fishman9

View Replies !    View Related
Matrix Text Effect Problem
Hey all,
I'm trying to create a matrx text effect for the background of a gallery. I found a great example from ilyaslamasse (pom) aka ilyas usal,
and modified the actionscript to what i wanted. only problem: no matter what i try, it ends up using 100% of the CPU after mere seconds. as you can see, this would be a problem in the long-run.

for my first keyframe i have:

Code:
/***Author: Ilyas USAL (pom)
Title: The Matrix has you...
Date: 06/06/2003
Version: 2 -- Japanese characters, and it fades from white to green
***/
// To make it run smoother
_quality = "LOWEST";

// String containing all the characters available in the font
letters_str = "unrealtournament,;:!?./$" ;
length_num = letters_str.length ;
for the next layer and kayframe i have:

Code:
/*** Functions ***/
// fade out and remove clip when _alpha inferior to 10 - no parameters
function fadeToBlack(){
this._alpha -= 5;
if (this._alpha < 10){
delete this.onEnterFrame;
this.removeMovieClip();
}
};
// color fade from white to the original color
function whiteToGreen(){
this._alpha -= 5;
if (this.rb < 2 && this.gb < 2 && this.bb < 2){
this.rb = this.gb = this.bb = 0;
delete this.onEnterFrame;
}
else {
this.rb *= .9;
this.gb *= .9;
this.bb *= .9;
}
var trans = {rb:this.rb , gb:this.gb , bb:this.bb};
this.col.setTransform(trans);
};
// Create a new clip with a letter in it
// x: _x position ; y: _y position ; size: size of the letter
MovieClip.prototype.createLetter = function (x,y,size){
// Create and position the new clip
var mc = this.createEmptyMovieClip("letter"+this.dep,this.dep++);
mc._x = x;
mc._y = y;
// Create a new TextField in the clip
mc.createTextField("t",0,0,0,size,size);
// Choose a random letter
var myChar = letters_str.charAt(random(length_num));
mc.t.text = myChar;
// Create the TextFormat, format the text and embed the font
var tf = new TextFormat();
tf.size = size;
tf.font = "Katakana";
tf.selectable = false;
tf.color = "0x00ff00";
mc.t.setTextFormat(tf);
mc.t.embedFonts = true;
// Letter goes from white to green
mc.rb = mc.gb = mc.bb = 255;
mc.col = new Color (mc) ;
mc.col.setTransform({rb:255 , gb:255 , bb:255});
mc.onEnterFrame = whiteToGreen;
};
// Create a trail of letters
function createTrail(){
// Create new clip and position it randomly
var clip = this.createEmptyMovieClip("trail"+i,i++);
clip._x = Math.round(random(Stage.width)/20)*20;
clip._y = clip.y = -20;
// Choose a random size for the letters, and set the spacing
var size = random(20)+15;
clip.spacing = size ;
// onEnterFrame, create a new letter that will wade out.
// if we're at the bottom of the screen, fade out the whole trail
clip.onEnterFrame = function(){
this.y += this.spacing;
this.createLetter(0,this.y,size);
if (this.y > Stage.height) this.onEnterFrame = fadeToBlack;
};
};
and for the final layer and keyframe i have:

Code:
// Create a new trail every 100 milliseconds
setInterval(this,"createTrail",100);
here's a sample i exported: matrix swf


any help?

View Replies !    View Related
The Matrix Bitstream Effect, I Keep Getting Script Errors
I'm learning to use Flash so I was trying to do the Matrix Bitstream effect described here: http://www.flashkit.com/tutorials/Sp...-152/more2.php

Anyway, it tells me to put this line of code for the first frame of the movie clip symbole:

Set Variable: "index" = 0
Set Variable: "loop" = Int (Random (10))

and this line of code for the 5th frame of the symbole

If (index<=loop)
Set Variable: "index" = index+1
Go to and Play (2)
End If

They tell me to re-use the same lines of code a couple of times and to put a STOP actionscript on my main timeline.

But I get like 5-6 script errors and the bitstream effect isn't random at all.

I'm not sure if it's because I'm using Flash MX 2004...

View Replies !    View Related
Flash Script - Matrix Text Effect
This is a dedicated thread for discussing the SitePoint article 'Flash Script - Matrix Text Effect'

View Replies !    View Related
Card Turning / Flipping Effect With A Transform Matrix
Anyway, I made this real basic memory game yesterday:

http://morphcham.com/memory/

and I just want to get a less wonky card flipping effect when each card is turned. I'm doing this with matrix tranformations and I know there is a science to skewing things, scaling them and translating them predictably. I just don't get it yet.

So with my current (let's call it "wonky") effect, I am just scaling it and translating it, but I would like to add some skew in order to make the card look like it's being lifted over.

Does anybody know how to explain this kind of stuff, or know of a good tutorial to get me started? Thanks. I'm a pretty fast learner, and sort of know a little math, so I should be able to figure it out if I can find any leads at all.

Thanks ya'll,
Chimpy

View Replies !    View Related
Help On Creating A Similar Matrix Text Effect Outputting DNA Sequences
DNA Matrix Text Effect
Hey!! i'm kinda new to actionscripting for flash and I wonder if there is a way to make a flash that is similiar to the matrix text effect. Rather than outputting random numbers and letters, it will output only A,T,C,G randomly. Please help out. Here's the matrix code I've found on the net...Please help...thx ^^

Stage.scaleMode = "noScale";

var stageWidth = 500;
var fp = Function.prototype;

fp.setInterval = function(obj, ms, params) {
return setInterval(function(fcn) {
fcn.apply(obj, params);
}, ms, this);
};

fp.createDerivedMC = function(timeline, name, level) {
var mcp = MovieClip.prototype;
MovieClip.prototype = this.prototype;
var newmc = timeline.createEmptyMovieClip(name, level);
MovieClip.prototype = mcp;
this.apply(newmc, arguments.slice(3));
return newmc;
};

delete fp;

TextField.prototype.writeln = function(tx) {
this.text += tx + "
";
};

var o = _global.MatrixLetters = function(v) {
this.v = v;
this.t = getTimer();
};

o = o.prototype = new MovieClip();

o.onEnterFrame = function() {
this._y += 5 * this.v;
if(getTimer() >= (this.t+2000)) this.removeMovieClip();
};

var letters = [], vel, letter = 0;
for(var i = 36; i-- letters.unshift(i.toString(36));

var mc, tf, generator = function() {
vel = Math.floor(Math.random()*20);
mc = MatrixLetters.createDerivedMC(this, "l" + letter, letter++, vel);
mc._x = Math.floor(Math.random()*stageWidth);
mc.createTextField("letters", 0, 0, 0, 0, 0);
(tf = mc.letters).setNewTextFormat(
new TextFormat("Courier New", 12, 0x00FF00)
);
tf.autoSize = true;
for(var i = random(10)+10; i-- {
tf.writeln(letters[random(letters.length)]);
};
};

generator.setInterval(this, 100);

View Replies !    View Related
Logic Help: Matrix.b Based Upon Matrix.a Values
Hi ya,

I have always had a hard time figuring out the best way to make a relationship between 2 changing values. Often times I use percents, but in this case that wont work very well.

Anyway, I'd like for the attached movieclip to scale up and then scale back down (and maybe one dip down some). What is the best way to corolate (sp?) these two values?

Cheers



ActionScript Code:
import flash.geom.Matrix;

// set up Matrix filter
var matrix:Matrix = new Matrix();
var totalSkew:Number= -0.3;
matrix.tx = text_mc._x;
matrix.ty = text_mc._y;

// initialize degress and radians
// conversion: radians = degrees * (Math.PI/180);
var radians:Number = 0;
var degrees:Number = 0;

text_mc.onEnterFrame = function():Void
{
    // increment the degrees of rotation and convert to radians
    degrees += 3;
    radians = degrees * (Math.PI/180);
   
    // calculate x scaling
    matrix.a = Math.round(100 * Math.cos(radians)) / 100;
   
    // calculate y skewing
    var range:Number = degrees % 91;
    var percent:Number = (range / 90);
    matrix.b = percent * totalSkew;
   
    // apply transformation
    text_mc.transform.matrix = matrix;
   
}

View Replies !    View Related
[FMX] Matrix Algebra And Matrix Inverse
Has anyone here ever developed a function (or general library of relevant functions) that will allow one to find the inverse of a matrix? I've searched the forum archives, as well as the internet more generally, but haven't found anything. If anyone has some leads, I hope you'll pass them along.

If I don't hear anything within the next few days, I might try to develop something on my own, but I'd hate to do so if someone has already done the dirty work.

A solution to this problem would be very useful for 3-D work or anyone doing mathematical programming more generally.

Thanks,
Chris

View Replies !    View Related
Matrix
Is possible to make matrix on ActionScript? you know and 2D array?

View Replies !    View Related
Matrix Help Plz
Hello!

I got this problem. a client wants a animation on his page, it will look like "Matrix text Fall" .. anyone know how to do that ?? please help me asap!

/micke

View Replies !    View Related
Matrix...
Ok, this is how the books shows it:


Code:
_root.createEmptyMovieClip("myMovie", 1);
with (_root.myMovie) {
colors = [0xFF0000, 0x0000FF];
alphas = [100, 100];
ratios = [0, 0xFF];
matrix = { a:200, b:0, c:0, d:0, e:200, f:0, g:200, h:200, i:1};
beginGradientFill("linear", colors, alphas, ratios, matrix);
moveto(100, 100);
lineto(100, 300);
lineto(300, 300);
lineto(300, 100);
lineto(100, 100);
endFill();
}


Obviously this makes a gradient box, pretty dull considering the amount of code. But this is not my problem...

Later on the book gives yet another sample like that, just that the matrix parameter shows like this:



Code:
matrix = {matrixType:"box", x:100, y:100, w:200, h:200, r: (45/180)*Math.PI};


This one I pretty much understand, x and y being the coordinates, and w and h being width and height. The r stands for radius, of course...

But what is a, b, c, d, e, f, g, h, i in the first example? And why is i always equal 1? Anybody can explain this?

The book says the letters stand for a matrix like this:

a, b, c
d, e, f
g, h, i

But I still don't get it...

View Replies !    View Related
Matrix Like?
How do i create a matrix-like camera trick within flashMX?

View Replies !    View Related
The Matrix
hi i am making a the matrix reloaded website and i am making an intro for it too

this is my site

well i have a gif, of the code going down the screen but i want it to run on a certain frame, and fill the whole screen...

how can i do this?.... someone please help me?

James

View Replies !    View Related
Mc Matrix
if i want to have a huge grid of attached movie clips on the stage, all interacting with eachother, does anyone know of any specific limitations as to how many mc's I can use?

View Replies !    View Related
The Matrix
Someone wanna help me make the matrix?

View Replies !    View Related
Matrix FX
I wanted to know if anybody could help me with matrix effects like the characters shadow type thing that follows them.

View Replies !    View Related
Matrix?
Hi, can anyone help me with creating a matrix? Currently I'm using this code for a 10x10 matrix:

v1 = 0
while (v1<9) {
v2 = 0
while (v2<0) {
set("matrix" add v1 add v2, 0)
v2 = v2 + 1
}
v1 = v1 + 1
}
// just to test if I assigned 0 to the right variable
v1 = 4
v2 = 6
test = "matrix" add v1 add v2


Well, the problem is, creating 100 variables as a matrix works, but how I do use the variables?
test became "matrix46" (as text), but I wanted the variable "matrix46", how I do I write that?

Thanks in advance!
-Shin

View Replies !    View Related
Why Matrix?
Hi

I've been trying to get in to the Matrix Class in AS3, but I don't get it.

What's it's perpose?
Except transforming a shape, what can it do?

Can you give me some links and stuff, good tutorials or inspiration?

I need to know if it's worth the effort of trying to learn it in a deep level.

//Mikael

View Replies !    View Related
Matrix
have a couple of cascaded MC's each have diferent Matrixtransformations on them

let's say for now Master & Master.Slave

now i rotate the Master by 45º

so the Master & the Slave is rotated (this shoud by so)

now i wana Scale the Slave
and here coms the problem !
it's scales BUT in the coordinatesystem of the Master !
and tath shoud NOT by !!!

how can i calculate this ?????

see code for more :


Code:
_root.createEmptyMovieClip("Master", 0);
TM = new flash.geom.Transform(Master);
_bmp1 = new flash.display.BitmapData(150, 150, false, 0x00FF0000);
Master.attachBitmap(_bmp1, 0);
Master.createEmptyMovieClip("Slave", 1);
TS = new flash.geom.Transform(Master.Slave);
_bmp2 = new flash.display.BitmapData(50, 50, false, 0x000000FF);
Master.Slave.attachBitmap(_bmp2, 1);
//
M = new flash.geom.Matrix();
M.translate(100, 50);
TM.matrix = M;
//Rotate Master
M.identity();
M.rotate(45/180*Math.PI);
Tmp = TM.matrix.clone();
M.concat(Tmp);
TM.matrix = M;
//Scale Slave
M.identity();
M.scale(2, 1);
Tmp = TS.matrix.clone();
M.concat(Tmp);
TS.matrix = M;
////////////////////////////
//
//
//This is how it shoud look :
//
_root.createEmptyMovieClip("Master1", 1);
TM1 = new flash.geom.Transform(Master1);
_bmp1 = new flash.display.BitmapData(150, 150, false, 0x00FF0000);
Master1.attachBitmap(_bmp1, 0);
_root.createEmptyMovieClip("Slave1", 2);
TS1 = new flash.geom.Transform(Slave1);
_bmp2 = new flash.display.BitmapData(50, 50, false, 0x000000FF);
Slave1.attachBitmap(_bmp2, 1);
//
M = new flash.geom.Matrix();
M.translate(350, 50);
TM1.matrix = M;
TS1.matrix = M;
//
M.identity();
M.rotate(45/180*Math.PI);
Tmp = TM1.matrix.clone();
M.concat(Tmp);
TM1.matrix = M;
M.identity();
M.rotate(45/180*Math.PI);
Tmp = TS1.matrix.clone();
M.concat(Tmp);
TS1.matrix = M;
//
M.identity();
Orgmatrix = TS1.matrix.clone();
M.a = 2;
M.d = 1;
//
M.tx = Orgmatrix.tx;
M.ty = Orgmatrix.ty;
//
Orgmatrix.tx = 0;
Orgmatrix.ty = 0;
Orgmatrix.concat(M);
TS1.matrix = Orgmatrix;

View Replies !    View Related
Like In Matrix
there is this kind of text effet like in Matrix....
http://www.calwhite.com/pix/matrix%20001.jpg
the animation of text that falling like rain.....
how can i do this ?

View Replies !    View Related
Copyright © 2005-08 www.BigResource.com, All rights reserved