#pragma once

#include "PG_FriendList.h"
#include "../../MainProc/NetGlobal.h"

class NetCli_FriendList : public CNetGlobal
{
protected:
    //-------------------------------------------------------------------
    static	NetCli_FriendList* This;
    static	bool _Init();
    static	bool _Release();	
    //-------------------------------------------------------------------
	static void _PG_Friend_ChattoC_BefriendRequest	( int Sockid , int Size , void* Data );	
	static void _PG_Friend_LtoC_AddFriend			( int Sockid , int Size , void* Data );		
	static void _PG_Friend_LtoC_DelFriend			( int Sockid , int Size , void* Data );		
	static void _PG_Friend_LtoC_FriendList			( int Sockid , int Size , void* Data );	


	static void _PG_Friend_ChattoC_PlayerOnline		( int Sockid , int Size , void* Data );
	static void _PG_Friend_ChattoC_PlayerOffline	( int Sockid , int Size , void* Data );
	static void _PG_Friend_ChattoC_ModifyInfo		( int Sockid , int Size , void* Data );

	static void		OnEvent_ServerDisConnect		( int ServerID );
public:    
    NetCli_FriendList() { This = this; }

	static	NetCli_FriendList*	GetThis()						{ return This; }

	//要求和某人建立好友
	static void SChat_BefriendRequest	( char* Name );	
	static void SChat_BefriendResult	( char* Name , bool Result );
	static void SL_DelFriend			( char* Name );

	static void SL_ModifyMyInfo			( char* Note );
	static void SL_AddBadFriend			( char* Name );
	static void SL_DelBadFriend			( char* Name );
	static void SL_SetFriendInfo		( char* Name , char* Group , char* Note );

	virtual void RChat_BefriendRequest	( char* FriendName ) = 0;
	virtual void RL_AddFriend			( char* FriendName ) = 0;
	virtual void RL_DelFriend			( char* FriendName ) = 0;
	virtual void RL_FriendList			( FriendListStruct& FriendList ) = 0;

	virtual void RChat_PlayerOnline		( char* RoleName , char* Note , int ZoneID , LookStruct& Look , Voc_ENUM Voc , Voc_ENUM Voc_Sub , int LV , int LV_Sub , Sex_ENUM Sex ) = 0;
	virtual void RChat_PlayerOffline	( char* RoleName ) = 0;
	virtual void RChat_ModifyInfo		( char* RoleName , char* Note , int ZoneID , Voc_ENUM Voc , Voc_ENUM Voc_Sub , int LV , int LV_Sub , Sex_ENUM Sex ) = 0;

	virtual void OnServerDisConnect		( int ServerID ) = 0;
};

