Article View: adobe.livemotion
Article #15867Re: ATTN: Phil S, Jon T, Joe B, and others... I have one final question from a previous problem
From: Jeremy Hendrickson
Date: Thu, 09 May 2002 21:30
Date: Thu, 09 May 2002 21:30
27 lines
3541 bytes
3541 bytes
Spurtnik:
Thank you for your insightful comments placed within the LIV. If you don�t mind, I�m going to go ahead and post them here for the benefit of everyone. I will comment further on another post.
- - - - - - - - BEGINNING OF SPURTNIK'S COMMENTS IN LIV FILE - - - - - - - -
�I cheated and added the square "bounds" objects behind each button. Since you grouped your buttons, that threw off the respective coordinates of each button. That would then require some translation of the coordinates of each of your buttons (That whole GlobalToLocal or LocalToGlobal thing. Easier to create a button, match it to the color of the background and place it behind each of your fancy buttons. Much easier than to place and track the coordinates of these buttons for your purposes. My buttons are "geometric" (combined) squares with the dimensions of 34x34. The x,y dimensions of each button then would be (from leftmost to rightmost) and upper right to lower left:
button 1 = 7,10 - 41,44 button 2 = 55,10 - 89,44 button 3 = 102,10 - 136,44 button 4 = 149,10 - 183,44 button 5 = 196,10 - 230,44 button 6 = 243,10 - 277,44 button 7 = 290,10 - 324,44 button 8 = 337,10 - 371,44 button 9 = 384,10 - 418,44
I just pulled the numbers from the Transform tab.
I haven't entered any code yet, but, what I'm thinking is, to set a variable condition (pseudo code): This is code that would be set whenever a button is clicked. The results of this variable would then need to be placed so as to be available to each buttons corresponding "bounds" button. EG: When the "homebtn" is clicked, Click would be true and would then need to be available to it's corresponding background button: "bounds1"
Click = boolean If(Button is down){ Click = True; } else { Click = False; }
Then under each bounds# button set the following:
Set Variables:
Upper left _x coordinate = LM (Left Margin); Upper left _y coordinate = TM (Top Margin); Lower left _x coordinate = RM (Right Margin); Lower left _y coordinate = BM (Bottom Margin);
If(Click = true AND mouse._x < LM OR mouse._y < TM OR Click = true and mouse._x > RM OR mouse._y > BM){ Action = GotoAndPlay(Move text); Reset Click (Click = False); }
This, theoretically, should test the boundaries of the mouse against the margin variables of _x and _y. If the mouse moves outside those boundaries, your action should kick in. The Click variable would then have to be reset, since the mouse has moved outside the boundaries of the button. Otherwise it would remain set at True, which would not be desired, I would think.�
- - - - - - - - END OF SPURTNIK'S COMMENTS IN LIV FILE - - - - - - - -
Technical Details
Message-ID:
<ef8666e.6@WebX.aaQKaf7vad4>Path:
arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-01!supernews.com!newsfeed.online.be!newsfeed01.sul.t-online.de!t-online.de!WebXReferences:
<ef8666e.-1@WebX.aaQKaf7vad4>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII X-Google-Thread: f6a55,94da54411efa17de X-Google-Attributes: gidf6a55,public X-Google-ArrivalTime: 2002-05-09 14:37:53 PST From: "Jeremy Hendrickson" <jeremyandrebecca@yahoo.com> Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-01!supernews.com!newsfeed.online.be!newsfeed01.sul.t-online.de!t-online.de!WebX Newsgroups: adobe.livemotion Subject: Re: ATTN: Phil S, Jon T, Joe B, and others... I have one final question from a previous problem Message-ID: <ef8666e.6@WebX.aaQKaf7vad4> Date: Thu, 9 May 2002 14:30:17 -0700 References: <ef8666e.-1@WebX.aaQKaf7vad4> Lines: 72 MIME-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 8bit