Don't like ads? PRO users don't see any ads ;-)
Guest

Untitled

By: a guest on Jun 14th, 2012  |  syntax: None  |  size: 1.31 KB  |  hits: 16  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. Project Part 3 (and 4)
  2. 1) 2 or 4 players
  3.         - Each player must track current position of each player and where the walls are
  4.         - last_move() -> what happened (i.e., how did the board change) after the last player moved
  5.  
  6. 2) PlayerMove class -> no change
  7.         (playerId,   move,  start,      end)
  8.          0,1,2,3^    T/F^    ^coordinates^
  9.  
  10. 3) player module -> 3 functions
  11.         i) init() -> unchanged
  12.                 (gameFile, playerId, numPlayers,     playerHomes,                       wallsRemaining)
  13.                   Board^   0,1,2,3^   2 or 4^    playerHomes[playerId]^         wallsRemaining[0]->2 player mode
  14.                                                                                 wallsRemaining[1]->4 player mode
  15.         ii) move() -> unchanged, random
  16.         iii) last_move(playerData, playerMove) returns playerData
  17.                          board^        ^state after another player moved (do not need to verify other players)
  18.  
  19. 4) Supplied player modules -> .pyc files
  20.         - 4 copies of each
  21.                 - player_human
  22.                 - player_badcomputer -> random, must beat in 2-player mode for part 4
  23.                 - player_goodcomputer -> better than random
  24.         - You may use multiple copies of your own player module if you would like
  25.         - Make a complete copy of your source code & give it a unique name
  26.                 - e.g., player_p242-07c.py
  27.  
  28. 5) Submit by 2:00 am Feb 1st.
  29.         - player module in 2 or 4 player mode
  30.         - quoridor3.txt
  31.                 - names
  32.                 - modifications from part 2
  33.                 - pseudocode for last_move