palette_n4.htm

戻る

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML LANG="ja">

<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html;charset=Shift_JIS">
<TITLE>パレット アニメーションもどき</TITLE>
</HEAD>

<BODY BGCOLOR="#CCFFFF">
<BR><BR><BR>
<CENTER>
<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0><TR>
<TD><ILAYER NAME="back1" BGCOLOR="#0099FF">
<IMG SRC="images/palette1.gif" WIDTH=178 HEIGHT=120></ILAYER></TD>
<TD><ILAYER NAME="back2" BGCOLOR="#FFCC00">
<IMG SRC="images/palette2.gif" WIDTH=229 HEIGHT=120></ILAYER></TD>
</TR></TABLE>
</CENTER>

<SCRIPT LANGUAGE="JavaScript1.2" TYPE="text/javascript">
<!--

function timer() {
  if(ud1) {
    if(--g1 == 0x99)
      ud1 = 0;
  }
  else {
    if(++g1 == 0xff)
      ud1 = 1;
  }
  document.back1.document.bgColor = (g1 << 8) | (0x198 - g1);

  if(ud2) {
    if(--g2 == 0xcc)
      ud2 = 0;
  }
  else {
    if(++g2 == 0xff)
      ud2 = 1;
  }
  document.back2.document.bgColor = ((0x1cb - g2) << 16) | (g2 << 8);
}

  g1 = 0x99;
  g2 = 0xcc;
  ud1 = ud2 = 0;
  setInterval(timer, 50);

//-->
</SCRIPT>

</BODY>

</HTML>