MonozCore

Blogging for fun

Followers

Cursor Trail Art Of Fighting Saga


Cursor Trail Art Of Fighting Saga merupakan widget bertemakan karakter-karakter dari game Art of Fighting yang terkenal. Game Neo Geo besutan SNK yang berjudul Art of Fighting ini merupakan game bergenre fighting yang terkenal di era permainan ding-dong dan merupakan salah satu game favorit saya. Karakter favorit dari game Art of Fighting adalah Robert Garcia dan Ryo. Oke sob... cukup sekian intronya kita lanjutkan pembahasannya. Widget cursor trail merupakan salah satu ciri khas postingan artikel yang ada di blog MonozCore dengan beberapa postingan artikelnya seperti :

- Hello Kitty Cursor Trail
- Mortal Kombat Cursor Trail 2
- Explosion Cursor Trail
- Mortal Kombat Female Ninja Cursor Trail
- Mortal Kombat Ninja Cursor Trail
- Saint Saiya Cursor Trail
- TMNT Cursor Trail
- Sailormoon Cursor Trail
- Naruto Cursor Trail
- Tinkerbell Fairy Cursor Trail
- Doraemon Cursor Trail
- Cursor Effect Bubble Trail

Oke sob sama seperti widget cursor trail yang sudah pernah dibuat dengan sedikit modifikasi dan update script untuk memudahkan pemasangan, widget ini menggunakan JavaScript sederhana dan tidak akan memberatkan workload browser untuk blog sobat untuk contoh seperti yang terlihat pada postingan artikel ini... Buat yang tertarik memasang widget ini langsung aja ke TKP...

Cara Pemasangan
  • Login » blogger.
  • Rancangan » Edit HTML.
  • Tekan tombol keyboard Ctrl+F dan cari kode berikut: </Body>
  • Copy-Paste kode di bawah ini tepat di atas Kode </Body> atau bisa juga langsung ditaruh di kotak gadget sebagai widget untuk mempermudah pemasangan scriptnya.

    /* http://monozcore.blogspot.com Visit us to get more updates */
    
    /* Put CSS Style Element to Body */
    $('body').append('<style type="text/css">.imgLayerTrail {position:absolute;top:0px;left:0px;visibility:hidden;}</style>');
    
    /* Image Variabel URL */
    theimage1 = "http://3.bp.blogspot.com/-HYfXwbFT_ls/WVjQn1xWhVI/AAAAAAAAIFs/wSKgvtS-vY0kB_dk5KE9bngKFx4v6H1_ACLcBGAs/s1600/artoffighting.gif";
    theimage2 = "http://3.bp.blogspot.com/-PvzCWSQqu8U/WVjQngJI1DI/AAAAAAAAIFk/bWgOrwYxyM0Ur1nxH8gQzvd1YQG0bx-kQCLcBGAs/s1600/artoffighting1.gif";
    theimage3 = "http://2.bp.blogspot.com/-rnHIe4yHkH8/WVjQorE1aNI/AAAAAAAAIF4/hfHhsBN5-pcz6aw319woo0FmDMo1Q27EACLcBGAs/s1600/artoffighting3.gif";
    theimage4 = "http://4.bp.blogspot.com/-tAG543Gro18/WVjQoTHUzAI/AAAAAAAAIFw/YdkkPoylTRUNOeOd8vtu7J-HGHVFeduGwCLcBGAs/s1600/artoffighting14.gif";
    theimage5 = "http://2.bp.blogspot.com/-PfqX5vS31eY/WVjQoUrBFUI/AAAAAAAAIF0/Ebb091lG2yUuVyYBtWLRmcCEbniX0EqoACLcBGAs/s1600/artoffighting15.gif";
    theimage6 = "http://2.bp.blogspot.com/-e1aTcBNKGu8/WVjQn2xqQvI/AAAAAAAAIFo/jpi-jVUEv30UiXPMSnGFYen_xgoJhAmewCLcBGAs/s1600/artoffighting13.gif";
    
    /* Setting */
    imageCount = 15;   /*maximum number of images on screen at one time*/
    curImage = 0;      /*the last image DIV to be displayed (used for timer)*/
    imageDelay = 1000; /*duration images stay on screen (in milliseconds)*/
    imageSpacer = 80;  /*distance to move mouse b4 next image appears*/
    
    /* Browser checking and syntax variables */
    var docLayers = (document.layers) ? true:false;
    var docId = (document.getElementById) ? true:false;
    var docAll = (document.all) ? true:false;
    var docbitK = (docLayers) ? "document.layers['":(docId) ? "document.getElementById('":(docAll) ? "document.all['":"document.";
    var docbitendK = (docLayers) ? "']":(docId) ? "')":(docAll) ? "']":"";
    var stylebitK = (docLayers) ? "":".style";
    var showbitK = (docLayers) ? "show":"visible";
    var hidebitK = (docLayers) ? "hide":"hidden";
    var imgns6 = document.getElementById&&!document.all;
    
    /* Variables used in script */
    var imgPosX, imgposY, imglastX, imglastY, imageCount, curImage, imageDelay, imageSpacer, theimage;
    var imglastX = 0;
    var imglastY = 0;
    
    /* Collection of functions to get mouse position and place the images */
    function doImgTrail(e) {
    imgPosX = getMouseXPos(e);
    imgposY = getMouseYPos(e);
    if (imgPosX>(imglastX+imageSpacer)||imgPosX<(imglastX-imageSpacer)||imgposY>(imglastY+imageSpacer)||imgposY<(imglastY-imageSpacer)) {
        showImgTrail(imgPosX,imgposY);
        imglastX = imgPosX;
        imglastY = imgposY;
    }}
    /* Get the horizontal position of the mouse */
    function getMouseXPos(e) {
      if (document.layers||imgns6) {
        return parseInt(e.pageX+10);
      } else {
        return (parseInt(event.clientX+10) + parseInt(document.body.scrollLeft));
    }}
    /* Get the vartical position of the mouse */
    function getMouseYPos(e) {
      if (document.layers||imgns6) {
        return parseInt(e.pageY);
      } else {
        return (parseInt(event.clientY) + parseInt(document.body.scrollTop));
    }}
    /* Place the image and start timer so that it disappears after a period of time */
    function showImgTrail(x,y) {
      var processedx=imgns6? Math.min(x,window.innerWidth-75) : docAll? Math.min(x,document.body.clientWidth-55) : x;
      if (curImage >= imageCount) {curImage = 0}
       $('#imgLayerTrail' + curImage).css('left', processedx+'px');
       $('#imgLayerTrail' + curImage).css('top', y+'px');
      eval(docbitK + "imgLayerTrail" + curImage + docbitendK + stylebitK + ".visibility = '" + showbitK + "'");
      if (eval("typeof(imageDelay" + curImage + ")")=="number") {
        eval("clearTimeout(imageDelay" + curImage + ")");
      }
      eval("imageDelay" + curImage + " = setTimeout('hideImgTrail(" + curImage + ")',imageDelay)");
      curImage += 1;
    }
    /* Make the image disappear */
    function hideImgTrail(kImgNum) {
      eval(docbitK + "imgLayerTrail" + kImgNum + docbitendK + stylebitK + ".visibility = '" + hidebitK + "'");
    }
    /* http://monozcore.blogspot.com Visit us to get more updates */
    function imageAniBegin(){
    /* Let the browser know when the mouse moves */
    if (docLayers) {
      document.captureEvents(Event.MOUSEMOVE);
      document.onMouseMove = doImgTrail;
    } else {
      document.onmousemove = doImgTrail;
    }}
    
    /* Write Document HTML using jQuery for easy applied */
    if (document.all||document.getElementById||document.layers){
    for (kImg=0;kImg<imageCount;kImg=kImg+5) {
    var strHTMLTrail='<img src="' + theimage1 + '" id="imgLayerTrail' + kImg + '" class="imgLayerTrail" alt="" border="0">';
    strHTMLTrail +='<img src="' + theimage2 + '" id="imgLayerTrail' + (kImg+1) + '" class="imgLayerTrail" alt="" border="0">';
    strHTMLTrail +='<img src="' + theimage3 + '" id="imgLayerTrail' + (kImg+2) + '" class="imgLayerTrail" alt="" border="0">';
    strHTMLTrail +='<img src="' + theimage4 + '" id="imgLayerTrail' + (kImg+3) + '" class="imgLayerTrail" alt="" border="0">';
    strHTMLTrail +='<img src="' + theimage5 + '" id="imgLayerTrail' + (kImg+4) + '" class="imgLayerTrail" alt="" border="0">';
    strHTMLTrail +='<img src="' + theimage6 + '" id="imgLayerTrail' + (kImg+5) + '" class="imgLayerTrail" alt="" border="0">';
    $('body').append(strHTMLTrail);
    }}
    imageAniBegin();

  • Keterangan :
    - Apabila ingin menggunakan gambar Karakter Art of Fighting yang lain silakan dirubah URL Images pada kode script diatas.
  • Klik "Save" dan lihat hasilnya
Oke sobat monozcore jangan lupa kritik dan sarannya yaa biar postingan berikutnya semakin unik dan menarik.. Buat yang masih bingung dengan pemasangan widget ini.. monggo ditanyakan lewat kotak komentar, email, facebook ataupun twitter monozcore... happy blogging...

.:Selamat Mencoba:.
Bagikan :
+
Previous
Next Post »
Comments
Tweets
0 Comments

0 Komentar untuk "Cursor Trail Art Of Fighting Saga"

Yahoo Minion UpinIpin Kaskus Special-Code

Recent Comments

 
Copyright © 2010 MonozCore - All Rights Reserved
Back To Top