/* Variablen definieren */
var ctx;
var clouds = new Array();
var timeout_title;



function init(){
    
    /* Wolken erstellen, falls nicht msie */

    if(!$.browser.msie){
        /* Wolken definieren */
        clouds.push({"object":"cloud","x":0,"y":120,"scale":0.5,"step":0.3,"alpha":0.9});
        clouds.push({"object":"cloud","x":790,"y":200,"scale":1,"step":0.5,"alpha":0.8});
        clouds.push({"object":"cloud","x":790,"y":270,"scale":0.3,"step":1,"alpha":1});

        /* Wolken zeichnen */
        $("#canvas").attr("width",$("body").width());
        try{
            ctx = $("#canvas")[0].getContext("2d");
            if(ctx!=null){
                drawClouds(clouds);
            }

        } catch(err) {
            $.console(err,"error");
        }
    }

    /* Events erstellen 

    // Show Bubble >> beim Titel Bild.
    $("#logo").hover(
        function(){
            timeout_title = setTimeout(function(){
                $("#logo").showBubble("Hallo");
            },1000);
        },
        function(){
            clearTimeout(timeout_title);
        }
    );*/
}

$(function(){
    init();
});
