jquery砸金蛋 高仿阿里旅游砸金蛋

清华大佬耗费三个月吐血整理的几百G的资源,免费分享!....>>>

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
function zadan(obj) {
 
    $(obj).children("span").hide();
 
    eggClick($(obj));
 
};
 
function donghua() {
 
    $("#hammer").animate({
 
        top : "150px",
 
        left : "420px"
 
    }, 1000);
 
    $("#hammer").animate({
 
        top : "110px",
 
        left : "455px"
 
    }, 1000);
 
  
 
}
 
var dingshi = setInterval("donghua()", 2000);
 
var dansui = 1;
 
function eggClick(obj) {
 
  
 
    if (dansui == 0) {
 
        alert("蛋都碎掉了");
 
        return;
 
    }
 
  
 
    $("#hammer").stop(true);
 
    clearInterval(dingshi);
 
    var _this = obj;
 
  
 
    $(".hammer").css({
 
        "top" : "170px",
 
        "left" : "420px"
 
    });
 
    setTimeout(function () {
 
        _this.addClass("curr"); //蛋碎效果
 
        _this.find("sup").show(); //金花四溅
 
        $(".hammer").hide(); //隐藏锤子
 
        $('.resultTip').css({
 
            display : 'block',
 
            top : '280px',
 
            left : '315px',
 
            opacity : 0
 
        }).animate({
 
            top : '240px',
 
            opacity : 1
 
        }, 300, function () {
 
            dansui = 0;
 
            $("#result").html("恭喜,您中得" + rs.data.prize);
 
  
 
        })
 
    }, 300);
 
  
 
}