Home Tutorials Forums Articles Blogs Movies Library Employment Press
Old 05-05-2005, 09:04 PM   #1
cxn926
no
 
cxn926's Avatar
 
Join Date: Mar 2005
Posts: 719
Default User can scale

i want it so that the person that is using the flash can scale the mc's or a picture

cheers,
michael
cxn926 is offline   Reply With Quote
Old 05-05-2005, 09:06 PM   #2
red penguin
[^\d\D]
 
red penguin's Avatar
 
Join Date: Jun 2001
Location: Brooklyn, NY
Posts: 3,254
Default

I want a billion Euro Dollars.
__________________

komielan.com
red penguin is offline   Reply With Quote
Old 05-05-2005, 09:17 PM   #3
lelales
forever learning
 
lelales's Avatar
 
Join Date: Aug 2004
Location: New Olreans
Posts: 1,261
Send a message via AIM to lelales Send a message via Yahoo to lelales
Default I think you want to look into

look into x_scale and y_scale and startdrag.
(might be xscale anbd yscale)

Or you could compare it to the mouse movement on the x and y coordinates.
lelales is offline   Reply With Quote
Old 05-05-2005, 09:18 PM   #4
cxn926
no
 
cxn926's Avatar
 
Join Date: Mar 2005
Posts: 719
Default

but i mean as in when they touch the sides
cxn926 is offline   Reply With Quote
Old 05-05-2005, 09:23 PM   #5
lelales
forever learning
 
lelales's Avatar
 
Join Date: Aug 2004
Location: New Olreans
Posts: 1,261
Send a message via AIM to lelales Send a message via Yahoo to lelales
Default try this

on.rollOver(this._xscale=200, this._yscale=200);

the syntax maybe off but that's a general direction

Last edited by lelales; 05-05-2005 at 09:34 PM.
lelales is offline   Reply With Quote
Old 05-05-2005, 09:45 PM   #6
lelales
forever learning
 
lelales's Avatar
 
Join Date: Aug 2004
Location: New Olreans
Posts: 1,261
Send a message via AIM to lelales Send a message via Yahoo to lelales
Default here is a dynamic scaling for you

ActionScript Code:
item_mc.onMouseDown=function(){ this.targetScale=(this.parent._xmouse+this._parent._ymouse)*2; this.onEnterFrame=this.scaleMe; this.acceleration=12; this.friction=0.8; item_mc.scaleMe = function(){ var scaleDiff = this targetScale-this._xscale; this.scaleSpeed += scaleDiff/this._parent.acceleration; this.scaleSpeed*= this._parent.friction; this._yscale= this._xscale+= this.scaleSpeed; this.checkScale(); }

then


ActionScript Code:
item_mc.checkScale = function(){ if (Math.abs(this.targetScale-this._xscale)<0.2 { if (Math.abs(this.scaleSpeed)<.02){ this._xscale = this.y_scale= this.tagetScale; delete this.onEnterFrame; } } };

So when the user clicks a section of the movie, your item_mc scales.

I pulled this code straight out of FlashMX Studio by friends of Ed.

Maybe you should buy this book if the above code interests you.It has plenty of scaling examples
lelales is offline   Reply With Quote
Old 05-05-2005, 09:54 PM   #7
senocular
six eyes
 
senocular's Avatar
 
Join Date: Jan 2003
Location: San Francisco, CA (USA)
Posts: 7,875
Send a message via ICQ to senocular Send a message via AIM to senocular Send a message via MSN to senocular Send a message via Yahoo to senocular
Default

or something like this?
http://proto.layer51.com/d.aspx?f=636
__________________
(6)
senocular is offline   Reply With Quote
Old 05-05-2005, 10:11 PM   #8
lelales
forever learning
 
lelales's Avatar
 
Join Date: Aug 2004
Location: New Olreans
Posts: 1,261
Send a message via AIM to lelales Send a message via Yahoo to lelales
Default Senocular is right

that site has tons of dynamic code.
lelales is offline   Reply With Quote
Old 05-05-2005, 11:20 PM   #9
Barn
digital curmudgeon
 
Barn's Avatar
 
Join Date: Feb 2005
Location: http://www.were-here.com
Posts: 1,082
Default

Quote:
Originally Posted by red penguin
I want a billion Euro Dollars.
I'm sorry, red penguin, but that's an incredibly incomplete specification.

What denominations?

What sort of containers?

What's your timeframe?

Where are you going to put it all?

Maybe you should explain specifically what it is you want to do with a billion Euro Dollars -- there might be another a way to do what you want.
Barn is offline   Reply With Quote
Reply


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump


All times are GMT. The time now is 12:16 PM.

///
Follow actionscriptorg on Twitter

 


Powered by vBulletin® Version 3.8.5
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Ad Management plugin by RedTyger
Copyright 2000-2013 ActionScript.org. All Rights Reserved.
Your use of this site is subject to our Privacy Policy and Terms of Use.