Converting A Simple AS2 File To AS3. Pic Loop Bar.
Hi everyone. I'm no expert on Actionscript 3.0. I'm wondering if someone had a suggestion on how to fix my AS3 code.
Here's the AS2 loop picture bar code. Works perfect.
_root.pics.onEnterFrame=function(){ _root.pics._x+=(86-_root._xmouse)/33.3;
if(this._x>0){ this._x=-300; } if(this._x<-300){ this._x=0; } }
Then I was trying to update to AS3. There's something obvious I'm missing, no?
pics.addEventListener(Event.ENTER_FRAME, onEnterFrame);
pics.x+=(86-mouseX)/33.3;
if(this.x>0){ this.x=-300; } if(this.x<-300){ this.x=0; }
thanks kindly for any suggestions!
ActionScript.org Forums > ActionScript Forums Group > ActionScript 3.0
Posted on: 06-07-2008, 07:05 PM
View Complete Forum Thread with Replies
See Related Forum Messages: Follow the Links Below to View Complete Thread
Converting A PDF To A Flash FLA File Without Converting To An Image First?
Basically, I'm building a digital catalogue that runs off a CD and uses a Flash 'page turning component' to display the pages. Certain pages will have links that use Flash's Fscommand call to open Word and Excel documents.
Has anyone got any bright ideas of how to Convert a PDF to a Flash FLA file without converting to an image first?
I know I can open a PDF in Photoshop, save as a PNG or JPG and then import this into Flash, however the quality isn't brilliant. If you use a hi-res image, then you get a hi-res file size...
Currently, the best way I have found, is to open the PDF in Illustrator, then export it as a SWF. Illustrator converts all text to shapes and you end up with a small SWF, yet great quality when displayed in larger sizes. As I'm currently using a page turning flash component that loads SWF files, I need the quality to be good for the 'Zoom' function.
I've found an Illustrator script that will do the hard work via a 'batch' process, so I can take a 100 page PDF and convert the whole lot to 100 SWF files while I drink tea and 'look busy' and read a magazine, but the problem I have is that I need to add a layer of buttons to several of the SWF files to add a little functionality....
I do have a SWF to FLA decompiler which does a good job, however because Illustrator turns everything into shapes, the decompiler does the same and you end up with thousands of files in the library.... Plus there are a lot of error messages when the file is first loaded...
Many layers are masked, (for some reason without a fill), so if you publish the decompiled file straight away, you just get a blank file. Once you go through and fill the masks needed, it shows when you publish, but this really is a lot of work and I've had a few pages that show when you open the SWF file, but don't show when the SWF is called into the page turning file.... Hmmm....
So in short, I'd like to take a PDF and convert it to a FLA file, add a layer of buttons and publish as a SWF file....
Anyone got any 'Pearls of Wisdom'?
Clere
Clere Print
Converting Swf File To Broadcast Quality Movie File
I'm using a Patrick Jansen effect in flash and if I try to export it the way I usually do for movie credits - ie export to quicktime - all I get is a grey box. The only way I can get the movie into a quicktime file correctly is to save the file as an swf then use "swf and flv player" to export each frame as a tif then recompile in quicktime.
Is there a program that will convert the SWF to quicktime in one go and keep the quality? It's for a movie, so I need it very high res.
thanks in advance,
(mac os x 10.4.9 G5 dual 2ghz, internal 250 and 350hd, external 500gb, 4gb ram)
Converting Simple Effects Into ActionScripts...
I have a drag & drop I am working on where 'object A' is draged upon 'target A'. Once dropped, 'object A' plays frames in it’s own timeline where it sizes and fades. I need to simplify this by having the _alpha, _xscale & _yscale change when 'onject A' is dropped on 'target A'.
NOTE: I need a subtle fade and shrinking of 'object A' and not instant.
Any help will be much appreciated.
-Waneman
AS - Help Converting Simple PHP Form To Flash
Hi all,
I have a project management tool built entirely in PHP. I'de like to have clients be able to log into it from my flash portfolio site, but am having trouble converting the PHP login to a flash form. Any help would be appreciated, here is the form.
PHP Code:
<form action="http://website.com/projects/index.php?c=access&a=login" method="post">
<label for="loginUsername">Username:</label>
<input id="loginUsername" class="medium" type="text" name="login[username]" value="" />
<label for="loginPassword">Password:</label>
<input id="loginPassword" class="medium" type="password" name="login[password]" value="" />
<input id="loginRememberMe" type="checkbox" class="checkbox" name="login[remember]" value="checked" />
<label class="checkbox" for="loginRememberMe">Remember me for 14 days</label>
<button class="submit" type="submit" accesskey="s">Login</button>(<a href="http://website.com/projects/index.php?c=access&a=forgot_password">Forgot password?</a>)
<!-- <p><a href="http://website.com/projects/index.php?c=access&a=forgot_password">Forgot password</a></p> -->
</form>
Converting Midi File Into Wave File
Hey folks. Is there a program that I can use that will convert midi sound files to wave files to use in flash?
Any URL or workaround would be helpful.
Problem Converting An MPEG File Into .FLV File
HI
I want to convert an video file into .FLV. I have imported an .MPEG file into the flash and i am trying to export as .Flv file but i culdnt find any option how to do that in flash mx 2004. Please can any one can help me in this concern....
Thanks in Advance
Ashirwad
Simple Converting As2 To As3 Help Requierd: FLV Video Player
Hello I found a perfect video player but the only problem i got is its in as2.. can someone help me convert it?
its a very basic code yes i no this but, i just suck with the new as3, but as2 is simple well was lol..
>Source:
Creating a Video Portfolio (FLV Video Player) in Flash
http://www.oman3d.com/tutorials/flash/video_portfolio/
>Now for the code it came with [as2]:
Code:
my1_btn.onRelease = function (){
myPlayer.contentPath = "video1.flv";
}
my2_btn.onRelease = function (){
myPlayer.contentPath = "video2.flv";
}
>And the convert i attempted to convert but failed [as3]:
Code:
function my1_btn(e:MouseEvent):void {
myPlayer.content.load(video1.flv);
}
function my2_btn(e:MouseEvent):void {
myPlayer.content.load(video2.flv);
}
Simple Question - Converting Entire Stage To Movieclip
I have created a pretty simple animation on the stage with several layers and movieclips. I now realize that I want to convert everything on the root timeline to a movieclip so I can easily move it over into another project's library.
What's the procedure to do this? I know I've done it once before, but I don't recall how.
Thanks.
Converting File
Ok I know I ask alot of questions. Thx for Helping me.
Ok I made my site on word ( for my first site) Now im told i need a converter to put it into the internet??? Um how can I put my word website/file into the internet. Thx
Jake
Converting Web/File
Ok I know I ask alot of questions. Thx for Helping me.
Ok I made my site on word ( for my first site) Now im told i need a converter to put it into the internet??? Um how can I put my word website/file into the internet. Thx
Jake
Converting An AS2.0 File To AS3.0?
Hey everyone,
I have a CS3 file that was given to me to make some changes to.
It was written in AS2.0, but I would like to implement some new AS3.0 classes.
Is there any way to convert this file to an AS3.0 file? I'd really like to avoid re-creating the entire .fla.
Thanks in advance for any thoughts!
Converting An AS2.0 File To AS3.0?
Hey everyone,
I have a CS3 file that was given to me to make some changes to.
It was written in AS2.0, but I would like to implement some new AS3.0 classes.
Is there any way to convert this file to an AS3.0 file? I'd really like to avoid re-creating the entire .fla.
Thanks in advance for any thoughts!
Help Converting File
I hope I can get some help here.
In a nutshell, I've made a 15-minute flash video for a friend's wedding. Basically it's a glorified slideshow, but several people asked for a copy. I'd like to provide copies as DVDs people can just stick in and play, particularly since many of them are blue-haired great aunts that won't necessarily have the latest and greatest computers, or any computer for that matter.
Does anyone out there have an angle on how to convert a Flash video into a straightforward movie format? I'm not a developer, so basically, I'm looking to pay someone to just take care of it for me.
Any leads would be greatly appreciated.
Thanks!
Converting A File Too Use In Flash
Was wondering if anyone here can tell me how too convert a DEM file from Half-life into a movie so that i can make a flash intro too there site?
Converting .txt File To Array
Hi,
I have a text file, which has large arrays in it of this format,
&Array1 = [2, 2, 2, 2, 2, 2, 2, 2, 2, etc etc etc ];
&Array2 = [2, 2, 2, 2, 2, 2, 2, 2, 2, etc etc etc ];
I need these loaded in at the begining of my movie (before any other actionscript can run), and converted to arrays in my Flash movie. When I do loadvariables, it just loads the text file in as a string, but I need it as a array.
How would I do that?
thanks for any help.
phil.
Converting SWF To Gif Animation File
Is that possible? I notice that under "Publish", it gives me the option to publish the file to Gif, but it only shows up the background image. Please help.
Converting To QuickTime File
Hello
I have a problem converting Flash 8 movie to Quick Time movie
I am using Export Movie command: selecting Quick Time file type, choosing needed options (kipping file flatten), setting Flash version to Flash Player 5, as asked.
I have a .mov file as a result, but it plays only in my computer; if I send this file to somebody else via email, it does not work anymore.
I tried to publish the movie as QuickTime – still the same result.
The size of that .mov file is equal to the size of the original .fla file, which is not right at all.
I remember, when I had Flash 5, there were no problems converting Flash movies to QuickTime movies, but now I spoke with several people, it seems like everybody have the same problem.
I would very appreciate, if somebody could help me
Thank you
Converting A MX 2004 File To MX
Hi,
I've been having trouble converting a .fla file from MX 2004 to MX.
I tried Save As Flash MX Document but when I openned it with MX it gave an error, Unexpected File Format.
I searched the forums but didn't have much success.
Does anyone know how can I convert it?
My main traget is to use Symbols I've created, I do have AS code but it's less important.
Thanks!
WMV File Not Converting To FLV Properly
I am trying to use the Flash Video Encoder to convert a WMV file that a client provided to me into an FLV file. The audio works fine in the FLV, but the image stays stuck on the first frame through the whole movie.
This file needs to be uploaded by tomorrow. I've tried compressing with about 6 different compression settings (both in Sorenson and the newer On2 VP6 codecs).
I'm about to rip my hair out.
I even downloaded a trial version of Adobe Premiere Pro CS3 to export it and it's taking an hour to do so. My suspision is that it wont work in there either.
Edited: 09/08/2007 at 08:51:28 PM by ThinkSeed
Converting Flash File To Gif?
Is there a way to export or convert a flash file to a picture file? Even if I go through fireworks? How would I get my flash animation imported into Fireworks???
Thanks,
vv
Converting Video File In FLV In Runtime
Hi,
I am working on a site where user can upload his video files like mpeg,avi,mov etc and i have to display that file in flash in FLV format so that its size will be minimum.
Is it possible ?
thanks for any help.
Converting An Number In A Text File To A Variable
I'm tried this a hundred ways, and can't seem to get it to work. I'm trying to get my flash file to read a number from an external text file (in form: &var0100=4&) and have the flash file go to a specific frame number based on this variable. This code works if I import it into a text file, but I can't get it to take what's in the text file and convert it to a variable. Here's my following code:
totalprojects = new LoadVars();
totalprojects.load("rmptext.txt");
totalprojects.onLoad = function(right) {
if (right) {
trace("done loading");
total.Number = this.var0100
if (Number(total) < 5) {
projectmovie.gotoAndStop(2);
}
else {
projectmovie.gotoAndStop(3);
}
}
else {
trace("not loaded");
}
};
stop();
Problem Converting Flash File To Animated .Gif
I've never made an animated gif from a flash file but the flash help says to simply do the following:
Flash exports the first frame in the movie as a GIF, unless you mark a different keyframe for export by entering the frame label
#Static. Flash exports all the frames in the current movie to an animated GIF unless you specify a range of frames for export by
entering the frame labels #First and #Last in the appropriate keyframes.
No matter what I try, when I export to an animated gif, the image that shows up is not animated but I only get the first frame. What could be missing and what areas should I check? Thanks in advance.
[CS3] Simple Image Loop Not So Simple
I'm relatively new to Flash - I can do some basic animations but very little actionscript.
I'm looking for a tutorial to have a set of images scroll across and repeat themselves.
this is what I'd like... example
I can do a continuous loop of a simple background image with the 'goto' function, but I can't even find a tutorial on how to repeat individual images.
Any suggestions?
Thanks,
JTN
Importing Strings Into A Text File And Converting Them In The Movie For Use.
I have a text file, in that text file there are several strings that look like this.
&&S1=[room,250,1]&&
&&S2=[room,252,1]&&
&&totalRooms =2&&
Any they go on like that. Now what I am wanting to do is to load this text file and convert the strings into items that can be used in the movie.
The code I have tried using for this is
code:
function buildInfo() {
for (i=1; i<=totalrooms; ++i) {
foo = "T"+i;
foo2 = "S" + i;
foo = foo2.split(",");
trace("foo:"+foo[0]);
}
}
Now I was expecting this to make the S1 into T1 with the information from text file. This is not working, when I run the movie the trace("foo:"+foo[0]); returns the actual name of the S1 file and that is it. I am just not sure what I am doing wrong. Thank you for any help. I f I have not made myself clear enough, please let me know.
Converting After Effects Scene To Swf FILE SIZE Question
I have created an introduction for a website and exported it from After Effects at 640 x 480 into Quicktime. The clip is 10 secs long and renders out to 14 megs. I have Sorenson Squeezed it 780 KBs.
Is this a good size? Or should I try another route? Is so which one?
What is a good standard file size for the web?
Converting Flash Scripts Inside .fla Into External .as File?
Hi, I have a client that for some reason they are wanting to convert their .fla project and break up the 8 script layers of their game, and put it in an external .as file for the Flash project.
I was just wondering if this could be done could someone show me a link, tutorial or anything on how I would go about doing this, and why this needs to be done this way?
Easy implementation for future games of the same kind?
Retriveing Date Variables From Text File/ Converting Strings To Dates
Hi,
I'm trying to read date variables from an external text file. I'm using the LoadVars method and it is working fine for regular string variables. I'm running into trouble trying to convert some of those strings into date variables so I can compare the current date to the targetDateX variable from the text file. I'm working on a countdown timer for a list of different times/dates. It will display the time left until the first event, then after that event the time left until the second event. I'm running the code in a for loop and everything is working except being able to convert the string with format (yyyy,mm,dd,hh,mm) into a date variable- I've attached a sample of where I'm having trouble.
Thanks in advance for any help! :)
Attach Code
var targetDateX:String = "targetDate" + i;
//sets a variable targetDateX equal to the variable targetDate(i) so that you can read it from the text file
var targetDateA:Date = new Date (this[targetDateX]);
//attempting to set it into a date format
trace (this[targetDateX]);
//returns the variable stored with the name targetDate(i) in the text file
trace (targetDateA);
// returns 'Invalid Date'
Edited: 11/09/2008 at 12:45:04 PM by wyattr1
Converting And .swf File Into A .fla File
Sorry if this topic has already been posted (the search feature wasn't working).
I was just wondering if there was any way to convert an .swf file into a .fla file. I have been doing some flash work on two computers and was copying the files to just one of them. Unfortunately I only copied an .swf file of one of them and deleted the .fla file. So I was just wondering whether there's any way to convert it into the .fla file.
SIMPLE LOOP-D-LOOP
I have a tween that is 20 frames long nested in a MC.
Is there a way to set it to loop a specific amount of times and then stop? Similiar to the sound loop option?
Does someone have a little code or something to point me in the right direction?
Thanks!
Simple Loop
Hi there,
well, I'am new in actionscripting and now I try to get started...
But now I've got a little problem...(I know, the solution will be
quiet easy.
I was trying to creat a little loop in actionscript, which allows me to give a variable every time it is recalled a bigger worth. (e.g +1)
How should such a movie look like?
Hope somebody can help me
Thanks
Daniel,
Germany
Simple Loop - DOH
hi guys,
could you please help me with a crazily simple probelm that I cant seem to figure out!!!
okay, i have all these items that I have to collect... dot0, dot1, dot2, dot3 etc. What I need to do is to set up a loop. here is what I have done so far ,but what am I missing???
Code:
for (i=0; i<dots; i++) {
if (_root.dot[i].hitTest(this)) {
_root.dot[i].gotoAndStop(2);
trace ("aaahhhh finally!!!");
}
}
btw: dots = 8
thanks guys!!!
A Simple Loop
i am really new to this stuff, can anyone show me how to use a simple loop?
Simple Loop
OK- I have a simple loop running off of my main timeline. On a certain fram, I would like this movie to stop.
How can I write this? Any help is much appreciated.
Thanks!
Simple Loop?
I have a intro that I have a goto and play 1 on frame 50 I want it to loop about 4-5 times and then after the 4 or 5 run it does a geturl command. What lines do I add to achive this loop effect?
Simple For Loop Please Help
Here is my loop with syntax errors
PHP Code:
for(i=1; i<5; i++)
{["Bn" + i ]onRollOver=function(){ gotoAndStop("_over");
}
["Bn" + i ]onPress=function(){gotoAndPlay("_down");
}
["Bn" + i ]onRelease=function(){gotoAndstop("_down");
}
["Bn" + i ]onRollOut=function(){gotoAndStop("_up");
}
["Bn" + i ]hitArea =["hit" + i ]_mc;
["hit" + i ]_mc._visible = false;
};
I've been fiddling with the code but I feel like I'm just hacking away. I've read through all my Flash books, 5 in total, and I still can't figure it out.
This should be basic programming correct?
thanks for the help.
Help With Simple For Loop
Hi there. i am making a simple photo gallery where when a button is clicked (in this example the button is 'custom'), then a function is called with the variables type and num. it will then make a menu based on type (the folder to open the pics from) and num (the number of pics in that folder). it is easy to understand i think. the problem is that the for loop doesnt work. i have a trace in there that never gets 'traced. can anyone help me with this?
thanks,
chris
Code:
custom.onPress = function() {
openpics("custom", 5);
};
//stop movement
stop();
//define the function - type of pic defines the folder that you
//want to open the pictures of, and num says how many pics are in that
//folder. the pics are numbered "1.jpg","2.jpg"... so they can
//be loaded easily with a for loop from the links created
function openpics(type, num) {
//create 'clickable' numbers to display each pic
for (var i = 1; i>num; i++) {
i = 1;
this.createEmptyMovieClip("number_"+i, i);
number_i._x = 15*i;
number_i._y = 10;
trace(i+" "+number_i+" "+type+" "+num);
number_i.createTextField("text_"+i, i, 0, 0);
text_i.font = "Arial";
text_i.size = 10;
text_i.color = 0xFFFFFF;
//change text color and style of number onmouseover
number_i.onRollOver = function(){
text_i.color = 0x999999;
text_i.underline = true;
}
number_i.onRollOut = function(){
text_i.color = 0xFFFFFF;
text_i.underline = false;
}
//add the number to the textfield
text_i.text = "["+i+"]";
//on click of each number/button, display corresp. pic
number_i.onPress = function(i) {
delete pic_holder;
this.createEmptyMovieClip("pic_holder", num+1);
pic_holder.scaleContent = true;
pic_holder._x = 15;
pic_holder._width = 285;
pic_holder._y = 20;
pic_holder.loadMovie("/images/"+type+"/"+i);
};
}
delete i;
}
Simple Loop
I was creating a loop to handle parsing this XML file and it doesn't seem to be working. This is probably some logic problem so I didn't look for resources. This loop begins at 1 because node 0 is used for something else. Help me understand where I may have goofed.Thanks for the help in advance.
code:
for(i=1; i<this.firstChild.childNodes.length; i++){
var song:String = this.firstChild.childNodes[i].firstChild.nodeValue;
var textBox = "text" + i + "_txt.text";
textBox = song;
}
Help With Simple Loop
Hi to all
I am Newbie and just into the ActionScript and coding to.. I just need a help with the loop... so far i can do the following..
on (release)
{
for(i=0;i<10;i++)
{
output=output + "some text";
}
}
thats works fine..but my question is how can i print the numbers i.e 123456789 in the text box using the loop?
Would appreciate any help on this.
Regards
Aneeliyo
Do While Loop ?... Should Be Simple....
for some reason, the following do while loop isn't scrolling continuously while the respective buttons are held down... take a look:
Code:
d_btn.onPress = function() {
scrollcheck = 0;
do {
myText.scroll += 1;
d_btn.onRelease = function() {
scrollcheck = 1;
};
} while (scrollcheck=0);
};
u_btn.onPress = function() {
scrollcheck = 0;
do {
myText.scroll -= 1;
u_btn.onRelease = function() {
scrollcheck = 1;
};
} while (scrollcheck=0);
};
there must be some simple logical error. any help would be greatly appreciated. thanks in advance!
Simple For Loop >>pls Help
Hola everyone, I'm kind'a new here so pls take it easy on me... heh
In any event, can anyone help me consolidate this portion of an actionscript l'm working on. I just can't seem to get this to work in a for loop, each of them is the same...
30 if statements in all each of them preforms the same task, just with a different value for the target movie clip (mark[i])... can anyone help me write up a quick for loop to make this code much smaller, and easily managed?
Thanks to anyone that can help me out w/this
Samantha G.
Code:
onClipEvent (enterFrame) {
if ((_root.mark1.hitTest(_root._xmouse, _root._ymouse, true)) and (draw) and (!mark1)) {
mark1 = true;
_root.marks++;
}
if (_root.mark2.hitTest(_root._xmouse, _root._ymouse, true) and (draw) and (!mark2)) {
mark2 = true;
_root.marks++;
}
if (_root.mark3.hitTest(_root._xmouse, _root._ymouse, true) and (draw) and (!mark3)) {
mark3 = true;
_root.marks++;
}
if (_root.mark4.hitTest(_root._xmouse, _root._ymouse, true) and (draw) and (!mark4)) {
mark4 = true;
_root.marks++;
}
if (_root.mark5.hitTest(_root._xmouse, _root._ymouse, true) and (draw) and (!mark5)) {
mark5 = true;
_root.marks++;
}
if (_root.mark6.hitTest(_root._xmouse, _root._ymouse, true) and (draw) and (!mark6)) {
mark6 = true;
_root.marks++;
}
if (_root.mark7.hitTest(_root._xmouse, _root._ymouse, true) and (draw) and (!mark7)) {
mark7 = true;
_root.marks++;
}
if (_root.mark8.hitTest(_root._xmouse, _root._ymouse, true) and (draw) and (!mark8)) {
mark8 = true;
_root.marks++;
}
if (_root.mark9.hitTest(_root._xmouse, _root._ymouse, true) and (draw) and (!mark9)) {
mark9 = true;
_root.marks++;
}
if (_root.mark10.hitTest(_root._xmouse, _root._ymouse, true) and (draw) and (!mark10)) {
mark10 = true;
_root.marks++;
}
if (_root.mark11.hitTest(_root._xmouse, _root._ymouse, true) and (draw) and (!mark11)) {
mark11 = true;
_root.marks++;
}
if (_root.mark12.hitTest(_root._xmouse, _root._ymouse, true) and (draw) and (!mark12)) {
mark12 = true;
_root.marks++;
}
if (_root.mark13.hitTest(_root._xmouse, _root._ymouse, true) and (draw) and (!mark13)) {
mark13 = true;
_root.marks++;
}
if (_root.mark14.hitTest(_root._xmouse, _root._ymouse, true) and (draw) and (!mark14)) {
mark14 = true;
_root.marks++;
}
if (_root.mark15.hitTest(_root._xmouse, _root._ymouse, true) and (draw) and (!mark15)) {
mark15 = true;
_root.marks++;
}
if (_root.mark16.hitTest(_root._xmouse, _root._ymouse, true) and (draw) and (!mark16)) {
mark16 = true;
_root.marks++;
}
if (_root.mark17.hitTest(_root._xmouse, _root._ymouse, true) and (draw) and (!mark17)) {
mark17 = true;
_root.marks++;
}
if (_root.mark18.hitTest(_root._xmouse, _root._ymouse, true) and (draw) and (!mark18)) {
mark18 = true;
_root.marks++;
}
if (_root.mark19.hitTest(_root._xmouse, _root._ymouse, true) and (draw) and (!mark19)) {
mark19 = true;
_root.marks++;
}
if (_root.mark20.hitTest(_root._xmouse, _root._ymouse, true) and (draw) and (!mark20)) {
mark20 = true;
_root.marks++;
}
if (_root.mark21.hitTest(_root._xmouse, _root._ymouse, true) and (draw) and (!mark21)) {
mark21 = true;
_root.marks++;
}
if (_root.mark22.hitTest(_root._xmouse, _root._ymouse, true) and (draw) and (!mark22)) {
mark22 = true;
_root.marks++;
}
if (_root.mark23.hitTest(_root._xmouse, _root._ymouse, true) and (draw) and (!mark23)) {
mark23 = true;
_root.marks++;
}
if (_root.mark24.hitTest(_root._xmouse, _root._ymouse, true) and (draw) and (!mark24)) {
mark24 = true;
_root.marks++;
}
if (_root.mark25.hitTest(_root._xmouse, _root._ymouse, true) and (draw) and (!mark25)) {
mark25 = true;
_root.marks++;
}
if (_root.mark26.hitTest(_root._xmouse, _root._ymouse, true) and (draw) and (!mark26)) {
mark26 = true;
_root.marks++;
}
if (_root.mark27.hitTest(_root._xmouse, _root._ymouse, true) and (draw) and (!mark27)) {
mark27 = true;
_root.marks++;
}
if (_root.mark28.hitTest(_root._xmouse, _root._ymouse, true) and (draw) and (!mark28)) {
mark28 = true;
_root.marks++;
}
if (_root.mark29.hitTest(_root._xmouse, _root._ymouse, true) and (draw) and (!mark29)) {
mark29 = true;
_root.marks++;
}
if (_root.mark30.hitTest(_root._xmouse, _root._ymouse, true) and (draw) and (!mark30)) {
mark30 = true;
_root.marks++;
}
}
Simple For Loop Help
I've been experimenting with a simple imageViewer class, implemented like this:
var viewer1:thumbLoader = new thumbLoader(target_mc);
viewer1.loadImage("whatever.jpg");
my question is how would i use a for loop to make twenty viewers (1-20) load say, twenty elements from an array. One problem is that if I use a string like ["viewer" + i], the class file is expecting a movieclip and throws up a type mismatch. I would guess it's done something like this:
for (var i=0; i<20; i++) {
var this["viewer"+i]:Thumbloader = new thumbLoader("target_mc"+i);
}
but obviously this doesn't work. any help much appreciated.
Simple Loop Q
hi guys how would i continually loop this
_root.clip.tween("_x",560,3,customEasing);
big thx to all who post
|