Advertisement
Guest User

Untitled

a guest
Feb 19th, 2018
70
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.55 KB | None | 0 0
  1.     public State movePawn(State s, String move, boolean isWhite) {
  2.  
  3.        
  4.             char[] movesss =  translateMove(move);
  5.         //This function updates the state after the move
  6.         int x1 = Character.getNumericValue(movesss[0]);
  7.         int y1 = Character.getNumericValue(movesss[1]);
  8.         int x2 = Character.getNumericValue(movesss[2]);
  9.         int y2 = Character.getNumericValue(movesss[3]);
  10.        
  11.         int[] nextState = new int[4];
  12.         nextState[0] = x1;
  13.         nextState[1] = y1;
  14.         nextState[2] = x2;
  15.         nextState[3] = y2;
  16.         //s.updateState(nextState, isWhite);
  17.        
  18.         return s;
  19.     }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement