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




A Mystery...



I have a number of components, mainly radio buttons, built into some movie clips that are peppered inside a .swf that gets loaded into an empty movie clip of the driver .swf. Everything works the way it is designed to, however I'm getting a 'error opening URL' notices inside the output box each time I test drive the main swf. I've noticed that I'm getting one notice for each occurance of a radio button.

These are not serious errors evidently since when after publishing the thing and running it via the html it works fine. But it does annoy me not knowing why I'm receiving the output in the test mode...

Any ideas?

All replies are appreciated and welcomed.

TIA!



FlashKit > Flash Help > Flash General Help
Posted on: 04-13-2004, 03:16 PM


View Complete Forum Thread with Replies

See Related Forum Messages: Follow the Links Below to View Complete Thread

URL Mystery
Is there anyway to load a clickable url address dynamically in flash mx??????

PNG Mystery
Hello All,

I created in Fireworks a PNG image of a lightning bolt and then placed it over a black and white photo in Flash. I exported the PNG as PNG32 from Fireworks MX and the problem i'm having is that there is a faint light box around the lightning bolt the size of the lighting bolt image. I really don't get why this is happening and would like to fix it. Does anyone know how to work around this issue?

Check out what I mean at:

http://www.robbniemann.com/electric/

Nick

Big Mystery, Need Some Help
I've place the following actionscript code inside a frame of an attached Mc:


Code:
_y = _root.Mc_y
trace(_y)
trace(_root.Mc_y)
"trace(_y)" gives the y-position of the Mc, but "trace(_root.Mc_y)" results in the text "undefined", although I've made "_root.Mc_y" equal to the y-position of the Mc. Why is this and how can I make "trace(_root.Mc_y)" result in the y-position of the Mc?

'this' Is A Mystery
I have a function that is defined within a function on my main timeline.
In either function I can access movieclips by their instance name.

e.g.trace(right_mc.name)

however if I use 'this'
e.g. trace(this.right_mc.name)
it works fine in the top level function, but on the lower level function it gives a run time error.

in one case 'this' is the main timeline, but in the embedded function it is not.

What is happening?

Avoiding it seems quite easy, but using the 'insert target path' tool put the this in, thus generating the error

It's A Mystery.....
I'm getting a bit aggrevated with a little problem I have.
Nothing complicated, and it just should work, but I just can't figure out what I can be doing wrong.

I have a function where I pass a reference to a clip and try to duplicate it.
All very standard stuff that I done 1000's of times, but this time it just will not work.
This is the code:

ActionScript Code:
function showModifiers(clip:MovieClip):Void{var cp:MovieClip=clip.duplicateMovieClip("clip_copy",_level0.getNextHighestDepth());trace("clip:"+clip);trace("depth:"+_level0.getNextHighestDepth());trace("ref:"+cp);trace("clip:"+_level0.clip_copy);}

Trace outputs the following:

Quote:




clip:_level0.C3
depth:100001
ref:undefined
clip:undefined




I know the code is correct and setting up a new blank fla it works.
The function is part of an external class and I tested to just stick it on the root timeline in the .fla with the same trace result.
So I really wonder what could possibly go wrong?
Since the clip variable and depth is there I can't think of any scope issues that could cause it.
Anyone experienced similar problems and found a cause?

Swf Mystery
Hi there,

I recently moved server, but when i put the same files up on the new place half the buttons on a particular swf don't call the relevant movies anymore. The page works perfectly on my computor, i have also pulled the files back down from the server and they work again on my pooter...me no get it.. i havent changed the files whatsoever, there was an update of content on other pages at the same time as i was changing server, but no architechture that stopped the page in question from working locally.

the relevant page is at http://www.instantactionobject.org and go to "nameplate supergroup" This takes you to a page of buttons that each play a different swif, if you try a few some work, some dont...they should all play different sound samples.

If anyone has an idea i would be most grateful
cheers
simon

Flv Mystery...
I have created a player with some buttons to load movies on _level2.
The SWF's contain Flv and they work OK as long as they are in the same dir where the EXE is.
I would like to have them in a different dir, but as soon as I place them in another dir, the flv don't load.
Maybe there's something wrong with the path I write. Here it is:

In the same dir:

loadMovie(Overview.swf", 2);

Another dir:

loadMovie(AnotherDir/Overview.swf",2);

Is there something wrong?

Please help...

Thanks

Mystery...... (I Need Heeeeelp)
I need to create a counter in miliseconds avoiding the use of GetTimer, because as a member told me, GetTimer cannot be set to 0, so when I want to replay the movie, I jump direct to the end.

code------------------
now=gettimer
delay=now+gettimer
if (delay>=9000
go to next scene....)
----------------------

when "delay" is larger than 9000, I jump to next,
but when I reply at the end of the movie, GetTimer is
ALWAYS bigger than 9000 so I jump to the end automatic!!

Difficult, eh???

(something else... is it possible to create a counter
without the frame2 "go to an play (1)" (I have problems
also with sounds repeating forever!) ????

please, If somebody has an idea!!!

Thanks!!

How Can This Be? - Quality Mystery -
Hello, I have a problem with the quality of my fla-movie.
When it is only one frame long, the quality is perfect, but when I add just one second frame (or to keep it simple: just make the movie longer) the quality gets down and the grafics look worse than before.
How can this be? I did not change a thing ecxept adding one second frame.
Please help
thx a lot
jean3k

Count Mystery
My loop only works if I hardcode a number in.

like the "3" here:

puppycount = new LoadVars();
puppycount.load("puppycount.txt");
puppycount.onLoad=function(){
count=this.count;
for (i=1; i<=3; i++) {
_root.createEmptyMovieClip("puppyholder"+i, i);
_root["puppyholder"+i]._x=i*60;
_root["puppyholder"+i]._y=25;
loadMovie("puppy"+i+".jpg",_root["puppyholder"+i]);

}
}

For some reason "count" is not working, but it shows up in my dynamic textfield. I tried adding "count=Number(count)" to convert it, but that did not work either. My movie freezes when this movieClip plays.

Any ideas??

Thanks

Variable Mystery?
Here are two codes:
Why are these two not the same? Result is different.
This solution does not work.


Code:
function bigGroup(bigCount){
if(count05==(bigCount-1) && myModel05 != undefined){
modelName = modelName_ + bigCount;
modelDescription = modelDescription_ + bigCount;
urlText = urlText_ + bigCount;
frame = frame_ + bigCount;
modelName = myModel05.attributes.name;
modelDescription = myModel05.firstChild.nodeValue;
trace(modelName);
urlText = myModel05.attributes.myUrl;
frame = myModel05.attributes.myFrame;
chooseModel(modelName,modelDescription);
}
}

function findSubgroup_2 (subGroup) {
for (count05=0; count05 <= subGroup.childNodes.length; count05++) {
myModel05 = subGroup.childNodes[count05];
bigGroup(1);
bigGroup(2);
bigGroup(3);
}
}

__________________________________________________
This solution works:

Code:
function findSubgroup_2 (subGroup) {
for (var count04=0; count04 <= subGroup.childNodes.length; count04++) {
myModel04 = subGroup.childNodes[count04];
if(count04==0 && myModel04 != undefined){
modelName_1 = myModel04.attributes.name;
modelDescription_1 = myModel04.firstChild.nodeValue;
urlText_1 = myModel04.attributes.myUrl;
frame_1 = myModel04.attributes.myFrame;
chooseModel(modelName_1,modelDescription_1);
}
if(count04==1 && myModel04 != undefined){
modelName_2 = myModel04.attributes.name;
modelDescription_2 =myModel04.firstChild.nodeValue;
urlText_2 =myModel04.attributes.myUrl;
frame_2 = myModel04.attributes.myFrame;
chooseModel(modelName_2,modelDescription_2);
}
if(count04==2 && myModel04 != undefined){
modelName_3 = myModel04.attributes.name;
modelDescription_3 = myModel04.firstChild.nodeValue;
urlText_3 = myModel04.attributes.myUrl;
frame_3 = myModel04.attributes.myFrame;
chooseModel(modelName_3,modelDescription_3);
}
}
}

Any help appreciated!

Scroll Bar Mystery
Hi, i was just wondering about fancy scroll bars on some websites, do this have to do something with flash or its a .html codings it. for instance this is an examplar of what i am talking about!! http://www.swfkit.com/samples.html
Any ideas for creating a new one, or one made with flash??

Cheers

Yahoo Add Mystery
hi every one .. yesterday i saw a flash add on yahoo's movie page link.. that appeared on the page and for 5 sec and then automaticaly disappeared .. i was wondering how it is done ..does any one have any idea about that

Preloader Mystery?
I have two separate flash files. Both have multiple scenes, both have a scene called "Loading" which is my preloader.

I setup both preloaders identically and the second one doesn't work. It doesn't move my progress bar correctly.

Here's the code.


loadedbytes=_root.getBytesLoaded();
totalbytes=_root.getBytesTotal();
bytesleft=totalbytes-loadedbytes
perc=Math.round((loadedbytes/totalbytes)*100);
if (loadedbytes >= totalbytes) {
gotoAndPlay("Movie", 1);
}
frame=int(loadedbytes/(totalbytes/100));
_root.loader.gotoAndStop(frame);


Again, both are set up identically. When I run the second movie though at a simulated 56K speed the progress bar scrolls over and over about 8 to 12 times before the actual movie is loaded. However when I change the speed to a simulated DSL / Cable it doesn't even get 1/2 way across before it finishes loading.

My preloader animation is 100 frames in length for both. Can anyone help me?

Please Someone Help Me (levels Mystery)
I´m going crazy!!!
(att. files)

I have a mystery (for me obviusly)

(code in TEST file)

on (press) {
loadMovieNum("test5.swf", 2);
}
on (release) {
_level2.movie._visible = true;
gotoAndPlay(2);
}

(code in TEST5 file)

movie._visible = false;

The code works only if you click the button in the movie TEST outside the animation. If you click just over the animation nothing happens in TEST5

Attachment: test.zip
This has been downloaded 0 time(s).


__________________
A***
[color=blue][color=blue][b][i]

Preloader Mystery
hi folks, this is not the first preloader i'm doing, but the most myterious one.
i put everything that happens in a scene called "Main"; that scene works fine.
then i added a scene called "preloader" and arranged it before the main scene in the scene-window (so it should load, before the rest of the movie will load, right ??)
the preloader unfortunately only shows up, after the whole movie has almost been loaded...

am i missing something in the publish settings or what is it ????
i'm desperate...

Combo Box Mystery
I'm not sure what I am doing wrong; I drag the combo box to the stage, and fill out the param's.
When I publish, only (what looks like) an empty text box appears.
If I create a new document, then do the same thing, everything works as it should. I have never had any problems before...

Mystery Level
Flash MX 2004 / AS1 / Pub: FP6

I have had this problem occur many times, and I think it has to do with the fact I am not understanding the relationship to the levels in the following code.

there is a host movie, and a feature movie that loads into the host. The feature movie ("feature") contains music that I want to control from the host. When audioFadeOut is called, it creates a blank MC at an arbitrary level and quickly reduces the volume.

The code below WORKS, however, to find the feature clip, it has to use _root = bad practice. I try _parent and it doesn't recognize.

code: function audioFadeOut ()
{

if (userAudio != 0) {
this.createEmptyMovieClip("volumeFade", 1700);
this.volumeFade.onEnterFrame = function ()
{
if (fadeVol > 0) {
_root.feature.soundObject.setVolume(fadeVol);
fadeVol--
} else {
_root.feature.musicObject.setVolume(0);
this.removeMovieClip();
}
}



does anyone know what can be used instead of "_root," or if there is a better way to do this?

- the previous code is on the _root level on the host.
- the audio is attached on the _root level of the feature movie:
code: soundObject = new Sound (this);
soundObject.attachSound ("victory");
soundObject.start(0, 99);

Thanks! any help would be GREATLY appreciated!

Mystery Problem
Hi there.

I have a site in development that runs fine locally, but when i test it online, one of the loaded movies doesn't appear.

same files, folders, etc.

I'm at a loss!

can anyone help me out?

Thanks for any advice!
S

Mystery Relinking
I tried to explain this problem earlier but am not sure I was clear. I have numerous symbols in a fla that needed to be changed. After I replaced old symbols with new ones of the same name, everything worked fine. However, after saving, closing and reopening the fla, several instances of some of the changed symbols were mysteriously linked to different symbols also in library.

I am editing someone elses file and am wondering if the only solution is to rebuild the entire file.

DataGrid Mystery
Im having a weird problem with a datagrid.

Im loading an xml-file into it, but sometimes the text in the cells wont show.

When clicking on any of the cells a couple of times (they are editable) I can edit the cells, and on any of the cells that Im editing the text inside it appears. When I loose focus on the cell (not editing it) the text dissappears again.

Makes sense?

What the heck is going on?!

A Url Link Mystery, Please Help
Hi all,

When I open my Flash movie directly from the folder it's in, my external links to url's work perfectly. But when I open the same Flash movie from my intro html page the movie opens but the Url links don't work, (the links to other swf's do still work).

Anyone any idea on how this can be?
Thanks all!

Bzzzz
Woopsybee

Australian Mystery
Hello everyone

Can anyone help me with my Flash Project, when i test my movie in Flash everything is OK but when i publish it some of the buttons and movie clips jump around like theyare having some sort of fit and im at a loss to explain if someone has any clues to the mystery i would be very grateful. The URL is www.paulrussell.batcave.net/australia1.swf

Cheers

Paul

Actionscrip Mystery. Can You Help With This?
Hi,

My files work properly when tested individualy. However there's a problem when I load them into my main file (front page)
I'll explain a bit better.
I have one main file called front page and 4 independend files with a vertical navigation bar (made with actionscript) loading into the front page.

File no.1 called schools loads ok (7 items on the vertical navigation)
The problem starts here, if I click on file no. 2-4 (courses, special programs or students) it only loads 2 items/boxes in the vertical naviagation.
Why is this happening?

In total:
File 1 has 7 navigation boxes in the vertical bar (schools)
File 2 has 15 (courses)
File 3 has 6 (special programs)
File 4 has 8 (students)

The actionscrip for all of them is the same. I only changed the array no. and they all work fine independently.
I haven't attached all .fla files due to size.
templatecode is the eg for the actionscript code for all vert. nav. files

Do you have any idea why this is happening? Do I have to add anything to the main .fla file where they are loading to fix this?

Your help would be appreciated.
Tks

danirob

SetFocus Mystery
It's amazing how the simplest things can be the most irritating and frustrating.

I have an input text field. I want it to receive focus when a button is clicked. I use Selection.setFocus("path.to.fieldName"). It doesn't work. No cursor in the text box, no text when typing, nothing.

However, when I trace Selection.getFocus immediately after calling Selection.setFocus, it returns the text box I just setFocus on. So the setFocus is setting the focus, but ... it's not.

Grrrrr ...

Any suggestions?

My Preloader Mystery...
This is really doing my nut, i'm preloading an external swf into a movie instance on my stage named m_index, with a preloader on the main stage rather than the loaded movie, here's the code:

ActionScript Code:
percentDone = 0;
loadMovie('index.swf',m_index);
   
m_preloader.onEnterFrame = function() {
    if(m_index.getBytesLoaded() != undefined){
        if(m_index.getBytesTotal() != undefined){
            percentDone = Math.round((m_index.getBytesLoaded() / m_index.getBytesTotal())*100);
            m_preloader.g_preloader._width = percentDone*1.5;
            m_preloader.percent = 'Loading '+percentDone +'%';
        }

        if (percentDone == 100){
            m_index.gotoAndStop('loaded');
            m_preloader._visible=false;
            delete this.onEnterFrame;
        }
    }
}

I've been having some problems with the last if statement (if percentDone = 100) being run immediately, ie before the movie is loaded.

After some manual debugging i've narrowed it down to getBytesLoaded & getBytesTotal both equalling 4(!) on the first time through the loop. After that BytesLoaded = 0 & Total Bytes = 11,435(or sumthin), and BytesLoaded increases as the movie loads, as it should. Does anyone have any idea why this is?
My only thought is that for that first frame it might be registering the size of the Instance rather that the swf being loaded into it, but i've never had any trouble with this in previous preloaders.

Hope i've explained this properly, any help would be much appreciated as this is really starting to do my head in....

Printing Mystery
09/18/2005 08:52:58 AM
Reply | Quote | Top | Bottom

I'm in the process of trying to finish the Job From Hell, an elaborate app written in AS1 (that's how long this has dragged on) where the client's suffering from the "can you add one more thing" syndrome. The latest has to with printing a frame from the swf.

The stage is dominated by a clip, call it the fieldClip. The user can attach additional clips within the fieldClip with a button action. There are numerous clips parked offstage.

To print I'm invoking print("#p", "bmovie"), with a bounding box on frame "#b". The fieldClip is visible when the frame is printed, but none of the clips that have been loaded into the fieldClip. This doesn't happen when using "bframe" or "bmax", but then the size of the printed image varies because of the clips parked offstage. Using the AS2 printJob() works fine, but when the swf's published as AS2, much of the AS1 code in other parts of the app malfunction, so I'm stuck with AS1.

Any suggestions, please?? Many thanks in advance.

DEINTERLACE Mystery
i see it referenced a lot in support materials... but where to deinterlace so we can place our broadcast content on our wbsite eludes me. Santa has told me if someone doesn't clear this up - he is canceling christmas.

he sounded serious too.

please help... if not for me... do it for the children.

- Blitzen

E4X Reparenting Mystery
Consider the following code:

// create a root node with 2 child nodes
var root:XML = <node id="1" />;
root.appendChild(<node id="2" />);
root.appendChild(<node id="3" />);
trace(root.toXMLString());

result:
<node id="1">
<node id="2"/>
<node id="3"/>
</node>

// now get the child nodes by their id
var node2:XML = root.node.(@id == 2)[0];
var node3:XML = root.node.(@id == 3)[0];

// make node3 a child of node2, this will create a copy of node3 under node2
node2.appendChild(node3);
trace(root.toXMLString());

result:
<node id="1">
<node id="2">
<node id="3"/>
</node>
<node id="3"/>
</node>

// now try to delete the original node3 directly under the root node
delete root.node.(@id == 3)[0];
trace(root.toXMLString());

result:
<node id="1">
<node id="2"/>
<node id="3"/>
</node>

The wrong node gets deleted!
How do I move (reparent) a node with E4X?





























Edited: 04/21/2007 at 02:06:47 PM by marcboon

Combox Mystery
I have some combo boxes that i have attached to the stage with attachMovie. I used a for loop to attach many combo boxes. after you click a button to submit the data in the boxes it takes u to another frame, but the combo boxes are still on the stage even 10 frames later, even with blank keyframes right after the frame that holds the combo boxes. how do i get rid of these bitches.

GetURL Mystery
Can anyone explain why the following statement works despite the file in question having been updated to PriceList_3.pdf.

getURL("downloads/PriceList_2.pdf");

I uploaded the new pdf and deleted the old one but forgot to edit the line above. It worked fine. The correct file was downloaded, not some cached copy of the old one. There are .zip and .sit versions too and they are also downloaded correctly. Is the version digit being ignored somehow?

Mystery Glitch
The following statements:

import fl.controls.UIScrollBar;
import fl.controls.ScrollBarDirection;

are producing the following compile time errors:

1172: Definition fl.controls.UIScrollBar could not be found
1172: Definition fl.controls.ScrollBarDirection could not be found

These errors are repeated twice in the compiler error output.

If I drag a scrollbar onto the stage then delete it, these errors don't appear and the test file compiles normally.

A few days ago this problem did not exist, but any import directive now seems to produce this error.

Being very new to Flash and AS, I'm totally baffled.

Thanks in advance!

Alan

Mystery Rpg Game?
does anyone know where i could find a good tutorial on how to make a solve-the-mystery game in flash mx?

you know where u go around and follow the clues and stuff...basically like an rpg...more like the myst series...except no movement, just a map and different rooms and ppl to talk to...yeaaaaa that kind of game... anyone know a good tutorial for it?

thanks,
mordaut

Mystery Lines...
Does anyone know why these lines come up after the logo is reshaped?

I'm not sure where they came from.

http://www.livetoskateboard.com/curi...mFlashSite.swf

im going for lunch but ill be back soon

Masking Mystery
Hopefully I'm just making a silly mistake, but I've looked over this several times and can't seem to come up with any solution. There was a very similar problem posted on Adobe's forums a long while ago (http://www.adobe.com/cfusion/webforums/forum/messageview.cfm?forumid=15&catid=194&threadid=1018 702&highlight_key=y&keyword1=masking%20movie%20cli ps),
but unfortunately it was never solved.

Basically, when I apply a mask to a movie clip, the movie clip is completely invisible. The size and position of the mask have no effect whatsoever on the situation. When I delete everything on the mask layer or just delete the mask layer itself, everything in the movie clip is visible. It's probably easier to see than read about. The flash file can be downloaded here...

http://www.personal.psu.edu/users/n/...g%20enigma.fla

The structure may seem a bit strange, but it is the only way to accomplish what I need in the full project. On the stage is a movie clip (mc_explosion). Inside here lies the problem. I posted more detail in the fla file...and after viewing it, hopefully the whole thing will make a bit more sense.

Fit To Screen Mystery Help...
Hey All,

I've got a flash movie that is 740 w x 650 h . This fits fine in many browsers, but not all. I have navigation info at the bottom, images are loaded dynamically in the center.

Here is what I'm trying to do -- I want this movie to resize to fit ONLY browsers/computers that are less than 650 pixels high. So it will only get smaller and NOT bigger.

I don't want this to end up on a cinemadisplay and try to stretch way the heck out, and totally ruin the look and asthetic of the layout and photos.

So, is it possible to have flash resize only smaller, and not go -beyond- it's a certain size (in this case, 740x650 pixels)?

Thanks -- REALLY appreciate it!!

-md

Can Someone PLEASE Help Me Solve This Mystery?
Ok, a few weeks ago I had some difficulty getting an audio player to work properly on my site. I tried a few tutorials, and I finally got it to work, except for one thing - when I put a video on my site, it interfered with the sound of the video. If a person tried to play the video, and the music was still on in the background, when they turn off the music, the video also turned off... which means they would have to re-start the video, and that's not the way it should be.

So, to avoid all the hassle, I purchased a sound player maker, which I thought would solve all these problems... but it hasn't, I can't get the sound player (which is an external swf) to play on my site. It works on its own, when I test it in a browser window.... but it doesn't play on my site.

Here is the code I have now (I changed the url for display purposes)


Code:
holder_mc.loadMovie("http://www.mysiteurl.com/flash/mysoundplayer2.swf")
I just want the player to work. And hopefully not interfere with the other sound on the site, like the old one did.

Please help?!!!

The Www.derbauer.de Mystery
I searched the forums and here are the threads thus far...

Thread1

Thread2

In perusing the (Amazing!) Bauer website, I stumbled upon some older content which listed their primary skills:

Flash (duh, you knew this one I'm sure)
Real3d(i don't know if this is theoretical skill or a program or what)
Lightwave 3d
Softimage

Now, I don't know a whole lot about these programs, but I did a little research and they are pretty high end. Go to their appropriate websites and you'll see a LOT of movies, tv cartoons/shows, and other media use this stuff to animate. I didn't see ANY reference to After Effects (although I'm sure it could attain a similar effect?)

Here are the issues I'd like to learn from the site
Obviously this stuff is bitmap intensive bc there's no way this stuff is vector-based. How do they keep the filesize down? I think the entire site(from what I could gather out of my cache) is around 1.5 Mb. On that note, do they pretty much eliminate a low-band (56k modem) market? Also, the images are pretty **** crisp... second to none in my opinion. Even
Billy Bussey's Website isn't THAT clean and crisp and his is downright amazing.

Let's talk it up peoples This is the direction I'm sure many would like to learn how to move in the web!

Mystery Rpg Game?
does anyone know where i could find a good tutorial on how to make a solve-the-mystery game in flash mx?

you know where u go around and follow the clues and stuff...basically like an rpg...more like the myst series...except no movement, just a map and different rooms and ppl to talk to...yeaaaaa that kind of game... anyone know a good tutorial for it?

thanks,
mordaut

Rollout Mystery
This may come off as a very newbie-esque question, but at this point I don't care. I'm attempting to make simple buttons with rollover and rollouts. I figure the simplest and least-complicated way to do this would be to make a movie clip button. I make the clip, and label the first frame I want for the rollout to begin (and of course, have a stop at the last frame). I go to the parent timeline for the clip/button and attach code to it:
on(rollout){
gotoAndPlay("label");
}
and it does nothing on a rollout. Then, after many frustrated attempts, I change the code to
on(rollout){
gotoAndPlay(22); //frame rollout starts
}
Magically--yet equally frustratingly--it works. Would someone mind explaining this?

UpdateAfterEvent() Mystery
I've posted this on 2 other forums but no one seems to have a clue - I'm sure you guys can figure this out in no time :-)

I've created a calculator which involves a rather long calculation loop (an iterative procedure). Once the 'calculate' button is pressed the calculation function is called.

During the calculation, I want to hide the Mouse and replace it with a MovieClip (a clock). My problem is that I'm unable to refresh the graphics before the calculation loop starts and takes over all processing.

I've tried this set-up:

//initially clock is hidden

CalcButton.onPress(){
showClock=true;
}

function checkClock(){
if (showClock==true){
..hide mouse & make clock visible
updateAfterEvent();
calculateAnswer();
}
}

setInterval(checkClock,100);


Even though updateAfterEvent() comes before calculateAnswer(), the graphics don't get updated until the calculateAnswer function is completed (by which time it's too late anyways).


All my code is in a single frame

Any suggestions ?????

Thanks for your help.

Variable Mystery
Hello!

I've come across a very strange problem I cannot explain - maybe regular Flash programmers have a much better undertstanding where the problem lies. - In short: It looks as if code of the main program is continued before a function that is called is properly finished, or in other words: that a function still continues when it is supposed to already have ended.

The problem in detail is as follows. All the code is in a first empty picture of the movie. I have a function that handles "Loading Keywords". The LoadNewKeyword function is called, and should there be a problem in the function the function LoadNewPicture shouldn't be called. For various reasons I intend to set a variable that I called "PicCanceled" in LoadNewPicture to 1.

Here's the declaration at the very beginning of the movie.


Code:

var PicCanceled = 0;



Part of the first function:


Code:

if (FirstWord<>"") {
trace("Run " + FirstWord);
LoadNewKeyword(FirstWord, SecondWord);
trace("Through " + FirstWord);
trace("Received PicCanceled: " + PicCanceled);
if (PicCanceled==0) {
LoadNewPicture();
}
}



Part of the second function:


Code:

function LoadNewKeyword(Keyword1, Keyword2) {

objLoadKey = new LoadVars();
objLoadKey.onLoad = function(signal)
{
if (signal) {
...
}
else {
KeyCanceled=0;
if (FirstWord == "X" && KeyCanceled==0) {txtText.htmlText = "You cannot find any " + SecondWord + " to examine here. Better try something else."; KeyCanceled=1};
PicCanceled=KeyCanceled;
trace("Cancellation: " + PicCanceled);
OldCharPath = CharPath;
scrollerText.init();
return;
}
}

if (isOnline==true)
{objLoadKey.load(KeywordPath + "?" + new Date().getTime());}
else
{objLoadKey.load(KeywordPath);
}

}



Now what completely buffles me is the fact that the debug window looks like this:


Code:

Run X
Through X
Received PicCanceled: 0
Cancellation: 1



Note that the problems happens if you type rubbish in the textbox, so that only the code after the else is of importance and actually run through.

The correct order (and expected values) of the program should be:


Code:

Run X
Cancellation: 1
Through X
Received PicCanceled: 1



What could there be possibly wrong??? Anyone got an idea? - Thanks in advance to anyone trying to help!

Mouse Events Mystery?
I don't know what is happening between the following 2 movies, but movie 1 will only work if both execute on an enterFrame event. Movie 2 should really be a mouseMove event though because it offers no inertia unlike movie 1 which has to be enterFrame for the inertia part to work!

Basically:
movie 1 is a rotation / inertia with angle throw
movie 2 is a rotation only thing

Both do the same thing but movie 1's } else if (!dragging) { statement which handles the inertia part after mouseUp only executes when movie 2 is using an enterFrame event and not a mouseMove?? even though both never can run at the same time because the script identifies this with the if hitTest().
This has totally thrown me, they seem to be connected through the clipEvent although both are on totally different timelines to each other, so how changing an event type in movie 2 can effect another in movie 1, i just can't work out.

Any ideas anyone?

cheers SAM


Here's the code for the 2 movies:
MOVIE 1 (Just a simple rotation / angle throw inertia thing)


Code:
onClipEvent (load) {
var dragging = false;
var angularSpeed = 0;
var newAngle = 0;
var oldAngle = 0;
}
onClipEvent (mouseDown) {
if (_parent.platter.hitTest(_root._xmouse, _root._ymouse, true) && (!_parent.tonearm.hitTest(_root._xmouse, _root._ymouse, true))) {
dragging = true;
}
}
onClipEvent (mouseUp) {
if (_parent.platter.hitTest(_root._xmouse, _root._ymouse, true) && (!_parent.tonearm.hitTest(_root._xmouse, _root._ymouse, true))) {
dragging = false;
angularSpeed = newAngle-oldAngle;
}
}
onClipEvent (enterFrame) {
oldAngle = newAngle;
newAngle = Math.atan2(_parent._ymouse-_y, _parent._xmouse-_x)*360/(2*Math.PI);
if (dragging) {
_parent.strobeDots._rotation += newAngle-oldAngle;
_parent.platterHoles._rotation += newAngle-oldAngle;
} else if (!dragging) {
_parent.strobeDots._rotation += angularSpeed;
_parent.platterHoles._rotation += angularSpeed;
angularSpeed *= .98;
}
}


MOVIE 2


Code:
onClipEvent (load) {
var dragging = false;
var newAngle = 0;
var oldAngle = 0;
}
onClipEvent (mouseDown) {
if (_root.technics.tonearm.hitTest(_root._xmouse, _root._ymouse, true)) {
if (dragging != true) {
dragging = true;
}
}
}
onClipEvent (mouseUp) {
dragging = false;
}
onClipEvent (mouseMove) {
oldAngle = newAngle;
newAngle = Math.atan2(_root._ymouse-this._y, _root._xmouse-this._x)*360/(2*Math.PI);
if (dragging == true) {
_root.technics.tonearm._rotation += newAngle-oldAngle;
} else {
dragging = false;
updateAfterEvent(mouseMove);
}
}

Here's A Mystery That Would Stump Scooby Doo:
I have a large movie with several scenes, each with a few nested movie clips.

When I test them individually, all my movie clips are showing up much larger than they actually are. They all show something at around 240K in the first frame of the Bandwidth Profiler. For instance; I ran my preloader by itself in the Profiler, which is nothing more than the word "loading" with some pulsing dots on either side of it. and it's saying that the first frame is 256 K. What gives? I know this preloader movie is not more than 1 or 2K. And there's nothing else in the movie. Not even a background. The movie size is 640 x 370.

Encoded Mystery Mouse
Hi.

I know how to transform the mouse cursor into another graphic..
HERE'S THE QUESTION>>
I need to know if it is possible to transform the cursor into an object on one side of the screen, but reverting back to it's cursor form on the other half.

thanks.

Index Page Mystery, PLEASE HELP
Fellow Forum Members,
I'm going crazy here with something I can't figure out. My website has the following structure:

1. Starts with an HTML INDEX Page.

2. The Main Menu SWF plays inside of a Pop up window that is activated by pressing on the ENTER button located in the INDEX page. This Main Menu SWF has 5 buttons. One of them is named PORTFOLIO.

3. To make a long story short, after pressing the "PORTFOLIO" button an external SWF Portofolio Menu loads into level 2 and then as you continue on there are some other buttons that load external SWF movies into level 3 and level 4.

Now here is my problem, when I do a test run starting from the INDEX page levels 3 and 4 don't want to load (only level 1 works). BUT if in my test run I bypass the INDEX page, and start from the Main Menu SWF levels 3 and 4 have no problem loading.

This tells me that the Loadmovie Paths I have specified in the loadmovie URL path have the correct syntax, but if this is the case why don't these external SWF movies load when I do a test run starting from the INDEX page?

Any advise or tips would be greatly appreciated, because I'm at my wit's end. Thanks in advance.

Cheers,

Binar

Mystery Behavior Of A Button?
I've created a game with (rollover) buttons everywhere. The game looks like professional, although is made with this "not so professional method".... but... I have a problem.

I have a draggable character MC that starts following mouse on (enterframe). The game works like this: I have to rollover to soldiers that appear several times in random. this way I get score.

If I rollover OUTSIDE a marked way, a cannon bomb falls over me and I loose a life.

Here's the problem: I have just to click once to start dragging my clip of the hero, but people not used to play, keeps the mouse PRESSED all time... and in this condition, ANY rollover works.... and you can go anywhere outside the way without dying and without killing soldiers.


Is this an unbreakable rule of flash or there's any way to stop the pressing mouse action or consequence???????

thanks

The Mystery Of The 'flash' Window
opening a new browser window and adjusting it's properties is a piece of cake. What i'm after is the illusive 'flash' window that appears in some web sites that contain flash movies, i can't find an example at the moment so it's hard to explain. it's a hovering window, that is not just a movie clip with drag properties attached as it can be dragged around the desktop outside of the browser.
In all the ones i've seen it only contains flash movies and no html.

summary: it only ever contains flash movies
it can only be found on the websites of ppl with more than 1000 posts
it is not contained within a web browser
it is it's own program and when you 'end' program it is called 'flash'
there are no tutorials to exlain this (believe me!)
there's nothing in the html of the page to suggest that it's launched from the page

what is it?

Load Image Mystery
After scouring all the forums I have given up in dismay for finding a script or tutorial that tells how to load one dynamic Jpg. and preload it with percent and status bar.

Now I know this topic has been visited many times but none of them has actually done what I propose above.

If you can help me with a clear concise explanation or a fla. I would be much obliged.

Copyright © 2005-08 www.BigResource.com, All rights reserved