利用Tweener製作動畫 – 廣告看板
依然是Tweener範例清倉,本篇範例大致是搭配Tweener讓目標物移動到指定座標的效果,話不多說看範例吧!
Tweener 橫幅廣告 範例:主要為利用Tweener針對廣告看板進行移動,以下為本範例的程式碼:
import caurina.transitions.Tweener; var i:int;//迴圈用變數 var pic:int = 1;//播放張數紀錄變數 var clock;//計時器變數 //按鈕變色與監聽 btnChange(); function btnChange() { for (i=1; i<=4; i++) { this["b" + i].gotoAndStop(1); this["b" + pic].gotoAndStop(2); } } for (i=1; i<=4; i++) { this["b" + i].addEventListener(MouseEvent.CLICK,clickFn); } function clickFn(e:MouseEvent) { clearInterval(clock); clock = setInterval(autoChange,5000); pic = e.currentTarget.name.substr(1,1); bannerChange(); btnChange(); } //計時器設定(每5秒更換) clock = setInterval(autoChange,5000); function autoChange() { pic++; if (pic>4) { pic = 1; } bannerChange(); btnChange(); } //圖片切換函數 function bannerChange() { Tweener.addTween(banner, {x:(pic-1)*-560, time:1, transition:"easeOutQuint"}); }
Tweener 移動看板 範例:與上面範例大致相同,不過本範例增加了縱向的移動。
import caurina.transitions.Tweener var i var j var targetX var targetY for(i=1;i<=3;i++){ for(j=1;j<=3;j++){ this["b"+i+j].addEventListener(MouseEvent.CLICK,moveFn) } } function moveFn(e:MouseEvent){ targetX=(e.currentTarget.name.substr(2,1)-1)*-450 targetY=(e.currentTarget.name.substr(1,1)-1)*-450 Tweener.addTween(nb, {x:targetX, y:targetY, time:2, transition:"easeOutQuint"}); }
Hello! Do you know if they make any plugins to help with Search Engine Optimization? I’m trying to get my site to
rank for some targeted keywords but I’m not seeing very good
results. If you know of any please share. Kudos! I saw similar blog here:
Auto Approve List
Discover best security cameras at pssonsite.net! Browse our selection of the best security cameras to safeguard your home or business. Our cameras offer advanced features for enhanced surveillance and peace of mind. Explore pssonsite.net today for premium security solutions.
Looking for a laptop? Check out PhoneU.ca for a wide selection of quality laptop for sale! Browse now for great deals!
Looking for a chiropractor near me? Visit alignedchiro.com.au for expert care and relief from discomfort. Your wellness journey starts here!
Find luxury transportation for any occasion with JSM Black Limousine’s Limo for rentservices. Book now for a stylish and comfortable ride. Visit jsmblacklimousine.ca.
Discover the ultimate solution for luscious locks with BodyandBlast ladies perfume. Our specially formulated serum nourishes and revitalizes your hair, leaving it silky-smooth and irresistibly shiny. Say goodbye to frizz and hello to manageable, radiant hair. Experience the transformation and unleash your hair’s natural beauty with BodyandBlast Hair Serum.
sandyterrace.com
하지만 지금 이 순간… 작업장 전체가 혼란에 휩싸였습니다.
hydroxyzine price – buy pamelor pills for sale brand endep
anafranil without prescription – cymbalta 20mg sale doxepin 25mg tablet
purchase seroquel – buy desyrel 100mg generic cheap eskalith without prescription
buspirone and clonazepam
anxiety medication celexa
ashwagandha nootropic
order clozapine 50mg pill – buy clozaril cheap famotidine 20mg generic
Arsenal Hospitality
celecoxib recreational
bupropion and phentermine
augmentin coverage
gabapentin and baclofen together
retrovir 300 mg generic – allopurinol us
glucophage buy online – buy glucophage 500mg pill buy lincocin 500 mg online cheap
how many celebrex can you take a day
amitriptyline for neuropathy
It’s very interesting! If you need help, look here: ARA Agency
Hello there! Do you know if they make any plugins to help with Search Engine
Optimization? I’m trying to get my blog to rank for some targeted keywords but I’m not seeing very good success.
If you know of any please share. Thank you! You can read
similar text here: Najlepszy sklep
aspirin / butalbital / caffeine
purchase furosemide for sale – furosemide 100mg without prescription order capoten online
aripiprazole package insert pdf
Thanks for the blog loaded with so many information. Stopping by your blog helped me to get what I was looking for.
click here: olympia gold testosterone review
allopurinol dosage for acute gout