-
5 Attachment(s)
Using the Flash command "_level" in XXPro.
I haven't seen this documented but someone was asking whether you could get one swf movie to call another. I wasn't sure but I thought I'd give it a try. I was pretty certain you could get one html page containing flash to call another but could you get XXPro to load further swf files in different LEVELS as per the ActionScript command :
Code:
on (release) {
loadMovieNum("coast.swf",2);
}
Whereby the swf in layer0 loads the swf "coast.swf" into layer 2 WHILST layer0 remains visible.
In fact you can get it to work very well using XXPro and the Web Address dialogue.
As an example of how to replicate the actionScript above in the Web Address use the url as coast.swf and the Target Frame of _level2.
There are some important things to note:
1: The loading of swf's into different levels will not work in the Flash Browser Preview. It has to be uploaded to a web server directory.
2: Whilst editing pages you can upload a new swf file that you've altered in some manner. When you test it, nothing's changed!
This is because the swf is always being loaded from the local cache. Refreshing the swf file won't have any effect as you're only updating the level zero swf, the swf's on higher levels still continue to be loaded from your computers cache. The only way to completely refresh loading all swf files is to go into Internet Options / Delete Temp Internet Files.
Anyway here's an example. It might look like one XXPro swf file but is in fact eight seperate & distinct XXPro swf files. CLICK HERE
It's quite simple & could have been done in a single XXPro swf file but even at this level of simplicity to do it in one linear fashion would soon start to tax the brain. Each swf only has a single frame.
I also attach the various swf's. Not exiting in themselves but hopefully in assisting you in what's going on.
-
Re: Using the Flash command "_level" in XXPro.
Not sure I understand all o' that .. I'll have a play.
Stand by to answer idiot questions ...
-
5 Attachment(s)
Re: Using the Flash command "_level" in XXPro.
Perhaps THIS will help Intbel.
What's happening is that you have one swf (index_menu.swf).
This swf is just one frame on which exist the show hide buttons.
When any of the buttons are pressed it loads another swf file in a layer above index_menu.swf which is on level 0.
In this manner you can load multiple swf's with a varying number of frames and timing.
As all the animations aren't in a single swf file it enables you to alter only one swf at a time (say the foot [level3.swf]) by adding 10 additional frames say, which changes the foot animation only . If they all sat in the same swf creating additional frames would effect the whole animation.
I'll post the swf files for this group of animations. Notice the widely different frame numbers and animation leghts. This wouldn't be possible in a single swf.
REMINDER: index_menu.swf wont do anything if viewed here. Use the link above to view it.
-
Re: Using the Flash command "_level" in XXPro.
Thank you.
I had got the idea of the buttons being on the background frame no problem.
I don't fully understand "Layers" here yet but I'm working on it ... don't tell me, I'll ask if I get stumped.
Thanks for the info ...
-
Re: Using the Flash command "_level" in XXPro.
Just a quicky:
levels, not layers.
-
Re: Using the Flash command "_level" in XXPro.
Just think as levels in SwishMax like layers (kinda) layer(0) is primary and you can load other swish objects into levels youspecify.
Jim
-
Re: Using the Flash command "_level" in XXPro.
That's exactly what this is doing Jim. The target frame for URL = _levelx so it's better if you talk about levels rather than frames or layers or you'll get XXPro users mixed up with Pro's Frames & Levels.
-
Re: Using the Flash command "_level" in XXPro.
And HERE'S another one. It just demonstrates the independant starting time of each swf.
EXPLANATION. The base swf is loaded into level 0. If you click on the 4 red buttons as quick as you can it loads 4 quadrents of a kalidascope, which if you've clicked quick enough (and you're not on a dial-up connection) runs pretty much as a kalidescope should do.
However if you reclick on any of the red buttons again it reloads the swf from the start and this way you can completely mess up the kalidascope effect.
This swf file has no practical purpose, it's just to demonstrate the independance of the five swf files all loaded into one swf.
I suggest reducing your browser window on this swf, it can become fairly cpu hungry.
-
Re: Using the Flash command "_level" in XXPro.
I managed it, thanks for the info.
A few things yiu didn't tell but this is good, makes the grey matter work a little.
Here's a fun result:
http://www.intbel.com/tg/test/swftest.html
I have used twice as many files to get the same result - tell me, to what do you link the "Hide" buttons please?
-
Re: Using the Flash command "_level" in XXPro.
Yea! you've got it Raymond. That's fun isn't it and in the long run easier to edit an individual file.
I link the hide buttons to a file called "blank.swf" which only has the border the same size as the root (level 0) swf, otherwise it's empty.
-
Re: Using the Flash command "_level" in XXPro.
Here's a link to a more detailed one. One that would be impossible to create in a single swf file. In total it's 34Kbs and is almost infinite in it's playing length.
CLICK HERE
-
Re: Using the Flash command "_level" in XXPro.
Quote:
Originally Posted by
Egg Bramhill
Here's a link to a more detailed one. One that would be impossible to create in a single swf file. In total it's 34Kbs and is almost infinite in it's playing length.
This is good stuff ... still playing here, once I'm totally au fait with it I'll find out how I can apply it more seriously.
Thanks for the heads up on this - much appreciated.
-
Re: Using the Flash command "_level" in XXPro.
Another fun piece. Have it well-sussed now, I think.
Muchos obligeous :)
Forgot to add the link: here
-
Re: Using the Flash command "_level" in XXPro.
It would be great if Xara supported this internally. The problem is that not everyone has their own web space to upload the flash files to.
-
Re: Using the Flash command "_level" in XXPro.
Quote:
Originally Posted by
Xhris
It would be great if Xara supported this internally. The problem is that not everyone has their own web space to upload the flash files to.
This is true.
Until this is supported internally (along with the ability to embed sound?) Xara could rent webspace to all registered users for a reasonable fee.
could possibly do this thing anyways, maybe.
A li'l more income for Xara and useful facility for users.
And .. I'd like to take this opportunity to say how increasingly annoying I find having the frame gallery upside down - since when does a background frame lie on top of other frames?
'Tis a most unnatural state of affairs ... grrrr.
-
Re: Using the Flash command "_level" in XXPro.
Xhris,
You can view it in a browser from your local computer. What you can't do is have it function under the "Flash Browser Preview"
I expect this is because it's loading the swf into a temp folder rather than the folder where the other swfs reside.
-
Re: Using the Flash command "_level" in XXPro.
Quote:
Originally Posted by
Egg Bramhill
Xhris,
You can view it in a browser from your local computer.
How (I've not actually played with this yet)?
Hmm, it's touch and go whether I include this or not in the Flash tutorial I wrote. It's powerful, but not official. Comments from Xara would help me decide, but as yet there have been none.
-
Re: Using the Flash command "_level" in XXPro.
Quote:
Originally Posted by
Xhris
How (I've not actually played with this yet)?
Hmm, it's touch and go whether I include this or not in the Flash tutorial I wrote. It's powerful, but not official. Comments from Xara would help me decide, but as yet there have been none.
View it in your browser directly from files on your Hard Drive simply by creating an html file for the first swf, conveniently provided in the swf browser preview in Xtreme.
-
Re: Using the Flash command "_level" in XXPro.
As Intbel says. So provided all the swf files are located in the same folder it will work in the browser from the local computer or a remote server. (But still not from XXPro's "Flash Browser Preview")
Quote:
Hmm, it's touch and go whether I include this or not in the Flash tutorial I wrote. It's powerful, but not official. Comments from Xara would help me decide, but as yet there have been none.
As I said, I was just experimenting and it worked, although I'd seen no documentation regarding this feature. As a feature it does greatly expand the ease of use swf files and their editability. I've tried to see if it's possible to insert this instruction in a frame command rather than as a button command [web address] but had no sucesess.
-
Re: Using the Flash command "_level" in XXPro.
Quote:
Originally Posted by
Xhris
Hmm, it's touch and go whether I include this or not in the Flash tutorial I wrote. It's powerful, but not official. Comments from Xara would help me decide, but as yet there have been none.
Come on, Xhris...if it works, you should mention it...at the very least as an "undocumented feature." (Isn't that the term Microsoft uses for bugs in their software?)
---
Will
-
Re: Using the Flash command "_level" in XXPro.
Quote:
Originally Posted by
Intbel
...by creating an html file for the first swf...
what's the recipe for creating an html file?
-
Re: Using the Flash command "_level" in XXPro.
Quote:
Originally Posted by
Xhris
what's the recipe for creating an html file?
The simplest way, for this particular purpose:
In Xtreme, use browser preview of your swf.
Select in Xtreme's browser window View HTML
Copy the resulting text and paste into Notepad.
Save the notepad file with .html extension instead of .txt.
Instant webpage :D
-
Re: Using the Flash command "_level" in XXPro.
Oh. Learn something everyday. Ok, I'll play around and then update the tutorial when I get time.
-
Re: Using the Flash command "_level" in XXPro.
Nintendo do some good interactive flash sites that use this levels stuff. Be good if one day Xara could do all of this kind of stuff:
http://www.metroidprimepinball.com/launch.html
-
Re: Using the Flash command "_level" in XXPro.
Xhris...
I'm really looking forward to more tutorial info from you. Your explanations and directions are always so clear and easy to understand and to follow...
You definitely know how to teach this old dog some new tricks.
By the way...I see you are planning to spend time in Oklahoma...That's my old home state. Lived there from first grade till I graduated from college.
Hope you will find it enjoyable. If I can answer any questions, etc., about Oklahoma, PM me and I'll be happy to respond.
---
Will
-
5 Attachment(s)
Re: Using the Flash command "_level" in XXPro.
Cracked it. A couple of things that weren't clear: levels have stacking order and are like acetates (clear sheets of plastic like animators use). Also, when you assign a blank swf to simulate an off command, it's level must be set to the same as the level of the swf you're working on.
Attached are all the Xar files you need to get it to work (I don't have web space to link too). Recipe for viewing HTML and flash:
1. Load each Xar file
2. Export flash animations for all 4 of them giving them appropriate names (For this, these have to be : LT0, LT1, LT2, and blank)
3. In the "Levels Test 0.xar", click flash preview and then click to see the HTML code.
4. Copy this and paste into notepad.
5. Change the two instances of the reference to a swf to whatever you saved the core/base swf as (e.g. LT0.swf). It should read as:
***********
<OBJECT classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" CODEBASE="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0"
WIDTH=598 HEIGHT=502>
<PARAM NAME=movie VALUE="LT0.swf">
<PARAM NAME=quality VALUE=high>
<PARAM NAME=menu VALUE=true>
<EMBED src="LT0.swf" quality=high bgcolor=#FFFFFF WIDTH="598" HEIGHT="502" NAME="yourmovie" ALIGN="" TYPE="application/x-shockwave-flash" PLUGINSPAGE="http://www.macromedia.com/go/getflashplayer">
</OBJECT>
***********
6. Save as an HTML instead of txt
7. Open the HTML file in a browser to view flash animation.
For any future changes to the Xar files, just re-export and refresh browser to see the changes.
In the animation, notice how after clicking "level 1", clicking it again to restart the animation is slightly different to having a "restart" button programmed in Xara to go to the start of the frame of animation.
Because this way of using Flash is like using clear acetates, you either have to draw over the contents of lower level flash files (as in "level 2"), or add extra buttons on free space (as in "level 1").
To clear all and restore to the beginning, just have a button on the core flash file that loads the core flash file. The button will have the level set to that of the core flash file. Look in the xar file and the web address dialogue to understand better. The best way to learn is to do.
-
Re: Using the Flash command "_level" in XXPro.
Something tells me this will be awfully informative once I hunker down and read it the way it should be read....
__________________________________________________ _____________
If nothing is never always impossible, why is something not always possible?
-
Re: Using the Flash command "_level" in XXPro.
Xhris,
You seem to have mastered it.
The only thing I would suggest is to keep your file names the same such that 0.xar exports an animation called 0.swf etc. In this manner it is far easier to understand what swf file is attached to what xar file.
Tallis,
Going beyond the AllFlashSitesRCrap tut, this is by far the best way to impliment your Flash site.