-
I would like to make a bitmap picture of a flag wave like in the movie below:
http://www.flashkit.com/movies/Effec...5398/index.php
The one selection(wave)is the one I am talking about.
It is difficult for me to learn from that how the wave selection could be programmed. It has alot to do with math so I thought I would include this in this forum.
I looked at another post about this same effect but saw no resolution.
http://board.flashkit.com/board/show...hreadid=188273
In this post they referred to a website that uses this effect in its opening.
http://www.che-lives.com/
Thanks!
-
ism
-
Hey thanks! I think that it is going to work.
-
New Problem
Hi, i followed the tutorial link here and it didnt work.
I need to make a black and white chequered flag in flash.
im guessing i need sine?
any ideas to get me going would be great!
-
Monkey Moderator
Assuming you have split your image up into slices and laid them out o stage you can use this kind of function to apply the sine wave, giving the flag effect. You will need to name your flag slices as "flag1", "flag2" ..... "flagN" etc.
code:
// settings //
var numSects = 20; // Number of segments in your flag
var startY = 20; // mid y point
var size = 20; // size of flag movement
var speed = 10; // smaller = faster speed
// -------- //
var inc = (2*Math.PI)/numSects;
var w=0;
// onEnterFrame action
this.onEnterFrame = function(){
for(i=1;i<=numSects;i++){
this["flag"+i]._y = startY + Math.sin((w/speed)+(inc*i))*size;
}
w++;
}
www.lexicon-design.co.uk
If we aren't supposed to eat animals, then why are they made of meat?
If Vegetarians like animals so much, why do they eat all their food?
-
Hi, Cheers man, thats excelent. im gonna have a go, and if you dont hear any more, thanks again.
-
-
Monkey Moderator
Enjoy
Once you know the methods, it only takes a couple of seconds to code so no need to feel lazy
www.lexicon-design.co.uk
If we aren't supposed to eat animals, then why are they made of meat?
If Vegetarians like animals so much, why do they eat all their food?
-
hi everyone
an old thread, but i cant work out how to do this! need to get a nice cheqeured flag effect...any ideas?!
thanks!
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
|