FRIHOST FORUMS SEARCH FAQ TOS BLOGS COMPETITIONS
You are invited to Log in or Register a free Frihost Account!


Flash script problem





Dark-Tech
at the moment im trying to make a certain button change shape depending on which shape the user decides he wants due to several problems in actionscript unconformity meaning i have to choose button for one thing and movie clip for another i have mangaed to get down to one hopefully easy fix that i just dont know how to do


in scene 1 Action Script declares var h;
in the same scene, same frame several buttons will set h to a number such as 3 in the next scene of that frame there is a button, in the button is a symbol in the first frame odf the symbol is a gotoandstop(h); comand
it wont realize the variable h's value how can i fix this



Scene1 -
Frame 1-
var h; stop();.....
Frame 2-
stop();.....

Frame 1-
Button1
h = 7;

Frame 2-
Button2-
moviclip1-
movi clip Frame 1 -
gotoandplay(h);
Sappho
Simple the movie clip cant know about the h initialized in another timeline, dont forget that variables in flash are dependant on a timeline in which they were created. If u want to be sure and go the easy way just set it in _root and always access it with absolute way as _root.h or just set it as global variable _global.h Global variables are not timeline dependant but dont forget u cant initialize em with var _global.h just _global.h without the var since that is reserved for local ones.
Dark-Tech
Thanx you were right setting it as _global.h worked perfectly just as i wanted it to be now its just a small while until the project will be done
Related topics
phpbb problem....
Flash Drive Problem
Script Problem
Script Problem
flash player problem
PHP script problem
Script problem
Strange flash intro problem
Flash Snap To Grid Problem
Flash movie problem
PHP login script problem
Flash Drive - Unrecognized Device
Need to add links at the end of a flash video
Flash Script
Reply to topic    Frihost Forum Index -> Scripting -> Php and MySQL

FRIHOST HOME | FAQ | TOS | ABOUT US | CONTACT US | SITE MAP
© 2005-2011 Frihost, forums powered by phpBB.