function initUi(){
ui = new ThreeUI(renderer.domElement, 750 * window.innerHeight/window.innerWidth/*window.innerHeight*/, true);
drawListBg();
spriteSc = ui.createMvCvsSprite(itemCanvas,0, 0, 750 - 80 * 2, 590, 80, 350, 750 - 80 * 2, 590);
var count_uiRedraw = 0;
var flag_uiRedraw = setInterval(function(max) {
if (count_uiRedraw >= max) {
clearInterval(flag_uiRedraw);
return;
}
ui.shouldReDraw = true
count_uiRedraw = count_uiRedraw + 1;
}, 1000, 3);
}
function drawListBg(){
const rectangle1 = ui.createRectangle('rgba(0, 0, 0, 0.5)', 0, 0, ui.width, ui.height);
const rectangle2 = ui.createRectangle('#302F30', 80, 290, 750 - 80 * 2, 650);
const text = ui.createText('好友排行榜', 50, 'Arial', '#fff', 750 / 2, 220); text.textAlign = 'center';
const text1 = ui.createText('每周一凌晨刷新', 20, 'Arial', '#8D8D8D', 100, 330); //text1.textBaseline = 'alphabetic';
const rectangle3 = ui.createRectangle('#302F30', 80, 960, 750 - 80 * 2, 120);
AssetLoader.add.image('return.png');
AssetLoader.load(function() {
var sprite1 = ui.createSprite('return.png', 80, 1120, 100, 100);
});
}
网友评论