?
Solved

Advance RollOver question

Posted on 2007-04-03
6
Medium Priority
?
221 Views
Last Modified: 2012-05-05
Hi, experts

I have a script that works and i try to make each images button becomes large after roll over. Roll over part of code is not working. Please let me know how to fix it.

Thanks

Example http://www.brianlinstudio.com/testingExample.zip

------------- Roll over part code ----------------

///////////////////\\\\\\\\\\\\\\\\\\/////////////\\\\\\\\\\\\\\
function buttonOver() {
      _loc1 = this._parent._parent;
      trace("which one is roll over now --  "+this._parent);
      this._parent.gotoAndStop(6);
      _loc1.myName = _loc1.projects[i];
      //_loc1["button"+i].gotoAndStop(1);
      mc = _loc1["myTarget"+this._parent.i];
      mc._xscale = mc._yscale=120;
      prev_width = this._parent._width;
      this._parent._xscale = this._parent._yscale=120;
      after_width = this._parent._width;
      this._parent.buffer = (after_width-prev_width)/2;
      this._parent._x -= this._parent.buffer;
      this._parent._y -= this._parent.buffer;
      mc._x -= this._parent.buffer;
      mc._y -= this._parent.buffer;
      mc.swapDepths(120);
      this._parent.swapDepths(121);
}
///////////////////\\\\\\\\\\\\\\\\\\/////////////\\\\\\\\\\\\\\
0
Comment
Question by:mingchih
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 3
6 Comments
 
LVL 34

Accepted Solution

by:
Aneesh Chopra earned 2000 total points
ID: 18856155
You need to do this changes to make button rollover work:
-------------
remove following code completely from button movieclip first frame:
----------
//remove it completely
btn.onRollOut = _parent.buttonOut;  //remove it
btn.onRollOver = _parent.buttonOver;  // remove it
btn.onRelease = _parent.buttonClick; //remove it
--------------

add following code just below this line:
----------
mc = ScrollMovie.attachMovie("button", "button"+i, 50+i);
//add following code here:
mc.btn.onRollOut = buttonOut;
mc.btn.onRollOver = buttonOver;
mc.btn.onRelease = buttonClick;
//---------------------

- Aneesh Chopra


0
 
LVL 34

Assisted Solution

by:Aneesh Chopra
Aneesh Chopra earned 2000 total points
ID: 18856198
Uploaded the fixed version here for ur reference:
http://www.4shared.com/file/13517357/bd97c773/netblue.html

zip contains only updated FLA, because changes are in FLA only..
replace ur FLA with this FLA and compile it to see the results

- Aneesh Chopra
0
 

Author Comment

by:mingchih
ID: 18856223
Thank you, Annesh
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 34

Expert Comment

by:Aneesh Chopra
ID: 18856290
welcome,

Plz spell my name correctly,
it is 'Aneesh' not 'Annesh'  

:)

0
 

Author Comment

by:mingchih
ID: 18856311
Opoos, sorry, by the way, I got one last small question on the function buttonClick()...

Thanks, Aneesh
0

Featured Post

Want to be a Web Developer? Get Certified Today!

Enroll in the Certified Web Development Professional course package to learn HTML, Javascript, and PHP. Build a solid foundation to work toward your dream job!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction This article is primarily concerned with ActionScript 3 and generally specific to AVM2.  Most suggestions would apply to ActionScript 2 as well, and I've noted those tips that differ between AS2 and AS3. With the advent of ActionS…
The last time I worked with Flash and Socket connections was in AS1. A recent project required flash connecting to a Socket, and sending receiving information - we figured it would be easy enough - we all know about the socket policy documents and c…
The goal of the tutorial is to teach the user how to set there setting in Adobe Flash Media Live Encoder and YouTube for optimal video and audio quality.
The goal of the tutorial is to teach the user how to select which audio input to use. Once you have an audio input plugged into the laptop or computer, you will go into the audio input settings and choose which audio input you want to use.
Suggested Courses

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question