WEST MiRa(1,739 Byte)
JavaScript(1,601 Byte)
DHCƒIƒ“ƒ‰ƒCƒ“ƒVƒ‡ƒbƒv

¢£ JavaScript - ¥µ¥ó¥×¥ë½¸(257¼ïÎà) - ¥²¡¼¥à
¡¡¡¡ - ¥¹¥í¥Ã¥È¥²¡¼¥à Ver2

¥¹¥í¥Ã¥È¥²¡¼¥àVer2¤Ç¤¹¡£
¥³¥¤¥ó¤¬Â·¤Ã¤¿¤êÏ¢È֤ˤʤë¤È¡¢¥³¥¤¥ó¤ò³ÍÆÀ¤Ç¤­¤Þ¤¹¡£
¥ê¥»¥Ã¥È¤ò²¡¤¹¤È½é´ü¾õÂÖ¤ËÊÖ¤ê¤Þ¤¹¡£
¥³¥¤¥ó¤¬¥¼¥í¤Ë¤Ê¤ë¤È¡¢¤½¤Î»ÝÅÁ¤¨¤ë¥À¥¤¥¢¥í¥°¤¬½Ð¤Þ¤¹¡£

¡¦¥µ¥ó¥×¥ë¤ò¸«¤ë
¡¦¥½¡¼¥¹¤òÊݸ¤¹¤ë
¡Ê±¦¥¯¥ê¥Ã¥¯¢ª¡ÖÂоݤò¥Õ¥¡¥¤¥ë¤ËÊݸ¡×or¡Ö¥ê¥ó¥¯¤ò̾Á°¤òÉÕ¤±¤ÆÊݸ¡×¤·¤Æ²¼¤µ¤¤¡£¡Ë
¡¦¥½¡¼¥¹¤ò¸«¤ë
¡¦²òÀâ¤ò¸«¤ë





[ ¥½¡¼¥¹ ]

<html>
<head>
<script language="JavaScript">
<!--//Copyright (C) WEST MiRa http://www.west-mira.jp

	//¥¹¥í¥Ã¥È¤¬²ó¤ëÁᤵ¤ò»ØÄꤹ¤ë
	hayasa=30;

	//½é´ü¾õÂ֤Υ³¥¤¥ó¤ÎËç¿ô¤ò»ØÄꤹ¤ë
	coin=50;

	//¥³¥¤¥ó¤ò»È¤¤²Ì¤¿¤·¤¿»þ¤Î¥á¥Ã¥»¡¼¥¸¤ò»ØÄꤹ¤ë
	mes='µ®Êý¤Ï¥³¥¤¥ó¤ò»È¤¤²Ì¤¿¤·¤Æ¤·¤Þ¤¤¤Þ¤·¤¿¡£';

	//¤¾¤íÌÜ»þ¤Î¾Þ¶â¤ÎÇÜΨ¤ò»ØÄꤹ¤ë
	//2¤À¤Ã¤¿¤é·¤Ã¤¿¿ô¤Î2ÇÜ¡¢3¤À¤Ã¤¿¤é·¤Ã¤¿¿ô¤Î3ÇÜ
	rate1=2;

	//Ï¢ÈÖ»þ¤Î¾Þ¶â¤ÎÇÜΨ¤ò»ØÄꤹ¤ë
	//2¤À¤Ã¤¿¤é·¤Ã¤¿¿ô¤Î2ÇÜ¡¢3¤À¤Ã¤¿¤é·¤Ã¤¿¿ô¤Î3ÇÜ
	rate2=3;


	kekka=coin;
	nums=new Array('','','');
	timers=0;
	e1=0;e2=0;e3=0;
	function hajime()
		{
		kekka=coin;
		document.form1.kekka.value=coin;
		document.form1.text1.value=" ";
		document.form1.text2.value=" ";
		document.form1.text3.value=" ";
		}

	function srot()
		{
		if(e1 < 1000)
			{
			nums[0]=Math.floor(Math.random()*46);
			for(i1=0,j1=9,k1=j1; i1 < 10; i1++)
				{
				if(nums[0] < k1 || nums[0] == 45)
					{
					if(i1+1 == 10)nums[0]=0;
					else nums[0]=i1+1;
					break;
					}
				j1--;
				k1+=j1;
				}
			document.form1.text1.value=nums[0];
			e1++;
			clearTimeout(timers);
			timers=setTimeout('srot()',hayasa);
			}

		if(e2 < 1000)
			{
			nums[1]=Math.floor(Math.random()*46);
			for(i2=0,j2=9,k2=j2; i2 < 10; i2++)
				{
				if(nums[1] < k2 || nums[1] == 45)
					{
					if(i2+1 == 10)nums[1]=0;
					else nums[1]=i2+1;
					break;
					}
				j2--;
				k2+=j2;
				}
			document.form1.text2.value=nums[1];
			e2++;
			clearTimeout(timers);
			timers=setTimeout('srot()',hayasa);
			}

		if(e3 < 1000)
			{
			nums[2]=Math.floor(Math.random()*46);
			for(i3=0,j3=9,k3=j3; i3 < 10; i3++)
				{
				if(nums[2] < k3 || nums[2] == 45)
					{
					if(i3+1 == 10)nums[2]=0;
					else nums[2]=i3+1;
					break;
					}
				j3--;
				k3+=j3;
				}
			document.form1.text3.value=nums[2];
			e3++;
			clearTimeout(timers);
			timers=setTimeout('srot()',hayasa);
			}

		if(e1 >= 1000)stop();
		else if(e2 >= 1000)stop();
		else if(e3 >= 1000)stop();
		}

	function stop()
		{
		document.form1.text1.value=nums[0];
		document.form1.text2.value=nums[1];
		document.form1.text3.value=nums[2];
		if(e1 >= 1000 && e2 >= 1000 && e3 >= 1000)
			{
			if(nums[0] == nums[1] && nums[1] == nums[2])
				{
				if(nums[0] == 0)kekka+=10*rate1;
				else kekka+=nums[0]*rate1;
				}
			else if(nums[0] == nums[1]+1 && nums[1] == nums[2]+1)
				{
				if(nums[0] == 0)kekka+=10*rate2;
				else kekka+=nums[0]*rate2;
				}
			else if(nums[2] == nums[1]+1 && nums[1] == nums[0]+1)
				{
				if(nums[0] == 0)kekka+=10*rate2;
				else kekka+=nums[0]*rate2;
				}
			document.form1.kekka.value=kekka;
			}
		}

	function starts(e)
		{
		e=eval(e);
		if(e == 0)
			{
			if(kekka<1)
				{
				alert(mes);
				document.form1.kekka.value=0;
				}
			else 
				{
				kekka--;
				document.form1.kekka.value=kekka;
				e1=0;e2=0;e3=0;
				srot();
				}
			}
		else if(e == 1)e1=1000;
		else if(e == 2)e2=1000;
		else if(e == 3)e3=1000;
		}

//-->
</script>
</head>
<body onLoad="hajime();">

<form name="form1">
<table border="1" align="center"><tr>
<td align="center"><input type="text" size="1" name="text1"></td>
<td align="center"><input type="text" size="1" name="text2"></td>
<td align="center"><input type="text" size="1" name="text3"></td>
</tr>

<tr>
<td align="center"><input type="button" value="Stop!" onClick="starts(1);"></td>
<td align="center"><input type="button" value="Stop!" onClick="starts(2);"></td>
<td align="center"><input type="button" value="Stop!" onClick="starts(3);"></td>

<tr>
<td colspan="3" align="center">
<input type="button" value="Start!" onClick="starts(0);">
<input type="button" value="Reset" onClick="hajime();">
</td>
</tr>

<tr>
<td colspan="3">¼ê»ý¤Á¥³¥¤¥ó¤Ï¤¢¤È<input type="text" size="3" name="kekka">Ëç¡£</td>
</tr>

</table>
</form>

</body>
</html>


[ ²òÀâ ]

½é´ü¥³¥¤¥ó¤ÎËç¿ô¤äÇÜΨ¤òÊѹ¹¤·¤¿¤¤Êý¤Ï¡¢¥½¡¼¥¹Æâ¤ÎÃí¼á¤ò»²¹Í¤Ë¿§¡¹¤È»ØÄꤷ¤Æ¤ß¤Æ²¼¤µ¤¤¡£


¥Ð¥Ê¡¼¡¢¥ê¥ó¥¯¤Ë¤Ä¤¤¤Æ  ,   ÍøÍѵ¬Ìó  ,   ¥Ø¥ë¥×

Copyright (C) 1998-2007 WEST MiRa. All rights reserved.