html合成大西瓜源码,index.html

合成大西瓜
share.jpg

loading......0%

loading.gif

-->

var preloader;

var adCompleteFlag = false;

var resCompleteFlag = false;

var adEndComplete = false;

var resEndComplete = false;

judgeLanTitle();

function judgeLanTitle() {

// console.log("window.navigator.language",window.navigator.language);

if (window.navigator.language == "zh-CN" || window.navigator.language == "zh-cn") {

document.title = "小游戏:合成大西瓜";

} else if (window.navigator.language == "zh-TW") {

document.title = "小遊戲:合成大西瓜";

} else if (window.navigator.language == "zh-HK") {

document.title = "小遊戲:合成大西瓜";

} else if (window.navigator.language == "ko-KR") {

document.title = "작은 놀이:큰 수박 을 합성 하 다";

} else if (window.navigator.language == "ja-JP") {

document.title = "ミニゲーム:合成スイカ";

} else if (window.navigator.language == "th-TH") {

document.title = "เกมเล็กๆ:แตงโมสังเคราะห์";

} else {

document.title = "Little game:Synthetic watermelon";

}

}

var loadintT = document.getElementById("loadingText");

var loadintGif = document.getElementById("loadingImg")

setTimeout(function() {

loadintGif.remove();

loadintT.style.display = ""

updateLabView(0.1);

}, 1 * 1000)

window.timer = null;

window.tempSeconds = 1;

window.loadData = {};

loadData.completedCount = 0;

loadData.totalCount = 0;

onload();

function onload() {

var winHeight = document.documentElement.clientHeight;

document.getElementById("canvasDiv").style.height = winHeight + "px";

};

window.onload = function() {

document.getElementById("block-Box").style.display = "none";

}

function updateLabView(t) {

if (timer != null) {

clearInterval(timer);

}

timer = setInterval(function() {

tempSeconds++;

actualTotal();

var loadintT = document.getElementById("loadingText")

if (!loadintT) {

return;

}

loadintT.innerHTML = 'loading......' + parseInt(tempSeconds) + '%';

switch (tempSeconds) {

case 20:

updateLabView(0.2);

break;

case 40:

updateLabView(0.3);

break;

case 60:

updateLabView(0.4);

break;

case 96:

updateLabView(5);

break;

case 97:

updateLabView(10);

break;

case 98:

updateLabView(50);

break;

case 99:

updateLabView(100);

break;

default:

if (tempSeconds >= 80 && tempSeconds < 96) {

updateLabView(t + 0.1);

}

break;

}

if (tempSeconds > 100) {

clearInterval(timer);

tempSeconds = 100

loadintT.innerHTML = 'loading......' + parseInt(tempSeconds) + '%';

}

}, t * 1000);

}

function actualTotal() {

var percent = parseInt(100 * loadData.completedCount / loadData.totalCount);

if (percent > tempSeconds && loadData.totalCount > 1) {

tempSeconds = percent;

}

}

/*setTimeout("ShowBannerAD()","2000");*/

window.adsbygoogle = window.adsbygoogle || [];

const adBreak = function(o) {

adsbygoogle.push(o);

}

(function() {

// open web debugger console

if (typeof VConsole !== 'undefined') {

window.vConsole = new VConsole();

}

var splash = document.getElementById('splash');

splash.style.display = 'block';

console.log("indexlTextTTTT");

var cocos2d = document.createElement('script');

cocos2d.async = true;

cocos2d.src = window._CCSettings.debug ? 'cocos2d-js.js' : 'cocos2d-js-min.js';

var engineLoaded = function() {

document.body.removeChild(cocos2d);

cocos2d.removeEventListener('load', engineLoaded, false);

window.boot();

};

cocos2d.addEventListener('load', engineLoaded, false);

document.body.appendChild(cocos2d);

})();

一键复制

编辑

Web IDE

原始数据

按行查看

历史

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值