View Full Version : Downward Compatibility?
Hi,
i use a lot of expressions like:
_root.mymc.GotoAndStart(10);
Now this seems to work only with version 5 of the Flash player, and I need to create a .swf-file that is compatible with flash 4 or even earlier. Is there any way to achieve that?
Thanks for your help,
Flow
zoomfreddy
10-23-2001, 10:29 PM
instead of this:
_root.mymc.GotoAndStart(10);
use this:
Begin Tell Target ("/mymc")
Go to and Play (10)
End Tell Target
:cool:
vilehelm
10-24-2001, 02:39 AM
I think this is true for the most part, somebody correct me if i'm wrong.
If you stay with the "auto scripting formatting" that flash five uses. Yknow where you hit the buttons and it writes it for you. Rather than using the expert mode. You should for the most part stay F4 compatible. I always get ragged on for mixing the two together.
Why it continues to write like that when Flash wants to move the language along to something more "programmerly" i don't know.
Jesse
10-24-2001, 12:22 PM
sounds like your rule might work. there are some functions, like clipEVent handlers which can be accessed from the drop downs which wont work in Flash 4... in fac there's quite a few... perhaps that ruel wont work after all :)
the things to remember are:
- tellTarget and slash synatx instead of dot syntax (see the paths tutorial)
- no clip events
- no for loops
- ahh... other stuff :)
Thanks for your replies, but it still does not work. When I write
stop ();
Begin Tell Target ("_root.mymc")
GotoAndPlay (1)
End Tell Target
oops, the posting was cut off. Again:
When I write
stop ();
Begin Tell Target ("_root.mymc")
GotoAndPlay (1)
End Tell Target
the whole script won't work, not even the stop action. The syntax check wants me to use ';' even if I use one after every line.
stop;
tellTarget ( "_root.mymc" ) {
GotoAndPlay (1);
}
This seems to be syntactically correct, and it works fine with Flash 5, and even if i compile it for Flash 5 at least the stop action works in the Flash 4 player. However, if I compile it for Flash 4, no part of the script works in the Flash 4 player (it all works in the 5 player, though).
Oh, maybe it is the "_root." path?
pinkaboo
10-25-2001, 02:49 PM
In Publish Settings if you set the flash publish setting to Flash 4 before you start then when you are within the Actions editor any command that is only compatible in Flash 5 is highlighted in a lovely warning yellow. mmm.
Then if, as Vilehelm says, you use the normal mode for writing the code you should find it easier to keep it Flash 4 compatible from the beginning. My company refuses to use Flash 5 for the majority of stuff (I can sometimes manage to sneak the odd thing past them) and generally requires everything to be Flash 4 (or even Flash 3 - eek).
I usually forget to switch the publish setting to Flash 4 though and then you can hear me cursing when I realise just as I have finished something that I have to back code everything again, nightmare.
K
red penguin
10-25-2001, 03:22 PM
Please please tell me why your company won't use F5? Are they insane? Or just stoopit? Good advice, pinkaboo!:D
As for Flow: NO DOT SYNTAX! WHATSOEVER in F4...So, yes, the _root would need to be changed to slash syntax...
he did not write "_root." he wrote "/"
flash4"/"==flash5"_root."
try it again.:)
zoomfreddy
10-25-2001, 07:33 PM
use the slash syntax,this have to work!!! and as a matter of clean scripting, use the "stop()" action at the end of the script
(don't know if flash cares about that, but it cut be that the stop ends the execution of code) somebody knows about that?
:cool:
red penguin
10-25-2001, 09:57 PM
stop(); just stops the playhead...the code will be reached...:)
so Flow...get it goin'?
Jesse
10-26-2001, 01:22 AM
I know you didn't actually write:
stop ();
Begin Tell Target ("_root.mymc")
GotoAndPlay (1)
End Tell Target
in Flash 5... you didn't di you? ;)
try:
stop ();
tellTarget ("/mymc") {
gotoAndPlay (1);
}
that really should work...
vilehelm
10-29-2001, 03:43 AM
Originally posted by pinkaboo
In Publish Settings if you set the flash publish setting to Flash 4 before you start then when you are within the Actions editor any command that is only compatible in Flash 5 is highlighted in a lovely warning yellow. mmm.
hey, that's a good tip. i only recently got my company to buy flash 5. but we try to stay flash 4 compatible. and if it's just an animation then i'll go down as far as i can.
Jesse
10-29-2001, 06:28 AM
Cmon people. You are the techs of the world. Force your companies out of the Stone Age of Flash! 78% Flash 5 player penetration as of last week. It's increasing every day. Force people to upgrade, they will be thankful to you in the end :)
red penguin
10-29-2001, 02:01 PM
yeah...that's tellin' it like it is!!!
78%
forces unite
vilehelm
10-29-2001, 04:36 PM
78% and none of them are CFOs
You are right, of course! Now I've got it working, thank you very much! There is just one problem left:
How can I access root level variables in a Flash 4 compatible way? Or to be precise, how could I express something like:
_root[_root.nextmc].GotoAndPlay(2);
Now this probably belongs into a thread of it's own, but where are your 78% from, and 78% of what? If 78% of all personal computers have Flash 5 installed, it is pretty cool. But if 78% of all installed versions of Flash are Flash 5, and, let's say, 70% of all relevant computers have Flash installed, it is not that cool after all. Together with people that do not have flash at all, that would mean that only 54.6% of all internet users would be able to access our flash 5 masterpieces.
What do you say?
vilehelm
10-30-2001, 03:23 PM
I usually use webmonkey for stats like that. There are some much more sophisticated services that cost $$$ that will give you very exact info. statmarket.com is one of them. forrester and jupiter are others.
Jesse
10-31-2001, 01:34 AM
Use Telltarget to be Flash 4 compatible. 96% of computers have Flash 2 or higher installed. 78% of computers (not 76% of that 96%) have Flash 5.
Hahaha guys you arent going to believe this, but my company still has Flash 3 as the company wide standard. You can just imagine how much of a hell my world is...
Josh Dura
vBulletin® v3.7.1, Copyright ©2000-2009, Jelsoft Enterprises Ltd.