
function init(){
 MSG.css=MSG.style||MSG
 MSG.start=parseInt(document.layers?SCR.document.height:SCR.offsetHeight)
 MSG.end=-parseInt(document.layres?MSG.document.height:MSG.offsetHeight)
 MSG.css.top=MSG.start
 MSG.step=-2
 MSG.oldstep=-2
 MSG.timeout=setInterval(go,40)
}

function go(){
 var tmp=(parseInt(MSG.css.top)||0)+(document.all?MSG.step:MSG.step*2)
 if((MSG.step<0)&&(tmp<MSG.end))tmp=MSG.start
 else if((MSG.step>0)&&(tmp>MSG.start))tmp=MSG.end
 MSG.css.top=tmp
 if(MSG.step!=MSG.way){
  if(MSG.step<0) tmp=0
  else if(MSG.step==0) tmp=1
  else tmp=2
  }
}

function setscroll(e,t){
 MSG.step=parseInt(t)
}

function restore(){
 MSG.step=MSG.oldstep
}
 
function keepscroll(e,t){
 if(!e)e=event
 MSG.oldstep=MSG.step=parseInt(t)
 e.returnValue=false 
 return false
}