Commit ac9a5a39 authored by 刘家荣's avatar 刘家荣 💬
Browse files

bugfix(存档 & 窗口切换)

parent f5f82127
Loading
Loading
Loading
Loading
+6 −2
Original line number Diff line number Diff line
@@ -4,7 +4,11 @@
    <CLASSES>
      <root url="jar://$MAVEN_REPOSITORY$/com/alibaba/fastjson2/fastjson2/2.0.17/fastjson2-2.0.17.jar!/" />
    </CLASSES>
    <JAVADOC />
    <SOURCES />
    <JAVADOC>
      <root url="jar://$MAVEN_REPOSITORY$/com/alibaba/fastjson2/fastjson2/2.0.17/fastjson2-2.0.17-javadoc.jar!/" />
    </JAVADOC>
    <SOURCES>
      <root url="jar://$MAVEN_REPOSITORY$/com/alibaba/fastjson2/fastjson2/2.0.17/fastjson2-2.0.17-sources.jar!/" />
    </SOURCES>
  </library>
</component>
 No newline at end of file
+1 −1
Original line number Diff line number Diff line
{"Game":{"chessboard":{"chessList":[{"chessColor":0,"chessType":0,"location":{"plate":2,"x":3,"y":0},"reversal":false,"selected":false,"id":0},{"chessColor":0,"chessType":0,"location":{"plate":2,"x":3,"y":4},"reversal":false,"selected":false,"id":1},{"chessColor":0,"chessType":1,"location":{"plate":2,"x":1,"y":5},"reversal":false,"selected":false,"id":2},{"chessColor":0,"chessType":2,"location":{"plate":2,"x":2,"y":6},"reversal":false,"selected":false,"id":3},{"chessColor":0,"chessType":2,"location":{"plate":2,"x":1,"y":1},"reversal":false,"selected":false,"id":4},{"chessColor":0,"chessType":3,"location":{"plate":2,"x":3,"y":6},"reversal":false,"selected":false,"id":5},{"chessColor":0,"chessType":3,"location":{"plate":2,"x":2,"y":2},"reversal":false,"selected":false,"id":6},{"chessColor":0,"chessType":4,"location":{"plate":2,"x":0,"y":3},"reversal":false,"selected":false,"id":7},{"chessColor":0,"chessType":4,"location":{"plate":2,"x":2,"y":7},"reversal":false,"selected":false,"id":8},{"chessColor":0,"chessType":5,"location":{"plate":2,"x":1,"y":2},"reversal":false,"selected":false,"id":9},{"chessColor":0,"chessType":5,"location":{"plate":2,"x":0,"y":1},"reversal":false,"selected":false,"id":10},{"chessColor":0,"chessType":6,"location":{"plate":2,"x":3,"y":1},"reversal":false,"selected":false,"id":11},{"chessColor":0,"chessType":6,"location":{"plate":2,"x":1,"y":7},"reversal":false,"selected":false,"id":12},{"chessColor":0,"chessType":6,"location":{"plate":2,"x":1,"y":6},"reversal":false,"selected":false,"id":13},{"chessColor":0,"chessType":6,"location":{"plate":2,"x":2,"y":0},"reversal":false,"selected":false,"id":14},{"chessColor":0,"chessType":6,"location":{"plate":2,"x":0,"y":4},"reversal":false,"selected":false,"id":15},{"chessColor":1,"chessType":0,"location":{"plate":2,"x":2,"y":1},"reversal":false,"selected":false,"id":16},{"chessColor":1,"chessType":0,"location":{"plate":2,"x":1,"y":3},"reversal":false,"selected":false,"id":17},{"chessColor":1,"chessType":1,"location":{"plate":2,"x":0,"y":0},"reversal":false,"selected":false,"id":18},{"chessColor":1,"chessType":2,"location":{"plate":2,"x":2,"y":3},"reversal":false,"selected":false,"id":19},{"chessColor":1,"chessType":2,"location":{"plate":2,"x":0,"y":5},"reversal":false,"selected":false,"id":20},{"chessColor":1,"chessType":3,"location":{"plate":2,"x":0,"y":7},"reversal":false,"selected":false,"id":21},{"chessColor":1,"chessType":3,"location":{"plate":2,"x":3,"y":5},"reversal":false,"selected":false,"id":22},{"chessColor":1,"chessType":4,"location":{"plate":2,"x":3,"y":7},"reversal":false,"selected":false,"id":23},{"chessColor":1,"chessType":4,"location":{"plate":2,"x":0,"y":2},"reversal":false,"selected":false,"id":24},{"chessColor":1,"chessType":5,"location":{"plate":2,"x":3,"y":3},"reversal":false,"selected":false,"id":25},{"chessColor":1,"chessType":5,"location":{"plate":2,"x":1,"y":0},"reversal":false,"selected":false,"id":26},{"chessColor":1,"chessType":6,"location":{"plate":2,"x":2,"y":5},"reversal":false,"selected":false,"id":27},{"chessColor":1,"chessType":6,"location":{"plate":2,"x":2,"y":4},"reversal":false,"selected":false,"id":28},{"chessColor":1,"chessType":6,"location":{"plate":2,"x":0,"y":6},"reversal":false,"selected":false,"id":29},{"chessColor":1,"chessType":6,"location":{"plate":2,"x":3,"y":2},"reversal":false,"selected":false,"id":30},{"chessColor":1,"chessType":6,"location":{"plate":2,"x":1,"y":4},"reversal":true,"selected":false,"id":31}],"idGrid":[[18,26,14,0],[10,4,16,11],[24,9,6,30],[7,17,19,25],[15,31,28,1],[20,2,27,22],[29,13,3,5],[21,12,8,23]],"sideStacks":[{"chessColor":0},{"chessColor":1}],"squareList":[{"id":32,"location":{"plate":0,"x":0,"y":0}},{"id":33,"location":{"plate":0,"x":1,"y":0}},{"id":34,"location":{"plate":0,"x":2,"y":0}},{"id":35,"location":{"plate":0,"x":3,"y":0}},{"id":36,"location":{"plate":0,"x":4,"y":0}},{"id":37,"location":{"plate":0,"x":0,"y":1}},{"id":38,"location":{"plate":0,"x":1,"y":1}},{"id":39,"location":{"plate":0,"x":2,"y":1}},{"id":40,"location":{"plate":0,"x":3,"y":1}},{"id":41,"location":{"plate":0,"x":4,"y":1}},{"id":42,"location":{"plate":0,"x":0,"y":2}},{"id":43,"location":{"plate":0,"x":1,"y":2}},{"id":44,"location":{"plate":0,"x":2,"y":2}},{"id":45,"location":{"plate":0,"x":3,"y":2}},{"id":46,"location":{"plate":0,"x":4,"y":2}},{"id":47,"location":{"plate":0,"x":0,"y":3}},{"id":48,"location":{"plate":0,"x":1,"y":3}},{"id":49,"location":{"plate":0,"x":2,"y":3}},{"id":50,"location":{"plate":0,"x":3,"y":3}},{"id":51,"location":{"plate":0,"x":4,"y":3}},{"id":52,"location":{"plate":0,"x":0,"y":4}},{"id":53,"location":{"plate":0,"x":1,"y":4}},{"id":54,"location":{"plate":0,"x":2,"y":4}},{"id":55,"location":{"plate":0,"x":3,"y":4}},{"id":56,"location":{"plate":0,"x":4,"y":4}},{"id":57,"location":{"plate":0,"x":0,"y":5}},{"id":58,"location":{"plate":0,"x":1,"y":5}},{"id":59,"location":{"plate":0,"x":2,"y":5}},{"id":60,"location":{"plate":0,"x":3,"y":5}},{"id":61,"location":{"plate":0,"x":4,"y":5}},{"id":62,"location":{"plate":0,"x":0,"y":6}},{"id":63,"location":{"plate":0,"x":1,"y":6}},{"id":64,"location":{"plate":0,"x":2,"y":6}},{"id":65,"location":{"plate":0,"x":3,"y":6}},{"id":66,"location":{"plate":0,"x":4,"y":6}},{"id":67,"location":{"plate":1,"x":0,"y":0}},{"id":68,"location":{"plate":1,"x":1,"y":0}},{"id":69,"location":{"plate":1,"x":2,"y":0}},{"id":70,"location":{"plate":1,"x":3,"y":0}},{"id":71,"location":{"plate":1,"x":4,"y":0}},{"id":72,"location":{"plate":1,"x":0,"y":1}},{"id":73,"location":{"plate":1,"x":1,"y":1}},{"id":74,"location":{"plate":1,"x":2,"y":1}},{"id":75,"location":{"plate":1,"x":3,"y":1}},{"id":76,"location":{"plate":1,"x":4,"y":1}},{"id":77,"location":{"plate":1,"x":0,"y":2}},{"id":78,"location":{"plate":1,"x":1,"y":2}},{"id":79,"location":{"plate":1,"x":2,"y":2}},{"id":80,"location":{"plate":1,"x":3,"y":2}},{"id":81,"location":{"plate":1,"x":4,"y":2}},{"id":82,"location":{"plate":1,"x":0,"y":3}},{"id":83,"location":{"plate":1,"x":1,"y":3}},{"id":84,"location":{"plate":1,"x":2,"y":3}},{"id":85,"location":{"plate":1,"x":3,"y":3}},{"id":86,"location":{"plate":1,"x":4,"y":3}},{"id":87,"location":{"plate":1,"x":0,"y":4}},{"id":88,"location":{"plate":1,"x":1,"y":4}},{"id":89,"location":{"plate":1,"x":2,"y":4}},{"id":90,"location":{"plate":1,"x":3,"y":4}},{"id":91,"location":{"plate":1,"x":4,"y":4}},{"id":92,"location":{"plate":1,"x":0,"y":5}},{"id":93,"location":{"plate":1,"x":1,"y":5}},{"id":94,"location":{"plate":1,"x":2,"y":5}},{"id":95,"location":{"plate":1,"x":3,"y":5}},{"id":96,"location":{"plate":1,"x":4,"y":5}},{"id":97,"location":{"plate":1,"x":0,"y":6}},{"id":98,"location":{"plate":1,"x":1,"y":6}},{"id":99,"location":{"plate":1,"x":2,"y":6}},{"id":100,"location":{"plate":1,"x":3,"y":6}},{"id":101,"location":{"plate":1,"x":4,"y":6}}]},"currentColor":0,"gameType":0,"hostColor":0,"msgList":[],"scoreboard":[0,0]},"History":{"steps":[{"srcChessId":31}]}}
 No newline at end of file
{"Game":{"chessboard":{"chessList":[{"chessColor":0,"chessType":0,"location":{"plate":2,"x":1,"y":3},"reversal":true,"selected":false,"id":0},{"chessColor":0,"chessType":0,"location":{"plate":2,"x":2,"y":3},"reversal":true,"selected":false,"id":1},{"chessColor":0,"chessType":1,"location":{"plate":2,"x":1,"y":6},"reversal":false,"selected":false,"id":2},{"chessColor":0,"chessType":2,"location":{"plate":2,"x":0,"y":1},"reversal":false,"selected":false,"id":3},{"chessColor":0,"chessType":2,"location":{"plate":2,"x":3,"y":4},"reversal":true,"selected":false,"id":4},{"chessColor":0,"chessType":3,"location":{"plate":2,"x":3,"y":5},"reversal":false,"selected":false,"id":5},{"chessColor":0,"chessType":3,"location":{"plate":2,"x":2,"y":7},"reversal":false,"selected":false,"id":6},{"chessColor":0,"chessType":4,"location":{"plate":2,"x":3,"y":1},"reversal":false,"selected":false,"id":7},{"chessColor":0,"chessType":4,"location":{"plate":2,"x":2,"y":5},"reversal":true,"selected":false,"id":8},{"chessColor":0,"chessType":5,"location":{"plate":2,"x":3,"y":3},"reversal":true,"selected":false,"id":9},{"chessColor":0,"chessType":5,"location":{"plate":2,"x":1,"y":7},"reversal":false,"selected":false,"id":10},{"chessColor":0,"chessType":6,"location":{"plate":2,"x":3,"y":7},"reversal":false,"selected":false,"id":11},{"chessColor":0,"chessType":6,"location":{"plate":2,"x":0,"y":3},"reversal":true,"selected":false,"id":12},{"chessColor":0,"chessType":6,"location":{"plate":2,"x":2,"y":6},"reversal":false,"selected":false,"id":13},{"chessColor":0,"chessType":6,"location":{"plate":2,"x":1,"y":1},"reversal":false,"selected":false,"id":14},{"chessColor":0,"chessType":6,"location":{"plate":2,"x":3,"y":0},"reversal":false,"selected":false,"id":15},{"chessColor":1,"chessType":0,"location":{"plate":2,"x":0,"y":0},"reversal":false,"selected":false,"id":16},{"chessColor":1,"chessType":0,"location":{"plate":2,"x":0,"y":5},"reversal":false,"selected":false,"id":17},{"chessColor":1,"chessType":1,"location":{"plate":2,"x":2,"y":0},"reversal":false,"selected":false,"id":18},{"chessColor":1,"chessType":2,"location":{"plate":2,"x":1,"y":2},"reversal":true,"selected":false,"id":19},{"chessColor":1,"chessType":2,"location":{"plate":2,"x":1,"y":0},"reversal":false,"selected":false,"id":20},{"chessColor":1,"chessType":3,"location":{"plate":2,"x":0,"y":6},"reversal":false,"selected":false,"id":21},{"chessColor":1,"chessType":3,"location":{"plate":2,"x":2,"y":2},"reversal":true,"selected":false,"id":22},{"chessColor":1,"chessType":4,"location":{"plate":2,"x":0,"y":7},"reversal":false,"selected":false,"id":23},{"chessColor":1,"chessType":4,"location":{"plate":2,"x":0,"y":2},"reversal":true,"selected":false,"id":24},{"chessColor":1,"chessType":5,"location":{"plate":2,"x":1,"y":4},"reversal":true,"selected":false,"id":25},{"chessColor":1,"chessType":5,"location":{"plate":2,"x":0,"y":4},"reversal":true,"selected":false,"id":26},{"chessColor":1,"chessType":6,"location":{"plate":2,"x":1,"y":5},"reversal":false,"selected":false,"id":27},{"chessColor":1,"chessType":6,"location":{"plate":2,"x":2,"y":1},"reversal":false,"selected":false,"id":28},{"chessColor":1,"chessType":6,"location":{"plate":2,"x":2,"y":4},"reversal":true,"selected":false,"id":29},{"chessColor":1,"chessType":6,"location":{"plate":2,"x":3,"y":6},"reversal":false,"selected":false,"id":30},{"chessColor":1,"chessType":6,"location":{"plate":2,"x":3,"y":2},"reversal":true,"selected":false,"id":31}],"idGrid":[[0,1,11,16],[15,27,18,9],[22,24,8,4],[28,13,17,2],[7,29,26,20],[25,12,23,3],[10,30,19,6],[14,5,21,31]],"sideStacks":[{"chessColor":0},{"chessColor":1}],"squareList":[{"id":32,"location":{"plate":0,"x":0,"y":0}},{"id":33,"location":{"plate":0,"x":1,"y":0}},{"id":34,"location":{"plate":0,"x":2,"y":0}},{"id":35,"location":{"plate":0,"x":3,"y":0}},{"id":36,"location":{"plate":0,"x":4,"y":0}},{"id":37,"location":{"plate":0,"x":0,"y":1}},{"id":38,"location":{"plate":0,"x":1,"y":1}},{"id":39,"location":{"plate":0,"x":2,"y":1}},{"id":40,"location":{"plate":0,"x":3,"y":1}},{"id":41,"location":{"plate":0,"x":4,"y":1}},{"id":42,"location":{"plate":0,"x":0,"y":2}},{"id":43,"location":{"plate":0,"x":1,"y":2}},{"id":44,"location":{"plate":0,"x":2,"y":2}},{"id":45,"location":{"plate":0,"x":3,"y":2}},{"id":46,"location":{"plate":0,"x":4,"y":2}},{"id":47,"location":{"plate":0,"x":0,"y":3}},{"id":48,"location":{"plate":0,"x":1,"y":3}},{"id":49,"location":{"plate":0,"x":2,"y":3}},{"id":50,"location":{"plate":0,"x":3,"y":3}},{"id":51,"location":{"plate":0,"x":4,"y":3}},{"id":52,"location":{"plate":0,"x":0,"y":4}},{"id":53,"location":{"plate":0,"x":1,"y":4}},{"id":54,"location":{"plate":0,"x":2,"y":4}},{"id":55,"location":{"plate":0,"x":3,"y":4}},{"id":56,"location":{"plate":0,"x":4,"y":4}},{"id":57,"location":{"plate":0,"x":0,"y":5}},{"id":58,"location":{"plate":0,"x":1,"y":5}},{"id":59,"location":{"plate":0,"x":2,"y":5}},{"id":60,"location":{"plate":0,"x":3,"y":5}},{"id":61,"location":{"plate":0,"x":4,"y":5}},{"id":62,"location":{"plate":0,"x":0,"y":6}},{"id":63,"location":{"plate":0,"x":1,"y":6}},{"id":64,"location":{"plate":0,"x":2,"y":6}},{"id":65,"location":{"plate":0,"x":3,"y":6}},{"id":66,"location":{"plate":0,"x":4,"y":6}},{"id":67,"location":{"plate":1,"x":0,"y":0}},{"id":68,"location":{"plate":1,"x":1,"y":0}},{"id":69,"location":{"plate":1,"x":2,"y":0}},{"id":70,"location":{"plate":1,"x":3,"y":0}},{"id":71,"location":{"plate":1,"x":4,"y":0}},{"id":72,"location":{"plate":1,"x":0,"y":1}},{"id":73,"location":{"plate":1,"x":1,"y":1}},{"id":74,"location":{"plate":1,"x":2,"y":1}},{"id":75,"location":{"plate":1,"x":3,"y":1}},{"id":76,"location":{"plate":1,"x":4,"y":1}},{"id":77,"location":{"plate":1,"x":0,"y":2}},{"id":78,"location":{"plate":1,"x":1,"y":2}},{"id":79,"location":{"plate":1,"x":2,"y":2}},{"id":80,"location":{"plate":1,"x":3,"y":2}},{"id":81,"location":{"plate":1,"x":4,"y":2}},{"id":82,"location":{"plate":1,"x":0,"y":3}},{"id":83,"location":{"plate":1,"x":1,"y":3}},{"id":84,"location":{"plate":1,"x":2,"y":3}},{"id":85,"location":{"plate":1,"x":3,"y":3}},{"id":86,"location":{"plate":1,"x":4,"y":3}},{"id":87,"location":{"plate":1,"x":0,"y":4}},{"id":88,"location":{"plate":1,"x":1,"y":4}},{"id":89,"location":{"plate":1,"x":2,"y":4}},{"id":90,"location":{"plate":1,"x":3,"y":4}},{"id":91,"location":{"plate":1,"x":4,"y":4}},{"id":92,"location":{"plate":1,"x":0,"y":5}},{"id":93,"location":{"plate":1,"x":1,"y":5}},{"id":94,"location":{"plate":1,"x":2,"y":5}},{"id":95,"location":{"plate":1,"x":3,"y":5}},{"id":96,"location":{"plate":1,"x":4,"y":5}},{"id":97,"location":{"plate":1,"x":0,"y":6}},{"id":98,"location":{"plate":1,"x":1,"y":6}},{"id":99,"location":{"plate":1,"x":2,"y":6}},{"id":100,"location":{"plate":1,"x":3,"y":6}},{"id":101,"location":{"plate":1,"x":4,"y":6}}]},"currentColor":0,"gameType":0,"hostColor":1,"msgList":[],"scoreboard":[0,0]},"History":{"eatSteps":[],"flipSteps":[{"srcChessId":22},{"srcChessId":31},{"srcChessId":9},{"srcChessId":1},{"srcChessId":0},{"srcChessId":19},{"srcChessId":24},{"srcChessId":12},{"srcChessId":26},{"srcChessId":25},{"srcChessId":29},{"srcChessId":4},{"srcChessId":8}],"initialState":{"chessboard":{"chessList":[{"chessColor":0,"chessType":0,"location":{"plate":2,"x":1,"y":3},"reversal":false,"selected":false,"id":0},{"chessColor":0,"chessType":0,"location":{"plate":2,"x":2,"y":3},"reversal":false,"selected":false,"id":1},{"chessColor":0,"chessType":1,"location":{"plate":2,"x":1,"y":6},"reversal":false,"selected":false,"id":2},{"chessColor":0,"chessType":2,"location":{"plate":2,"x":0,"y":1},"reversal":false,"selected":false,"id":3},{"chessColor":0,"chessType":2,"location":{"plate":2,"x":3,"y":4},"reversal":false,"selected":false,"id":4},{"chessColor":0,"chessType":3,"location":{"plate":2,"x":3,"y":5},"reversal":false,"selected":false,"id":5},{"chessColor":0,"chessType":3,"location":{"plate":2,"x":2,"y":7},"reversal":false,"selected":false,"id":6},{"chessColor":0,"chessType":4,"location":{"plate":2,"x":3,"y":1},"reversal":false,"selected":false,"id":7},{"chessColor":0,"chessType":4,"location":{"plate":2,"x":2,"y":5},"reversal":false,"selected":false,"id":8},{"chessColor":0,"chessType":5,"location":{"plate":2,"x":3,"y":3},"reversal":false,"selected":false,"id":9},{"chessColor":0,"chessType":5,"location":{"plate":2,"x":1,"y":7},"reversal":false,"selected":false,"id":10},{"chessColor":0,"chessType":6,"location":{"plate":2,"x":3,"y":7},"reversal":false,"selected":false,"id":11},{"chessColor":0,"chessType":6,"location":{"plate":2,"x":0,"y":3},"reversal":false,"selected":false,"id":12},{"chessColor":0,"chessType":6,"location":{"plate":2,"x":2,"y":6},"reversal":false,"selected":false,"id":13},{"chessColor":0,"chessType":6,"location":{"plate":2,"x":1,"y":1},"reversal":false,"selected":false,"id":14},{"chessColor":0,"chessType":6,"location":{"plate":2,"x":3,"y":0},"reversal":false,"selected":false,"id":15},{"chessColor":1,"chessType":0,"location":{"plate":2,"x":0,"y":0},"reversal":false,"selected":false,"id":16},{"chessColor":1,"chessType":0,"location":{"plate":2,"x":0,"y":5},"reversal":false,"selected":false,"id":17},{"chessColor":1,"chessType":1,"location":{"plate":2,"x":2,"y":0},"reversal":false,"selected":false,"id":18},{"chessColor":1,"chessType":2,"location":{"plate":2,"x":1,"y":2},"reversal":false,"selected":false,"id":19},{"chessColor":1,"chessType":2,"location":{"plate":2,"x":1,"y":0},"reversal":false,"selected":false,"id":20},{"chessColor":1,"chessType":3,"location":{"plate":2,"x":0,"y":6},"reversal":false,"selected":false,"id":21},{"chessColor":1,"chessType":3,"location":{"plate":2,"x":2,"y":2},"reversal":false,"selected":false,"id":22},{"chessColor":1,"chessType":4,"location":{"plate":2,"x":0,"y":7},"reversal":false,"selected":false,"id":23},{"chessColor":1,"chessType":4,"location":{"plate":2,"x":0,"y":2},"reversal":false,"selected":false,"id":24},{"chessColor":1,"chessType":5,"location":{"plate":2,"x":1,"y":4},"reversal":false,"selected":false,"id":25},{"chessColor":1,"chessType":5,"location":{"plate":2,"x":0,"y":4},"reversal":false,"selected":false,"id":26},{"chessColor":1,"chessType":6,"location":{"plate":2,"x":1,"y":5},"reversal":false,"selected":false,"id":27},{"chessColor":1,"chessType":6,"location":{"plate":2,"x":2,"y":1},"reversal":false,"selected":false,"id":28},{"chessColor":1,"chessType":6,"location":{"plate":2,"x":2,"y":4},"reversal":false,"selected":false,"id":29},{"chessColor":1,"chessType":6,"location":{"plate":2,"x":3,"y":6},"reversal":false,"selected":false,"id":30},{"chessColor":1,"chessType":6,"location":{"plate":2,"x":3,"y":2},"reversal":false,"selected":false,"id":31}],"idGrid":[[2,22,1,27],[5,3,14,18],[10,30,19,11],[29,31,20,0],[26,23,15,21],[16,24,13,7],[9,8,6,28],[12,25,17,4]],"sideStacks":[{"chessColor":0},{"chessColor":1}],"squareList":[{"id":32,"location":{"plate":0,"x":0,"y":0}},{"id":33,"location":{"plate":0,"x":1,"y":0}},{"id":34,"location":{"plate":0,"x":2,"y":0}},{"id":35,"location":{"plate":0,"x":3,"y":0}},{"id":36,"location":{"plate":0,"x":4,"y":0}},{"id":37,"location":{"plate":0,"x":0,"y":1}},{"id":38,"location":{"plate":0,"x":1,"y":1}},{"id":39,"location":{"plate":0,"x":2,"y":1}},{"id":40,"location":{"plate":0,"x":3,"y":1}},{"id":41,"location":{"plate":0,"x":4,"y":1}},{"id":42,"location":{"plate":0,"x":0,"y":2}},{"id":43,"location":{"plate":0,"x":1,"y":2}},{"id":44,"location":{"plate":0,"x":2,"y":2}},{"id":45,"location":{"plate":0,"x":3,"y":2}},{"id":46,"location":{"plate":0,"x":4,"y":2}},{"id":47,"location":{"plate":0,"x":0,"y":3}},{"id":48,"location":{"plate":0,"x":1,"y":3}},{"id":49,"location":{"plate":0,"x":2,"y":3}},{"id":50,"location":{"plate":0,"x":3,"y":3}},{"id":51,"location":{"plate":0,"x":4,"y":3}},{"id":52,"location":{"plate":0,"x":0,"y":4}},{"id":53,"location":{"plate":0,"x":1,"y":4}},{"id":54,"location":{"plate":0,"x":2,"y":4}},{"id":55,"location":{"plate":0,"x":3,"y":4}},{"id":56,"location":{"plate":0,"x":4,"y":4}},{"id":57,"location":{"plate":0,"x":0,"y":5}},{"id":58,"location":{"plate":0,"x":1,"y":5}},{"id":59,"location":{"plate":0,"x":2,"y":5}},{"id":60,"location":{"plate":0,"x":3,"y":5}},{"id":61,"location":{"plate":0,"x":4,"y":5}},{"id":62,"location":{"plate":0,"x":0,"y":6}},{"id":63,"location":{"plate":0,"x":1,"y":6}},{"id":64,"location":{"plate":0,"x":2,"y":6}},{"id":65,"location":{"plate":0,"x":3,"y":6}},{"id":66,"location":{"plate":0,"x":4,"y":6}},{"id":67,"location":{"plate":1,"x":0,"y":0}},{"id":68,"location":{"plate":1,"x":1,"y":0}},{"id":69,"location":{"plate":1,"x":2,"y":0}},{"id":70,"location":{"plate":1,"x":3,"y":0}},{"id":71,"location":{"plate":1,"x":4,"y":0}},{"id":72,"location":{"plate":1,"x":0,"y":1}},{"id":73,"location":{"plate":1,"x":1,"y":1}},{"id":74,"location":{"plate":1,"x":2,"y":1}},{"id":75,"location":{"plate":1,"x":3,"y":1}},{"id":76,"location":{"plate":1,"x":4,"y":1}},{"id":77,"location":{"plate":1,"x":0,"y":2}},{"id":78,"location":{"plate":1,"x":1,"y":2}},{"id":79,"location":{"plate":1,"x":2,"y":2}},{"id":80,"location":{"plate":1,"x":3,"y":2}},{"id":81,"location":{"plate":1,"x":4,"y":2}},{"id":82,"location":{"plate":1,"x":0,"y":3}},{"id":83,"location":{"plate":1,"x":1,"y":3}},{"id":84,"location":{"plate":1,"x":2,"y":3}},{"id":85,"location":{"plate":1,"x":3,"y":3}},{"id":86,"location":{"plate":1,"x":4,"y":3}},{"id":87,"location":{"plate":1,"x":0,"y":4}},{"id":88,"location":{"plate":1,"x":1,"y":4}},{"id":89,"location":{"plate":1,"x":2,"y":4}},{"id":90,"location":{"plate":1,"x":3,"y":4}},{"id":91,"location":{"plate":1,"x":4,"y":4}},{"id":92,"location":{"plate":1,"x":0,"y":5}},{"id":93,"location":{"plate":1,"x":1,"y":5}},{"id":94,"location":{"plate":1,"x":2,"y":5}},{"id":95,"location":{"plate":1,"x":3,"y":5}},{"id":96,"location":{"plate":1,"x":4,"y":5}},{"id":97,"location":{"plate":1,"x":0,"y":6}},{"id":98,"location":{"plate":1,"x":1,"y":6}},{"id":99,"location":{"plate":1,"x":2,"y":6}},{"id":100,"location":{"plate":1,"x":3,"y":6}},{"id":101,"location":{"plate":1,"x":4,"y":6}}]},"currentColor":1,"gameType":0,"hostColor":1,"msgList":[],"scoreboard":[0,0]},"moveSteps":[],"references":[{"_1":0,"_2":0},{"_1":0,"_2":1},{"_1":0,"_2":2},{"_1":0,"_2":3},{"_1":0,"_2":4},{"_1":0,"_2":5},{"_1":0,"_2":6},{"_1":0,"_2":7},{"_1":0,"_2":8},{"_1":0,"_2":9},{"_1":0,"_2":10},{"_1":0,"_2":11},{"_1":0,"_2":12}]}}
 No newline at end of file
+13 −5
Original line number Diff line number Diff line
@@ -240,9 +240,10 @@ public class AppController {
    }
    
    public void backToStart() {
        if (status == AppStatus.ROOM)
        if (status == AppStatus.ROOM) {
            RoomFrame.instance.dispose();
        else if (status == AppStatus.GAME)
        }
        else if (status == AppStatus.GAME) {
            ChessGameFrame.instance.dispose();
            if (Game.instance != null && Game.instance.gameType != GameType.ONLINE) {
                try {
@@ -252,6 +253,7 @@ public class AppController {
                    JOptionPane.showMessageDialog(null, "阿哦,保存时发生错误了:" + e.getMessage(), "提示", JOptionPane.WARNING_MESSAGE);
                }
            }
        }
        else return;
        SwingUtilities.invokeLater(() -> {
            AppFrame.instance = new AppFrame();
@@ -260,10 +262,16 @@ public class AppController {
        status = AppStatus.START;
    }
    
    /**
     * 年度大无语事件之JSON能做的事JSONObject不能做
     * @param path
     * @throws IOException
     * @throws JSONException
     */
    public void read(String path) throws IOException, JSONException {
        JSONObject jsonObject = JSONObject.parse(Files.readString(Path.of(path)));
        savedGame = jsonObject.getObject("Game", Game.class);
        savedHistory = jsonObject.getObject("History", History.class);
        savedGame = JSON.parseObject(jsonObject.getJSONObject("Game").toString(), Game.class);
        savedHistory = JSON.parseObject(jsonObject.getJSONObject("History").toString(), History.class);
    }
    
    public void write(String path) throws IOException, JSONException {
+2 −1
Original line number Diff line number Diff line
@@ -32,6 +32,7 @@ public enum ChessClickController {
        Square square = squareCom.getBackSquare();
        Step step = null;
        //处理一番,结果写到step,否则step为null即无结果
        if(Game.instance.gameType == GameType.LOCAL_AI && Game.instance.getCurrentColor() != Game.instance.hostColor) return;
        if (firstId == -1) {    //判断第一次点击
            if (square instanceof Chess chess) {
                if (!chess.isReversal()) {  //未翻开,翻之
@@ -57,7 +58,7 @@ public enum ChessClickController {
            }else {
                step = Game.instance.resolveStep(step);
                if(step != null) {
                    History.instance.steps.add(step);
                    History.instance.push(step);
                    firstId = -1;
                    if(Game.instance.gameType == GameType.LOCAL_AI){
                        AI.instance.start();
Loading