Groups | Blog | Home
all groups > macromedia flash sitedesign > march 2007 >

macromedia flash sitedesign : I am Stuck - gotoSlide and pointer issues


djelder
3/5/2007 7:30:36 PM
I am having serious issues with my scripting. I am not getting errors, but I
am also not getting the results I am looking for. So I am stuck, and can't
figure out why it's not going the way I want it too.

To lay it out for you, I have my Main Page - Blank, then inside that I have
"Pages" which holds all of the flash pages for the website which there are 6 of
them: "about_us" "our_work" our_offices" "in_development" "PRESS" "contact_us"
this is how I've labeled both the form scenes and the mcbuttons so that I can
use the "this._name" syntax to tie everything together. I have a home page,
but I want the home page to be linked to my logo buttons on the top of the site.

When I test the movie, everything is working, I am getting my rollover,
rollout actions, when I release the buttons, my pointer action works, except in
one case. If I click on the logos to go to the home page, the pointer goes off
the screen to the home movie clip I put off screen, but if I click on any other
button, the pointer doesn't come right back on the screen, as it should. I
really am stuck, please help.

All of the code is on the mainMenu which is "_parent" to the "Main"




on (load) {
import mx.transitions.*;
import mx.transitions.easing.*;
lastTarget = "home"


this.btnLogo.onRollOver = function() {
mcLogo.gotoAndPlay("_over");
};
this.btnLogo.onRollOut = function() {
mcLogo.gotoAndPlay("_out");
};
this.btnLumtype.onRollOver = function() {
mcLuminairtype.gotoAndPlay("_over");
};
this.btnLumtype.onRollOut = function() {
mcLuminairtype.gotoAndPlay("_out");
};
this.about_us.onRollOver = function() {
about_us.gotoAndStop("_over");
};
this.about_us.onRollOut = function() {
about_us.gotoAndStop("_out");
};
this.our_work.onRollOver = function() {
our_work.gotoAndStop("_over");
};
this.our_work.onRollOut = function() {
our_work.gotoAndStop("_out");
};
this.our_offices.onRollOver = function() {
our_offices.gotoAndStop("_over");
};
this.our_offices.onRollOut = function() {
our_offices.gotoAndStop("_out");
};
//In Development Rollover animation
this.in_development.onRollOver = function() {
in_development.gotoAndStop("_over");
};
//In Development Rollout animation
this.in_development.onRollOut = function() {
in_development.gotoAndStop("_out");
};
//Press Rollover animation
this.PRESS.onRollOver = function() {
PRESS.gotoAndStop("_over");
};
//Press Rollout animation
this.PRESS.onRollOut = function() {
PRESS.gotoAndStop("_out");
};
//Press Rollover animation
this.contact_us.onRollOver = function() {
contact_us.gotoAndStop("_over");
};
//Press Rollout animation
this.contact_us.onRollOut = function() {
contact_us.gotoAndStop("_out");
};

home.onRelease = about_us.onRelease = our_work.onRelease =
our_offices.onRelease = in_development.onRelease = PRESS.onRelease =
contact_us.onRelease = function() {
trace("go to slide" + " " + this._name);
this._parent._parent.pages.gotoSlide(this._parent._parent.pages[this._name]);
var pointertween:Tween = new Tween(this._parent.mcPointer, "_x",
Strong.easeOut, this._parent[lastTarget]._x, this._x, 1, true);
lastTarget = this._name;
};

btnLogo.onRelease = btnLumtype.onRelease = function() {
this._parent.pages.gotoSlide(this._parent.pages[home]);
var pointertween:Tween = new Tween(this._parent.mcPointer, "_x",
Strong.easeOut, this._parent[lastTarget]._x, this._parent["home"]._x, 1, true);
lastTarget = this.name;
};

}
djelder
3/7/2007 3:30:58 PM
djelder
3/7/2007 4:52:02 PM
If you need more information, I would gladly give i to anyone who has any ideas?

AddThis Social Bookmark Button