-
button
HI all Iam khader agin in this time i have anther subject and i hope to help me in it , i am trying to make button active and not active exactlly i want to press on the button then i want to be inactive and if i press on onther button the first one return active
i just need to know hoe to do that using action script
-
Senior Member
I think you could do this by setting 2 variables in your main timeline like this
buttonOneActive = true;
buttonTwoActive = false;
on the actions for button 1 use
on (press) {
if (_root.buttonOneActive) {
// do any actions you want button 1 to do and then make button 2 the active button
_root.buttonOneActive = false;
_root.buttonTwoActive = true;
}
}
then on button 2 use
on (press) {
if (_root.buttonTwoActive) {
// do any actions you want button 2 to do and then make button 1 the active button
_root.buttonOneActive = true;
_root.buttonTwoActive = false;
}
}
-
button
thanx and i want to continou help me
relly it's good ,but ineed put button1 over button2 and i need to press on button 1 then disappear and press on button2 (which is below button 2 ) and so
ok
-
Senior Member
How about this,
create movie clip, in frame 1 of this clip add a stop(); acrion and put your button 1 on button 1 attach the actions
on (press) {
// do whatever you want button 1 to do
nextFrame();
}
in frame 2 of the clip put button 2 and on button 2 use
on (press) {
// do whatever you want button 2 to do
prevFrame();
}
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|