/*============================================================================*

	SUITE:		e-Scrabble
	FILE:		pci_api.h
	
	COPYRIGHT NOTICE:
	
	Copyright (C) 2001 Players Inc, All Rights Reserved

	THIS MATERIAL IS PROVIDED FOR ACADEMIC USE ONLY, you may modify it
	provided this copyright notice is preserved, however you may not
	redistribute it, or use it for commercial purposes without prior
	written permission of the authors.

	Direct questions, comments, or bug reports to:
	aul@ecf.utoronto.ca
	ticku@ecf.utoronto.ca
	varia@ecf.utoronto.ca	

*============================================================================*/


#ifndef pci_api_h
#define pci_api_h


#include <glib.h>
#include "scrabble.h"
#include "internal.h"


#define SUCCESS -1

#define AUTO_PLAYER 0;

void setup_listener ();

int pci_new_game ( gboolean, PlayerIDList * );
int pci_invite_player ( PlayerID );
int pci_start_game ( Scores * );
int pci_cancel_game ();
int pci_challenge_move ();
int pci_save_game ();
int pci_restore_game (Scores *);
int pci_try_move (Bmove, int *);
int pci_make_move (Bmove, Scores *);
int pci_accept_invite ( gboolean );
int pci_send_tiles ( Tile *, int );
int pci_get_tiles ( Tile ***t );
int pci_get_scores (Scores *);
int pci_i_am_here ();
int pci_create_AP();

void gm_user_invited ();
void gm_start_game ( gboolean, PlayerID );
void gm_player_update ();
void gm_request_move ();
void gm_request_tiles ();
void gm_game_over (WinnerPacket *);
void gm_move_revoked (Bmove, PlayerID);
void gm_new_move (Bmove);
void gm_invite_challenge ();

void gm_refresh_tray ( Tile *, int );
void incoming_message(gpointer, gint, GdkInputCondition);



#endif

