楼主: 莺燕音画

[教程] 让世界充满LOVE

  [复制链接]

该用户从未签到

鲜花(0) 鸡蛋(0)
发表于 2011-6-25 16:48 | 显示全部楼层
很好 看看

该用户从未签到

鲜花(0) 鸡蛋(0)
发表于 2011-7-12 22:06 | 显示全部楼层
cvnnnnnnnnnnnnnnnnn

该用户从未签到

鲜花(0) 鸡蛋(0)
发表于 2011-7-19 11:11 | 显示全部楼层
学习了

该用户从未签到

鲜花(0) 鸡蛋(0)
发表于 2011-7-19 11:16 | 显示全部楼层
本帖最后由 RUHONG 于 2011-7-19 11:22 编辑

看一看效果

该用户从未签到

鲜花(0) 鸡蛋(0)
发表于 2011-7-20 18:25 | 显示全部楼层
看看吧

该用户从未签到

鲜花(0) 鸡蛋(0)
发表于 2011-7-20 23:35 | 显示全部楼层
感谢roger01rao

该用户从未签到

鲜花(0) 鸡蛋(0)
发表于 2011-7-20 23:36 | 显示全部楼层


<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>爱的世界</title>
<meta name="Author" content="【莺燕音画】">
<style type="text/css">
body {cursor:crosshair; background:#000; margin:0; padding:0; position:absolute; overflow:hidden; left:0; top:0; width:100%; height:100%;}
</style>

<><script type="text/javascript"><!--

<>var M = new Array();
M[0] = " 0 1 1 0 0 111111 "
M[1] = " 0 1 1 0 0 1 "
M[2] = " 0 1 1 0 0 1 "
M[3] = " 0 1 1 0 0 1 "
M[4] = " 0 1 1 0 0 111111 "
M[5] = " 0 1 1 0 0 1 "
M[6] = " 0 1 1 0 0 1 "
M[7] = " 0 1 1 0 0 1 "
M[8] = " 0000 1 1 0 111111 "

var object = new Array();
var nx = 0;
var ny = 0;
var nX = 0;
var nY = 0;
var xm = 0;
var ym = 0;

function CObj(N,img,x1,y1,tmp){

this.img = document.createElement("img");
this.img.src = img.src;
this.img.style.position = "absolute";
this.img.style.left = -1000;
document.body.appendChild(this.img);

this.N = N;
this.sx = img.width/2;
this.x0 = 0;
this.y0 = 0;
this.x1 = x1;
this.y1 = y1;
this.sto = "object["+N+"].depl();"

this.depl = function() {
with (this) {
x = (x1-x0+nX)*.1;
y = (y1-y0+nY)*.1;
if(Math.abs(x+y)>0.0001){
x0 = x0+x;
y0 = y0+y;
img.style.left = x0;
img.style.top = y0;
} else {
x0 = xm-sx;
y0 = ym-sx;
}
setTimeout(sto,30);
}
}

this.start = function() {
with(this) {
x0 = xm-sx;
y0 = ym-sx;
depl();
}
}

setTimeout("object[" + N + "].start()",tmp);
}

function resize(){
nx = document.body.offsetWidth;
ny = document.body.offsetHeight;
nX = (nx-(M[0].length*15))/2;
nY = (ny-(M.length*15))/2;
}
onresize = resize;

onload = function() {
imgsrc = document.getElementById("doot").getElementsByTagName("img");
resize();
xm = nx/2;
ym = ny/2.5;

document.onmousemove = function(e) {
if (window.event) e = window.event;
xm = (e.x || e.clientX);
ym = (e.y || e.clientY);
}

k = 0;
for(i=0; i<M[0].length; i++){
for(j in M){
c = M[j].charAt(i);
if(c!=" ")object[k] = new CObj(k++, imgsrc[c*1], i*15, j*15, k*50);
}
}
}


//-->
</script>
</head>

<body>

<div style="LEFT: 0px; POSITION: absolute; TOP: 0px" align="left"><img style="FILTER: alpha(opacity=90, finishOpacity=0,style=2)" src="world.jpg" /></div>

<div id="doot" style="display:none">
<img src="boulMP11.gif">
<img src="bouleGris1.gif">
</div>

</body>
</html>

该用户从未签到

鲜花(0) 鸡蛋(0)
发表于 2011-7-29 23:00 | 显示全部楼层
我也来学习学习

该用户从未签到

鲜花(0) 鸡蛋(0)
发表于 2011-7-30 08:39 | 显示全部楼层
看看!学习一下!~

该用户从未签到

鲜花(0) 鸡蛋(0)
发表于 2011-8-16 11:50 | 显示全部楼层
进来学学
您需要登录后才可以回帖 登录 | 中文注册

本版积分规则

网站地图|小黑屋|Archiver|中画网 ( 蜀ICP备11021737号-2 )|网站地图

GMT+8, 2024-11-23 11:18 , Processed in 0.059165 second(s), 24 queries , MemCached On.

上网要文明 发言要理性

Powered by Discuz! © 2008-2023 YinHuaBBS.CN

快速回复 返回顶部 返回列表