dcsimg
A Flash Developer Resource Site

Results 1 to 12 of 12

Thread: any more like these resizing sites?

  1. #1
    Senior Member mal pacino's Avatar
    Join Date
    Jul 2003
    Location
    England - and it's going down the pan!
    Posts
    996

    any more like these resizing sites?

    do you know of any other sites that use this resizing technique like the following:



    http://www.dubko.com



    and



    http://www.braingiants.com





    It would be useful to have some examples because I am writing an essay about this for my course.



    Thank you.

  2. #2
    Senior Member pellepiano's Avatar
    Join Date
    Feb 2000
    Location
    Stockholm, Sweden
    Posts
    15,151
    Heres a start. A code to resize a movieclip with easing. Put it ON the movieclip to be resized.

    //Elasticity on a Square
    onClipEvent (enterFrame) {
    // Speed
    var speed = 5;
    // Elasticity
    var viscosity = 1.2;
    // Percentage to scale to
    xscale =150;
    yscale = 150;
    //X Scale Script
    difference = xscale-this._xscale;
    xvelocity = (xvelocity+(difference)/speed)/viscosity;
    this._xscale += xvelocity;
    //Y Scale Script
    difference = yscale-this._yscale;
    xvelocity = (xvelocity+(difference)/speed)/viscosity;
    this._yscale += xvelocity;
    }

    -Pelle Piano
    // Image Gallery
    www.studiobild.com
    // Photo Blog
    http://talesofthepixel.blogspot.com

  3. #3
    Senior Member mal pacino's Avatar
    Join Date
    Jul 2003
    Location
    England - and it's going down the pan!
    Posts
    996
    pelle - i'm not trying to make a site like this - i just want some examples of sites that use this technique so i can refer to them in my essay - thanks

    do you know of any?

  4. #4
    Senior Member pellepiano's Avatar
    Join Date
    Feb 2000
    Location
    Stockholm, Sweden
    Posts
    15,151
    No. But I use this on my gallery at my site ( but its only the images that resize, not the whole site ).

    And the sections at a site I did called www.eriksoderlind.com does this too.

    -Pelle Piano
    // Image Gallery
    www.studiobild.com
    // Photo Blog
    http://talesofthepixel.blogspot.com

  5. #5
    Senior Member mal pacino's Avatar
    Join Date
    Jul 2003
    Location
    England - and it's going down the pan!
    Posts
    996
    thanks pelle

  6. #6
    Senior Member
    Join Date
    Jun 2001
    Location
    Sydney
    Posts
    124
    pellepiano,

    the expression defining xvelocity uses xvelocity.

    ?

    doesn't work


  7. #7
    Senior Member
    Join Date
    Jun 2001
    Location
    Sydney
    Posts
    124
    Figured it out.

    For anyone trying to use the above (very nice) script for elasticity submitted by pellepiano, you may find it doesn't work.

    my tip: define "xvelocity" in the frame where the movie clip first appears in the timeline.

    For example I used:
    Code:
    myMC.xvelocity = 10;

  8. #8
    Senior Member pellepiano's Avatar
    Join Date
    Feb 2000
    Location
    Stockholm, Sweden
    Posts
    15,151
    Yes, its a Flash 5 script, forgot to mention that. In MX2004 a variable has to be declared before manipulating it.

    -Pelle Piano
    // Image Gallery
    www.studiobild.com
    // Photo Blog
    http://talesofthepixel.blogspot.com

  9. #9

  10. #10
    Senior Member mal pacino's Avatar
    Join Date
    Jul 2003
    Location
    England - and it's going down the pan!
    Posts
    996
    thanks john

  11. #11
    Creative Addiction
    Join Date
    Nov 2001
    Location
    Newyork
    Posts
    91
    this code is still not working for me in flashmx2004 when i export the movie as a flash player 7 file this code stops working even if i declare the xvelocity before that

  12. #12
    Creative Addiction
    Join Date
    Nov 2001
    Location
    Newyork
    Posts
    91
    i got it have to use this.xvelocity

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center