<body bgcolor="#ffffff">
<html><head><title>D-Machine</title>
<style type="text/css">
.dm0{position:absolute;visibility:hidden;top:-100px;font-family:Arial,Helvetica,sans-serif;font-size:50pt;color:#FF11CC;z-index:0;}
.dm1{position:absolute;visibility:hidden;top:-100px;font-family:'Times New Roman',Times,serif;font-size:40pt;color:#3300CC;z-index:0;}
.dm2{position:absolute;visibility:hidden;top:-100px;font-family:'Courier New',Courier,mono;font-size:30pt;color:#CC0011;z-index:0;}
.dm3{position:absolute;visibility:hidden;top:-100px;font-family:Gergia,'Times New Roman',Times,serif;font-size:20pt;color:#33FF33;z-index:0;}
</style>
<script language="JavaScript1.2">
var message=new Array("Welcome","ゆっくり","ごらんください","d(⌒o⌒)b♪");
var isMSIE=(document.all)?true:false;
var isNS=(document.layers)?true:false;
var isNS6=(!isMSIE && document.getElementById)?true:false;
var layerRef=(isNS)?"document.layers['":(isNS6)?"document.getElementById('":"document.all['";
var styleSwitch=(isNS)?"']":(isNS6)?"').style":"'].style";
var widthSwitch=(isNS)?"'].clip.width":(isNS6)?"').offsetWidth":"'].offsetWidth";
var heightSwitch=(isNS)?"'].clip.height":(isNS6)?"').offsetHeight":"'].offsetHeight";
var xSwitch=(isNS||isNS6)?".left":".pixelLeft";
var ySwitch=(isNS||isNS6)?".top":".pixelTop";
var layerID="layer",sprite=new Array(),timerID;
function shiftTo(obj,x,y){
if(isNS6){obj.left=x+"px";obj.top=y+"px";}else{
if(isNS){obj.moveTo(x,y);}else{obj.pixelLeft=x;obj.pixelTop=y;}
}}
function getVWidth(){return (isNS||isNS6)?window.innerWidth:document.body.clientWidth;}
function getVHeight(){return (isNS||isNS6)?window.innerHeight:document.body.clientHeight;}
function Vector(x,y){this.x=x||0;this.y=y||0;}
function Point(h,v){this.h=h||0;this.v=v||0;}
function Dimension(w,h){this.width=w||0;this.height=h||0;}
function Bound(id){
this.INELASTICITY=0.96;this.MIN_Y_VELOCITY=1;
this.id=id;this.object;
this.windage=0.0;this.gravity=10;
this.vector=new Vector(2.0-Math.random()*4.0,this.MIN_Y_VELOCITY+Math.random()*5);
this.location=new Point();
this.size=new Dimension();
this.move=moveBound;this.pop=popBound;this.isMouseOver=isBoundMouseOver;
eval("this.object="+layerRef+this.id+styleSwitch);
eval("this.size.width="+layerRef+this.id+widthSwitch);
eval("this.size.height="+layerRef+this.id+heightSwitch);
this.location.h=(getVWidth()-this.size.width)/2;
shiftTo(this.object,this.location.h,this.location.v);
this.object.visibility="visible";
}
function moveBound(){
this.location.h+=this.vector.x+this.windage/2.0;
this.location.v+=this.vector.y+this.gravity/2.0;
var caprice=Math.random()*0.01-0.005;
if(this.location.h<=0){
this.location.h=0;this.vector.x=-this.vector.x*this.INELASTICITY+caprice;
}
if(this.location.h+this.size.width>=getVWidth()){
this.location.h=getVWidth()-this.size.width;
this.vector.x=-this.vector.x*this.INELASTICITY+caprice;
}
if(this.location.v<=0){
this.location.v=0;this.vector.y=-this.vector.y*this.INELASTICITY+caprice;
}
if(this.location.v+this.size.height>=getVHeight()){
this.location.v=getVHeight()-this.size.height;
this.vector.x*=this.INELASTICITY;
this.vector.y=-this.vector.y;
}
shiftTo(this.object,this.location.h,this.location.v);
this.vector.x+=this.windage;
this.vector.y+=this.gravity;
}
function popBound(){
this.vector.x=10.0-Math.random()*20.0;
this.vector.y=-Math.random()*30.0-30.0;
}
function isBoundMouseOver(x,y){
if(x>this.location.h&&x<this.location.h+this.size.width
&& y>this.location.v&&y<this.location.v+this.size.height){return true;}
return false;
}
function process(){for(var i=0;i<sprite.length;i++){sprite[i].move();}}
function init(){
for(var i=0;i<message.length;i++){sprite[i]=new Bound(layerID+i);}
if(isNS6){document.addEventListener('mousemove',mouseMoveHandler,true);}else{
if(isNS){document.captureEvents(Event.MOUSEMOVE);}
document.onmousemove=mouseMoveHandler;
}
timerID=setInterval("process()",60);
}
function mouseMoveHandler(e){
var mx=(isNS||isNS6)?e.pageX:document.body.scrollLeft+event.clientX;
var my=(isNS||isNS6)?e.pageY:document.body.scrollTop+event.clientY;
for(var i=0;i<sprite.length;i++){
if(sprite[i].isMouseOver(mx,my)){sprite[i].pop();}
}
}
function cleanup(){clearInterval(timerID);}
function resizeHandler(){location.reload();return false;}
if(isNS){
window.captureEvents(Event.RESIZE);
window.onresize=resizeHandler;
}
window.onload=init;window.onunload=cleanup;
</script>
</head><body bgcolor='#ffffff'>
<script language="JavaScript1.2">
for (var i=0;i<message.length;i++){
document.writeln("<span id='"+layerID+i+"' class='dm"+i+"'>");
document.writeln(message[i]);document.writeln("</span>");
}
</script>
</p>
</body>