partikel efek kembang api

بِسْــــــــــــــــمِ اﷲِالرَّحْمَنِ اارَّحِيم

Posted by mukhammad nur Senin, 03 Desember 2012 0 komentar
Cara membuat partikel efek kembang api  bisa anda dapatkan script AS3 di bawah, sebelumnya anda buka dulu adobe flash milik anda, buat file baru , lanjutkan sendiri , jangan lupa tulis script di tempat Flash anda. coba baca juga : efek salju dg flash


In this free Flash ActionScript 3.0 source file and video tutorial we learn an interesting ActionScript 3.0 particle effect for making an animated fourth of july rocket blast. It uses tween effects to pull it off and also uses MOTION_FINISH event listeners on certain tweens to time things out correctly. I made this very quickly and it may have bugs... it is just an example made for people to learn advanced tween techniques and particle effect basics.
coba anda belajar dasar partikel salju flash
Demo
Download Source Files





import fl.transitions.*;
import fl.transitions.easing.*;
// AS3 Script created by Adam Khoury @ www.developphp.com
// I made this very quickly and it may have some bugs
var i:uint;
var maxParts:uint;
var firstParticle:lilstar = new lilstar;
rocket1_btn.addEventListener(MouseEvent.CLICK, shootRocket1);
function shootRocket1 (event:MouseEvent):void {
rocket1_btn.visible = false;
addChild(firstParticle);
var rocket1FlyY:Tween = new Tween(firstParticle, "y", None.easeOut, 300, 120, 1, true);
var rocket1FlyX:Tween = new Tween(firstParticle, "x", None.easeOut, 200, 225, 1, true);
rocket1FlyY.addEventListener(TweenEvent.MOTION_FINISH, rocket1Explode);
function rocket1Explode(event:TweenEvent):void {
var explosionPoint:Number = firstParticle.y;
removeChild(firstParticle);
maxParts = 18;
for (i = 0; i < maxParts; i++) {
var randNum1:Number = (Math.random() * 150) - 10 + 150;
var randNum2:Number = (Math.random() * 150) - 10 + 50;
var particle:lilstar = new lilstar;
addChildAt(particle, 0);
var particleFlyX:Tween = new Tween(particle, "x", Strong.easeOut, 225, randNum1, 4, true);
var particleFlyY:Tween = new Tween(particle, "y", Strong.easeOut, explosionPoint, randNum2, 4, true);
var particleFade:Tween = new Tween(particle, "alpha", Strong.easeOut, 1, 0, 3, true);
particleFade.addEventListener(TweenEvent.MOTION_FINISH, removeParticle);
function removeParticle(event:TweenEvent):void {
removeChildAt(0);
rocket1_btn.visible = true;
}
}
}
}


Demikian trik membuat partikel efek kembang api. semoga bermanfaat.






sumber : http://www.developphp.com/view.php?tid=294
TERIMA KASIH ATAS KUNJUNGAN SAUDARA
Judul: partikel efek kembang api
Ditulis oleh mukhammad nur
Rating Blog 5 dari 5
Semoga artikel ini bermanfaat bagi saudara. Jika ingin mengutip, baik itu sebagian atau keseluruhan dari isi artikel ini harap menyertakan link dofollow ke http://cintafido.blogspot.com/2012/12/partikel-efek-kembang-api.html. Terima kasih sudah singgah membaca artikel ini.

0 komentar:

Posting Komentar

Panduan blog dan SEO support Online Skill - Cinta fido Fido | Kopi kanan Akherat | Kisah Nabi Muhammad | Sahabat | Belajar Blogger | Template | HTML | Tutorial | Komputer.

investasi semoga anda senang

kurs mata uang BCA-2


Selamat datang di blog cinta fido, semoga anda diberi keSehatan oleh alloh SWT

Islam itu Cinta Damai Agama Islam Cinta Damai
jihad Damai adalah amal kebaikan yang Allah perintahkan dan menjadi sebab kokoh dan kemuliaan umat islam