Button functionality/Animation flow issues

Button functionality/Animation flow issues

Page 1 of 1

3 Replies - 1122 Views - Last Post: 06 October 2009 - 06:10 AM

#1 r0x0rcist  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 47
  • Joined: 15-May 09

Button functionality/Animation flow issues

Posted 17 June 2009 - 12:54 PM

Listing issues with buttons by labeled name and "menu" is referencing the menu that ascends/descends upon button click.
Issues are as follows:

• When going from Cap Mod to MS Office
Tools the MS Office Tools appears to be
on the stage in place already, not easing
in but already on the stage behind the
Cap Mod menu.

• Need menus to all descend behind the
ascending menu, showing as the one
coming up on top. Currently some drop
in front and others behind. It doesn’t look
very uniform. (This is my fault, I’m sure)

• Need to make it so that buttons cannot be
clicked and button appearance cannot be
changed after that button’s menu comes
up. Only other buttons should be clickable
to prevent menus to be able to ascend
repeatedly if the user clicks the button again.


If you have an ideas or suggestions please let me know... any help at all is appreciated. I'm getting fairly frustrated with these problems and can't seem to figure it out. The "cap mod" up version of the button and the menu are not vector graphics. I am already aware of this and replacing it. The main issues I am querying here are for the animation problems that keep it not looking right. Thanks for reading, btw!!!1



import fl.transitions.Tween;
import fl.transitions.TweenEvent;
import fl.transitions.easing.*;

var xMovement:Tween;
var yMovement:Tween;

function Start():void
{
	CapModBtn.addEventListener(MouseEvent.MOUSE_DOWN, moveCapMods);
	OfficeToolsBtn.addEventListener(MouseEvent.MOUSE_DOWN, moveOfficeTools);
	LOBBtn.addEventListener(MouseEvent.MOUSE_DOWN, moveLOB);
}

function moveCapMods(even:MouseEvent):void
{
	yMovement = new Tween(LOBInfo, "y", Back.easeIn, LOBInfo.y, 413, 1, true);
	yMovement = new Tween(OfficeToolsInfo, "y", Back.easeIn, OfficeToolsInfo.y, 413, 1, true);
	xMovement = new Tween(CapModuleInfo, "x", Back.easeIn, CapModuleInfo.x, 20, 1, true);
	yMovement = new Tween(CapModuleInfo, "y", Back.easeIn, CapModuleInfo.y, 138, 1, true);
}

function moveOfficeTools(even:MouseEvent):void
{
	yMovement = new Tween(LOBInfo, "y", Back.easeIn, LOBInfo.y, 413, 1, true);
	yMovement = new Tween(CapModuleInfo, "y", Back.easeIn, CapModuleInfo.y, 413, 1, true);
	xMovement = new Tween(OfficeToolsInfo, "x", Back.easeIn, CapModuleInfo.x, 20, 1, true);
	yMovement = new Tween(OfficeToolsInfo, "y", Back.easeIn, CapModuleInfo.y, 138, 1, true);
}

function moveLOB(even:MouseEvent):void
{
	yMovement = new Tween(OfficeToolsInfo, "y", Back.easeIn, OfficeToolsInfo.y, 413, 1, true);
	yMovement = new Tween(CapModuleInfo, "y", Back.easeIn, CapModuleInfo.y, 413, 1, true);
	xMovement = new Tween(LOBInfo, "x", Back.easeIn, LOBInfo.x, 20, 1, true);
	yMovement = new Tween(LOBInfo, "y", Back.easeIn, LOBInfo.y, 138, 1, true);
}

Start();




** Edit ** :code:

Is This A Good Question/Topic? 0
  • +

Replies To: Button functionality/Animation flow issues

#2 sankar22222  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 1
  • Joined: 20-August 09

Re: Button functionality/Animation flow issues

Posted 20 August 2009 - 02:09 AM

please send me the fla .U have the problem on ur fla so send me the fla also.let me check
Was This Post Helpful? 0
  • +
  • -

#3 BetaWar  Icon User is offline

  • #include "soul.h"
  • member icon

Reputation: 1148
  • View blog
  • Posts: 7,148
  • Joined: 07-September 06

Re: Button functionality/Animation flow issues

Posted 20 August 2009 - 11:01 PM

Okay, I believe I got something like what you are trying to accomplish. Here is it:

import fl.transitions.Tween;
import fl.transitions.TweenEvent;
import fl.transitions.easing.*;

var xMovementIn:Tween;
var yMovementIn:Tween;

var xMovementOut:Tween;
var yMovementOut:Tween;

var selectedMenu:MovieClip;


function Start():void
{
	Btn1.addEventListener(MouseEvent.MOUSE_DOWN, moveCapMods);
	Btn2.addEventListener(MouseEvent.MOUSE_DOWN, moveOfficeTools);
	selectedMenu = moveOfficeInfo;
}

function moveCapMods(even:MouseEvent):void
{
	if(selectedMenu == moveCapInfo){
		return;
	}
	yMovementOut = new Tween(selectedMenu, "y", Back.easeIn, selectedMenu.y, 413, 1, true);
	selectedMenu = moveCapInfo;
	yMovementIn = new Tween(selectedMenu, "y", Back.easeIn, selectedMenu.y, 0, 1, true);
}

function moveOfficeTools(even:MouseEvent):void
{
	if(selectedMenu == moveOfficeInfo){
		return;
	}
	yMovementOut = new Tween(selectedMenu, "y", Back.easeIn, selectedMenu.y, 413, 1, true);
	selectedMenu = moveOfficeInfo;
	yMovementIn = new Tween(selectedMenu, "y", Back.easeIn, selectedMenu.y, 0, 1, true);
}

Start();


Now, I simplified things where possible (MC names, lines, not using x movement, etc.).

Hope that helps.
Was This Post Helpful? 0
  • +
  • -

#4 r0x0rcist  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 47
  • Joined: 15-May 09

Re: Button functionality/Animation flow issues

Posted 06 October 2009 - 06:10 AM

View PostBetaWar, on 21 Aug, 2009 - 12:01 AM, said:

Okay, I believe I got something like what you are trying to accomplish. Here is it:

import fl.transitions.Tween;
import fl.transitions.TweenEvent;
import fl.transitions.easing.*;

var xMovementIn:Tween;
var yMovementIn:Tween;

var xMovementOut:Tween;
var yMovementOut:Tween;

var selectedMenu:MovieClip;


function Start():void
{
	Btn1.addEventListener(MouseEvent.MOUSE_DOWN, moveCapMods);
	Btn2.addEventListener(MouseEvent.MOUSE_DOWN, moveOfficeTools);
	selectedMenu = moveOfficeInfo;
}

function moveCapMods(even:MouseEvent):void
{
	if(selectedMenu == moveCapInfo){
		return;
	}
	yMovementOut = new Tween(selectedMenu, "y", Back.easeIn, selectedMenu.y, 413, 1, true);
	selectedMenu = moveCapInfo;
	yMovementIn = new Tween(selectedMenu, "y", Back.easeIn, selectedMenu.y, 0, 1, true);
}

function moveOfficeTools(even:MouseEvent):void
{
	if(selectedMenu == moveOfficeInfo){
		return;
	}
	yMovementOut = new Tween(selectedMenu, "y", Back.easeIn, selectedMenu.y, 413, 1, true);
	selectedMenu = moveOfficeInfo;
	yMovementIn = new Tween(selectedMenu, "y", Back.easeIn, selectedMenu.y, 0, 1, true);
}

Start();


Now, I simplified things where possible (MC names, lines, not using x movement, etc.).

Hope that helps.



I'm sorry, I didn't get a notification that you replied to this post at all. I might need to set something up (?) that I haven't yet.

Thanks so much for your help. I get some errors with this code. -I know you took some out and the names don't match up. -However, I have something new I need help on. Can you see my recent posted question. -You seem to be helpful and I've yet to receive a reply from anyone. I'm flying blind, and I'm sorry, but I'd appreciate any (and I do mean any) help whatsoever ^_~

Thanks so much,

~R
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1