-
Hey,
I have some flash footers that i want to load into a site.
I don't know how to load the flash footers exactly where i want them to load.
How do i do this?
-
Code:
onClipEvent(load){
loadMovieNum("fileName.swf",1);
}
i think that is something like what you are looking for? hope that helps.
-
you can set the position of the loaded movie by adding the little extra code shown below:
[code] onClipEvent(load){
loadMovieNum("fileName.swf",1);
}
onClipEvent(enterFrame){
_level1._x=150;
_level1._y=50;
} [code]
-
-
sure no probs DZL,
i often do this with images and sounds too. it allows me to create preloaders for each part of the site and enables idle areas of the animations to be unloaded.
by the way you forgot to incude the URL for your site.
chow
-
Miss Understood
Originally posted by deva_station
sure no probs DZL,
i often do this with images and sounds too. it allows me to create preloaders for each part of the site and enables idle areas of the animations to be unloaded.
by the way you forgot to incude the URL for your site.
chow
can you tell me what clip event means? hate to be so thick but i'm still getting my head around it.
-
ClipEvent is the handler and in this case it's a blank clip (just code) that constantly (each frame) evaluates and sets conditions for the loaded swf. In our example it sets the _x and _y of the swf. Otherwise when you use loadMovie it just dumps the swf onto the stage with all the grace of the Jolly Green Giant after a case (truckload?) of brews.
Using this method allows us to place the swf exactly where we want it which is vital for aesthetic reasons. EnterFrame means that the blank clip is constantly making sure the swf stays put. In basic form it looks like this:
onClipEvent(enterFrame){
doYourStuffHereEachFrame;
}
-
Miss Understood
thanks
thank you
-
Re: thanks
I needed to learn that too ..cool
-
Miss Understood
Originally posted by deva_station
you can set the position of the loaded movie by adding the little extra code shown below:
[code] onClipEvent(load){
loadMovieNum("fileName.swf",1);
}
onClipEvent(enterFrame){
_level1._x=150;
_level1._y=50;
} [code]
hi i tried to do this and i got an error message saying "Clip events are permitted only for movie clip instances"
where does this script go? i tried using it instead of load movie as i thought this is where it'd go. can you enlighten me
cheers
miffy
-
miffy,
Just create a blank clip with nothing in it. (The code doesn't reside within the clip itself.) Then drag a copy of it on to the stage and add the code there in the actions panel. Provided you haven't tried to nest onLoad and enterFrame together you shouldn't get any error messages.
You may need to click on the white dot to get the actions panel to go from frame actions to object actions. That may be your problem. In fact, this happens quite a bit even with normal clips. If you try to type in the clip event actions while the actions panel is in frame mode you'll get the error you described when you test the movie. It has to be one of these things.
-
hi, well I have a few problems 2... I created a movie clip placed it on the main time line, and set the actions... but it doesn't load the swf file.
-
show us your version of the code and the file name you wish to load
-
oops... my mistake it works .. is there another way to do this ?? because one of my friends tried to explain to me a way but I didn't understand much... but he said something about coordinates so maybe he was talking about the same thing.
-
there can be more than one way of doing something, obviously the long and short way. I dont really care as long as it does the job i want i'll be well happy!
-
Miss Understood
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|