function CurrentGameMovePiece($ConfigFile, $GameID, $SID, $PID, $Move) { $returncode = ""; // Delete previous moves from inbox (other player); $initiator = ""; $w_player_id = ""; $b_player_id = ""; $status = ""; $completion_status = ""; $start_time = ""; $next_move = ""; $this->GetGameInfoByRef($ConfigFile, $GameID, $initiator, $w_player_id, $b_player_id, $status, $completion_status, $start_time, $next_move); if ($w_player_id != $PID) { $this->PurgeOldMovesFromInbox($ConfigFile, $w_player_id, $GameID); } if ($b_player_id != $PID) { $this->PurgeOldMovesFromInbox($ConfigFile, $b_player_id, $GameID); } // Look for game timeouts now. Ideally should only check if this specific game has timed out. $this->MangeGameTimeOuts(); //Instantiate the CChess Class $oChess = new CChess($this->ChessCFGFileLocation); $returncode = $oChess->process_move($this->ChessCFGFileLocation, $PID, $GameID, $Move); unset($oChess); return $returncode; }