📄 1.htm
字号:
</v:line>
<v:line from="305,295" to="305,290" style="z-index: 3;" strokeweight="1pt">
</v:line>
<v:line from="305,295" to="310,295" style="z-index: 3;" strokeweight="1pt">
</v:line>
<v:line from="295,305" to="295,310" style="z-index: 3;" strokeweight="1pt">
</v:line>
<v:line from="295,305" to="290,305" style="z-index: 3;" strokeweight="1pt">
</v:line>
<v:line from="295,295" to="295,290" style="z-index: 3;" strokeweight="1pt">
</v:line>
<v:line from="295,295" to="290,295" style="z-index: 3;" strokeweight="1pt">
</v:line>
<v:line from="395,155" to="395,160" style="z-index: 3;" strokeweight="1pt">
</v:line>
<v:line from="395,155" to="390,155" style="z-index: 3;" strokeweight="1pt">
</v:line>
<v:line from="395,145" to="395,140" style="z-index: 3;" strokeweight="1pt">
</v:line>
<v:line from="395,145" to="390,145" style="z-index: 3;" strokeweight="1pt">
</v:line>
<v:line from="395,305" to="395,310" style="z-index: 3;" strokeweight="1pt">
</v:line>
<v:line from="395,305" to="390,305" style="z-index: 3;" strokeweight="1pt">
</v:line>
<v:line from="395,295" to="395,290" style="z-index: 3;" strokeweight="1pt">
</v:line>
<v:line from="395,295" to="390,295" style="z-index: 3;" strokeweight="1pt">
</v:line>
<v:line from="5,155" to="5,160" style="z-index: 3;" strokeweight="1pt">
</v:line>
<v:line from="5,155" to="10,155" style="z-index: 3;" strokeweight="1pt">
</v:line>
<v:line from="5,145" to="5,140" style="z-index: 3;" strokeweight="1pt">
</v:line>
<v:line from="5,145" to="10,145" style="z-index: 3;" strokeweight="1pt">
</v:line>
<v:line from="5,305" to="5,310" style="z-index: 3;" strokeweight="1pt">
</v:line>
<v:line from="5,305" to="10,305" style="z-index: 3;" strokeweight="1pt">
</v:line>
<v:line from="5,295" to="5,290" style="z-index: 3;" strokeweight="1pt">
</v:line>
<v:line from="5,295" to="10,295" style="z-index: 3;" strokeweight="1pt">
</v:line>
<v:oval id="q1" style="left: -20; top: -20; width: 40; height: 40; z-index: 9; cursor: hand;"
fillcolor="gray" strokeweight="1" onclick="sel(this);" title="q1">
<v:shadow on="Ture" type="single" color="#8b4513" offset="3px,3px" />
<v:textbox inset="2pt,2pt,1pt,1pt" style="z-index: 4; font-size=24; font-weight: bold;
filter: glow(color=#ffffff,strength=1);">车</v:textbox>
</v:oval>
<v:oval id="q2" style="left: 30; top: -20; width: 40; height: 40; z-index: 9; cursor: hand;"
fillcolor="gray" strokeweight="1" onclick="sel(this);" title="q2">
<v:shadow on="Ture" type="single" color="#8b4513" offset="3px,3px" />
<v:textbox inset="2pt,2pt,1pt,1pt" style="z-index: 4; font-size=24; font-weight: bold;
filter: glow(color=#ffffff,strength=1);">马</v:textbox>
</v:oval>
<v:oval id="q3" style="left: 80; top: -20; width: 40; height: 40; z-index: 9; cursor: hand;"
fillcolor="gray" strokeweight="1" onclick="sel(this);" title="q3">
<v:shadow on="Ture" type="single" color="#8b4513" offset="3px,3px" />
<v:textbox inset="2pt,2pt,1pt,1pt" style="z-index: 4; font-size=24; font-weight: bold;
filter: glow(color=#ffffff,strength=1);">象</v:textbox>
</v:oval>
<v:oval id="q4" style="left: 130; top: -20; width: 40; height: 40; z-index: 9; cursor: hand;"
fillcolor="gray" strokeweight="1" onclick="sel(this);" title="q4">
<v:shadow on="Ture" type="single" color="#8b4513" offset="3px,3px" />
<v:textbox inset="2pt,2pt,1pt,1pt" style="z-index: 4; font-size=24; font-weight: bold;
filter: glow(color=#ffffff,strength=1);">士</v:textbox>
</v:oval>
<v:oval id="q5" style="left: 180; top: -20; width: 40; height: 40; z-index: 9; cursor: hand;"
fillcolor="gray" strokeweight="1" onclick="sel(this);" title="q5">
<v:shadow on="Ture" type="single" color="#8b4513" offset="3px,3px" />
<v:textbox inset="2pt,2pt,1pt,1pt" style="z-index: 4; font-size=24; font-weight: bold;
filter: glow(color=#ffffff,strength=1);">将</v:textbox>
</v:oval>
<v:oval id="q6" style="left: 230; top: -20; width: 40; height: 40; z-index: 9; cursor: hand;"
fillcolor="gray" strokeweight="1" onclick="sel(this);" title="q6">
<v:shadow on="Ture" type="single" color="#8b4513" offset="3px,3px" />
<v:textbox inset="2pt,2pt,1pt,1pt" style="z-index: 4; font-size=24; font-weight: bold;
filter: glow(color=#ffffff,strength=1);">士</v:textbox>
</v:oval>
<v:oval id="q7" style="left: 280; top: -20; width: 40; height: 40; z-index: 9; cursor: hand;"
fillcolor="gray" strokeweight="1" onclick="sel(this);" title="q7">
<v:shadow on="Ture" type="single" color="#8b4513" offset="3px,3px" />
<v:textbox inset="2pt,2pt,1pt,1pt" style="z-index: 4; font-size=24; font-weight: bold;
filter: glow(color=#ffffff,strength=1);">象</v:textbox>
</v:oval>
<v:oval id="q8" style="left: 330; top: -20; width: 40; height: 40; z-index: 9; cursor: hand;"
fillcolor="gray" strokeweight="1" onclick="sel(this);" title="q8">
<v:shadow on="Ture" type="single" color="#8b4513" offset="3px,3px" />
<v:textbox inset="2pt,2pt,1pt,1pt" style="z-index: 4; font-size=24; font-weight: bold;
filter: glow(color=#ffffff,strength=1);">马</v:textbox>
</v:oval>
<v:oval id="q9" style="left: 380; top: -20; width: 40; height: 40; z-index: 9; cursor: hand;"
fillcolor="gray" strokeweight="1" onclick="sel(this);" title="q9">
<v:shadow on="Ture" type="single" color="#8b4513" offset="3px,3px" />
<v:textbox inset="2pt,2pt,1pt,1pt" style="z-index: 4; font-size=24; font-weight: bold;
filter: glow(color=#ffffff,strength=1);">车</v:textbox>
</v:oval>
<v:oval id="q10" style="left: 30; top: 80; width: 40; height: 40; z-index: 9; cursor: hand;"
fillcolor="gray" strokeweight="1" onclick="sel(this);" title="q10">
<v:shadow on="Ture" type="single" color="#8b4513" offset="3px,3px" />
<v:textbox inset="2pt,2pt,1pt,1pt" style="z-index: 4; font-size=24; font-weight: bold;
filter: glow(color=#ffffff,strength=1);">炮</v:textbox>
</v:oval>
<v:oval id="q11" style="left: 330; top: 80; width: 40; height: 40; z-index: 9; cursor: hand;"
fillcolor="gray" strokeweight="1" onclick="sel(this);" title="q11">
<v:shadow on="Ture" type="single" color="#8b4513" offset="3px,3px" />
<v:textbox inset="2pt,2pt,1pt,1pt" style="z-index: 4; font-size=24; font-weight: bold;
filter: glow(color=#ffffff,strength=1);">炮</v:textbox>
</v:oval>
<v:oval id="q12" style="left: -20; top: 130; width: 40; height: 40; z-index: 9; cursor: hand;"
fillcolor="gray" strokeweight="1" onclick="sel(this);" title="q12">
<v:shadow on="Ture" type="single" color="#8b4513" offset="3px,3px" />
<v:textbox inset="2pt,2pt,1pt,1pt" style="z-index: 4; font-size=24; font-weight: bold;
filter: glow(color=#ffffff,strength=1);">卒</v:textbox>
</v:oval>
<v:oval id="q13" style="left: 80; top: 130; width: 40; height: 40; z-index: 9; cursor: hand;"
fillcolor="gray" strokeweight="1" onclick="sel(this);" title="q13">
<v:shadow on="Ture" type="single" color="#8b4513" offset="3px,3px" />
<v:textbox inset="2pt,2pt,1pt,1pt" style="z-index: 4; font-size=24; font-weight: bold;
filter: glow(color=#ffffff,strength=1);">卒</v:textbox>
</v:oval>
<v:oval id="q14" style="left: 180; top: 130; width: 40; height: 40; z-index: 9; cursor: hand;"
fillcolor="gray" strokeweight="1" onclick="sel(this);" title="q14">
<v:shadow on="Ture" type="single" color="#8b4513" offset="3px,3px" />
<v:textbox inset="2pt,2pt,1pt,1pt" style="z-index: 4; font-size=24; font-weight: bold;
filter: glow(color=#ffffff,strength=1);">卒</v:textbox>
</v:oval>
<v:oval id="q15" style="left: 280; top: 130; width: 40; height: 40; z-index: 9; cursor: hand;"
fillcolor="gray" strokeweight="1" onclick="sel(this);" title="q15">
<v:shadow on="Ture" type="single" color="#8b4513" offset="3px,3px" />
<v:textbox inset="2pt,2pt,1pt,1pt" style="z-index: 4; font-size=24; font-weight: bold;
filter: glow(color=#ffffff,strength=1);">卒</v:textbox>
</v:oval>
<v:oval id="q16" style="left: 380; top: 130; width: 40; height: 40; z-index: 9; cursor: hand;"
fillcolor="gray" strokeweight="1" onclick="sel(this);" title="q16">
<v:shadow on="Ture" type="single" color="#8b4513" offset="3px,3px" />
<v:textbox inset="2pt,2pt,1pt,1pt" style="z-index: 4; font-size=24; font-weight: bold;
filter: glow(color=#ffffff,strength=1);">卒</v:textbox>
</v:oval>
<v:oval id="q17" style="left: -20; top: 280; width: 40; height: 40; z-index: 9; cursor: hand;"
fillcolor="red" strokeweight="1" onclick="sel(this);" title="q17">
<v:shadow on="Ture" type="single" color="#8b4513" offset="3px,3px" />
<v:textbox inset="2pt,2pt,1pt,1pt" style="z-index: 4; font-size=24; font-weight: bold;
filter: glow(color=#ffffff,strength=1);">兵</v:textbox>
</v:oval>
<v:oval id="q18" style="left: 80; top: 280; width: 40; height: 40; z-index: 9; cursor: hand;"
fillcolor="red" strokeweight="1" onclick="sel(this);" title="q18">
<v:shadow on="Ture" type="single" color="#8b4513" offset="3px,3px" />
<v:textbox inset="2pt,2pt,1pt,1pt" style="z-index: 4; font-size=24; font-weight: bold;
filter: glow(color=#ffffff,strength=1);">兵</v:textbox>
</v:oval>
<v:oval id="q19" style="left: 180; top: 280; width: 40; height: 40; z-index: 9; cursor: hand;"
fillcolor="red" strokeweight="1" onclick="sel(this);" title="q19">
<v:shadow on="Ture" type="single" color="#8b4513" offset="3px,3px" />
<v:textbox inset="2pt,2pt,1pt,1pt" style="z-index: 4; font-size=24; font-weight: bold;
filter: glow(color=#ffffff,strength=1);">兵</v:textbox>
</v:oval>
<v:oval id="q20" style="left: 280; top: 280; width: 40; height: 40; z-index: 9; cursor: hand;"
fillcolor="red" strokeweight="1" onclick="sel(this);" title="q20">
<v:shadow on="Ture" type="single" color="#8b4513" offset="3px,3px" />
<v:textbox inset="2pt,2pt,1pt,1pt" style="z-index: 4; font-size=24; font-weight: bold;
filter: glow(color=#ffffff,strength=1);">兵</v:textbox>
</v:oval>
<v:oval id="q21" style="left: 380; top: 280; width: 40; height: 40; z-index: 9; cursor: hand;"
fillcolor="red" strokeweight="1" onclick="sel(this);" title="q21">
<v:shadow on="Ture" type="single" color="#8b4513" offset="3px,3px" />
<v:textbox inset="2pt,2pt,1pt,1pt" style="z-index: 4; font-size=24; font-weight: bold;
filter: glow(color=#ffffff,strength=1);">兵</v:textbox>
</v:oval>
<v:oval id="q22" style="left: 30; top: 330; width: 40; height: 40; z-index: 9; cursor: hand;"
fillcolor="red" strokeweight="1" onclick="sel(this);" title="q22">
<v:shadow on="Ture" type="single" color="#8b4513" offset="3px,3px" />
<v:textbox inset="2pt,2pt,1pt,1pt" style="z-index: 4; font-size=24; font-weight: bold;
filter: glow(color=#ffffff,strength=1);">炮</v:textbox>
</v:oval>
<v:oval id="q23" style="left: 330; top: 330; width: 40; height: 40; z-index: 9; cursor: hand;"
fillcolor="red" strokeweight="1" onclick="sel(this);" title="q23">
<v:shadow on="Ture" type="single" color="#8b4513" offset="3px,3px" />
<v:textbox inset="2pt,2pt,1pt,1pt" style="z-index: 4; font-size=24; font-weight: bold;
filter: glow(color=#ffffff,strength=1);">炮</v:textbox>
</v:oval>
<v:oval id="q24" style="left: -20; top: 430; width: 40; height: 40; z-index: 9; cursor: hand;"
fillcolor="red" strokeweight="1" onclick="sel(this);" title="q24">
<v:shadow on="Ture" type="single" color="#8b4513" offset="3px,3px" />
<v:textbox inset="2pt,2pt,1pt,1pt" style="z-index: 4; font-size=24; font-weight: bold;
filter: glow(color=#ffffff,strength=1);">车</v:textbox>
</v:oval>
<v:oval id="q25" style="left: 30; top: 430; width: 40; height: 40; z-index: 9; cursor: hand;"
fillcolor="red" strokeweight="1" onclick="sel(this);" title="q25">
<v:shadow on="Ture" type="single" color="#8b4513" offset="3px,3px" />
<v:textbox inset="2pt,2pt,1pt,1pt" style="z-index: 4; font-size=24; font-weight: bold;
filter: glow(color=#ffffff,strength=1);">马</v:textbox>
</v:oval>
<v:oval id="q26" style="left: 80; top: 430; width: 40; height: 40; z-index: 9; cursor: hand;"
fillcolor="red" strokeweight="1" onclick="sel(this);" title="q26">
<v:shadow on="Ture" type="single" color="#8b4513" offset="3px,3px" />
<v:textbox inset="2pt,2pt,1pt,1pt" style="z-index: 4; font-size=24; font-weight: bold;
filter: glow(color=#ffffff,strength=1);">相</v:textbox>
</v:oval>
<v:oval id="q27" style="left: 130; top: 430; width: 40; height: 40; z-index: 9; cursor: hand;"
fillcolor="red" strokeweight="1" onclick="sel(this);" title="q27">
<v:shadow on="Ture" type="single" color="#8b4513" offset="3px,3px" />
<v:textbox inset="2pt,2pt,1pt,1pt" style="z-index: 4; font-size=24; font-weight: bold;
filter: glow(color=#ffffff,strength=1);">仕</v:textbox>
</v:oval>
<v:oval id="q28" style="left: 180; top: 430; width: 40; height: 40; z-index: 9; cursor: hand;"
fillcolor="red" strokeweight="1" onclick="sel(this);" title="q28">
<v:shadow on="Ture" type="single" color="#8b4513" offset="3px,3px" />
<v:textbox inset="2pt,2pt,1pt,1pt" style="z-index: 4; font-size=24; font-weight: bold;
filter: glow(color=#ffffff,strength=1);">帅</v:textbox>
</v:oval>
<v:oval id="q29" style="left: 230; top: 430; width: 40; height: 40; z-index: 9; cursor: hand;"
fillcolor="red" strokeweight="1" onclick="sel(this);" title="q29">
<v:shadow on="Ture" type="single" color="#8b4513" offset="3px,3px" />
<v:textbox inset="2pt,2pt,1pt,1pt" style="z-index: 4; font-size=24; font-weight: bold;
filter: glow(color=#ffffff,strength=1);">仕</v:textbox>
</v:oval>
<v:oval id="q30" style="left: 280; top: 430; width: 40; height: 40; z-index: 9; cursor: hand;"
fillcolor="red" strokeweight="1" onclick="sel(this);" title="q30">
<v:shadow on="Ture" type="single" color="#8b4513" offset="3px,3px" />
<v:textbox inset="2pt,2pt,1pt,1pt" style="z-index: 4; font-size=24; font-weight: bold;
filter: glow(color=#ffffff,strength=1);">相</v:textbox>
</v:oval>
<v:oval id="q31" style="left: 330; top: 430; width: 40; height: 40; z-index: 9; cursor: hand;"
fillcolor="red" strokeweight="1" onclick="sel(this);" title="q31">
<v:shadow on="Ture" type="single" color="#8b4513" offset="3px,3px" />
<v:textbox inset="2pt,2pt,1pt,1pt" style="z-index: 4; font-size=24; font-weight: bold;
filter: glow(color=#ffffff,strength=1);">马</v:textbox>
</v:oval>
<v:oval id="q32" style="left: 380; top: 430; width: 40; height: 40; z-index: 9; cursor: hand;"
fillcolor="red" strokeweight="1" onclick="sel(this);" title="q32">
<v:shadow on="Ture" type="single" color="#8b4513" offset="3px,3px" />
<v:textbox inset="2pt,2pt,1pt,1pt" style="z-index: 4; font-size=24; font-weight: bold;
filter: glow(color=#ffffff,strength=1);">车</v:textbox>
</v:oval>
</v:group>
<div id="ppp" style="position:absolute;top:50;left:700;font-size:12px;">
现在该你红棋走了,请拖动棋子,本程序只支持IE,如果IE不能正常显示,请设置为信任站点</div>
<div style="position:absolute;top:100;left:700;font-size:12px;">
<button onclick="Retract();" id="RetractChess">悔棋</button>
<button onclick="window.location.reload();">重来</button>
<button onclick="Change();">变着</button>
<button onclick="bug.click();">报告Bug</button><A id="bug" href="mailto:wolf.pan@kuqu.com?subject=I_find_a_bug!&body=I_find_a_bug:"></A>
</div>
<textarea id="qqq" style="position:absolute;top:150;left:700;font-size:12px;width:200px;height:350px;"></textarea>
<script language="javascript" type="text/javascript">
//p.StandardInput.WriteLine("position fen 4C4/4a4/b2ank2b/9/9/1RNR1crC1/3r1p3/3cKA3/4A4/4n4 w - - 0 1");
//move(30,80,180,80);
function msg(x)
{
//alert(unescape(x));
}
//bestmove d4f4 ponder g4f4
//以下是棋子动画部分
function bestmove(str)
{
window.status=unescape( str);
if(str.length==4)
{
window.clearTimeout(timeOut);
str=str.toLowerCase();
var x1=(str.charCodeAt(0)-97)*50-20;
var y1=430-parseInt(str.substr(1,1)) * 50;
var x2=(str.charCodeAt(2)-97)*50-20;
var y2=430-parseInt(str.substr(3,1))* 50;
//alert(" " + x1 + "," +y1 + "," + x2 + "," +y2 +" " );
move(x1,y1,x2,y2)
}
else
{
Timming();
// ppp.innerHTML=(unescape( str).replace(/\n/ig,"<br/>"));
}
RetractChess.disabled=false;
}
var timeOut=0;
function move(x1,y1,x2,y2)
{
var moveChess=document.getElementById( getQ_xy(x1,y1) );
myColor= "gray" ;
enemyColor="red";
//setSel(moveChess,x1,y1);
//setTarget(x2,y2);//走过去
var deadId=getQ_xy(x2,y2);
//纪录棋谱;
getMove(moveChess,x1,y1,x2,y2);
if( deadId !=""){
eatNumRed+=1;
var deadChess=document.getElementById(deadId);
deadChess.style.top=(eatNumRed -1)* 50;
deadChess.style.left=550;
if(isKing(deadId)){
if(window.confirm("你输了!重来吗?"))
{
window.location.reload();
}
}
}
//document.getElementById(deadID).style.display="none";
moveChess.style.top=y2;
moveChess.style.left=x2;
if(moveChess.strokeWeight==1){
moveChess.style.zIndex=5;
moveChess.strokeWeight=2;
moveChess.strokeColor="Navy" ;
}
myColor= "red" ;
enemyColor="gray";
whosTurn="w";
selectNull();
ppp.innerHTML="现在该你红棋走了,请拖动棋子";
}
//以下是拖动棋子部分
var isDrag=false;
var allChess=document.getElementsByTagName("OVAL");
for(i=0;i<allChess.length;i++)
{
//点下
if(allChess[i].fillColor == myColor ) {
allChess[i].onmousedown=function MouseDown(){
if(event.button==2){return false ;}
if(whosTurn!="w"){return false;}
chessObj=this;
sel(this ) ;
chessObj.setCapture();
chessObj.l=event.x-chessObj.style.pixelLeft;
chessObj.t=event.y-chessObj.style.pixelTop;
}
//移动
allChess[i].onmousemove=function MouseMove(){
if(whosTurn!="w"){return false;}
if(chessObj!=null){
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -