I’m not too sure what I’m doing wrong here but I’ve been stuck on this for too long now…
I’ve got a full browser Flash project that has the container that then pulls in a some background images (located in one swf), a logo, a menu and then some content boxes (10 boxes in one swf).
My menu swf has button code in it to set off a few things on rollOver, rollOut and onPress. Here’s a look at one of the onPress functions:
[AS]menu.btn_contact.onPress = function () {
myActiveButton = “contact”;
enableButtons (myActiveButton);
new Tween(currentPhoto, “_alpha”, Strong.easeIn, 100, 0, 1, true);
new Tween(_root.obj_photos.photo006, “_alpha”, Strong.easeIn, 0, 100, 1, true);
new Tween(currentContent, “_x”, Strong.easeOut, 0, 1024, 2, true);
new Tween(_root.obj_content.mcContent010, “_x”, Strong.easeOut, 1024, 0, 2, true);
currentPhoto = _root.obj_photos.photo006;
trace(currentContent);
currentContent = “_root.obj_content.mcContent010”;
trace(currentContent);
}[/AS]
Now I declare the variables earlier in the script like so:
[AS]currentPhoto = _root.obj_photos.photo001;
currentContent = “_root.obj_content.mcContent001”;[/AS]
Odd thing is, the currentPhoto variable works just fine without the quotes, the currentContent does not. If I leave that one with out the quotes and trace the variable, it comes up undefined.
The trace functions show currentContent’s value as _root.obj_content.mcContent001 the first time then _root.obj_content.mcContent010 which tells me its working but it does not trigger the tween! If I dump _root.obj_content.mcContent001 in there as opposed to currentContent it works just fine but as soon as I place the variable in there, it croaks.
I’m losing it here… any ideas?
Thanks in advance!