chuyiwen_gmsv/include/petmail.h

58 lines
1.8 KiB
C
Raw Normal View History

2016-12-24 08:45:52 +08:00
#ifndef __PETMAIL_H__
#define __PETMAIL_H__
#include "version.h"
/*
* ʸ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD>ɬ<EFBFBD><EFBFBD>ƥ<EFBFBD>ʣ<EFBFBD>
*/
#define PETMAIL_OFFMSG_MAX 10000
#define PETMAIL_OFFMSG_TIMEOUT ( 3 * 24 * 3600 )
#define PETMAIL_CHECK_OFFMSG_EXPIRE_INTERVAL 3600
#define PETMAIL_OFFMSG_TEXTLEN 512
/* ʸ<><CAB8><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBCB0><EFBFBD>ض<EFBFBD><D8B6><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ѣ<EFBFBD> <20>˼<EFBFBD><CBBC>ѷ<EFBFBD>Ի<EFBFBD><D4BB><EFBFBD><EFBFBD>ئ<EFBFBD><D8A6><EFBFBD><EFBFBD><EFBFBD>³<EFBFBD><C2B3><EFBFBD> */
#define PETMAIL_EFFECTMAX 1
#define PETMAIL_SPOOLFLOOR 777
#define PETMAIL_SPOOLX 30
#define PETMAIL_SPOOLY 30
#define PETMAIL_LOOPINTERVAL1 500
#define PETMAIL_LOOPINTERVAL2 5000
/* <20><><EFBFBD>׷<EFBFBD><D7B7>̼<EFBFBD><CCBC><EFBFBD>ƽ<EFBFBD>ҷ³߼<C2B3><DFBC><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ë<EFBFBD><C3AB><EFBFBD><EFBFBD><EFBFBD><EFBFBD> */
typedef struct
{
int use;
time_t send_tm; /* <20><><EFBFBD><EFBFBD><EFBFBD>ǻ<EFBFBD><C7BB><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ë˪<C3AB><CBAA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>+TIMEOUT<55><54> */
int color; /* ƽ<><C6BD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> */
char text[PETMAIL_OFFMSG_TEXTLEN]; /* ƽ<><C6BD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> */
char destcd[CDKEYLEN]; /* ˪<><CBAA><EFBFBD><EFBFBD>CDKEY */
char destcharname[CHARNAMELEN]; /* ˪<><CBAA><EFBFBD>Ƽ<EFBFBD>ƽ<EFBFBD>ҷ<EFBFBD> */
char srccd[CDKEYLEN]; /* ˪<><CBAA><EFBFBD>缰cdkey */
char srccharname[CHARNAMELEN]; /* ˪<><CBAA><EFBFBD>ƽ<E7BCB0>ҷ<EFBFBD> */
} PETMAIL_offmsg;
void PETMAIL_Loopfunc( int index);
BOOL PETMAIL_CheckPlayerExist( int index, int mode);
BOOL PETMAIL_initOffmsgBuffer( int count );
BOOL PETMAIL_addOffmsg( int fromindex, char *tocdkey, char *tocharaname,
char *text, int color );
PETMAIL_offmsg *PETMAIL_getOffmsg( int offmsgindex);
BOOL PETMAIL_deleteOffmsg( int offmsgindex);
void PETMAIL_proc( void );
BOOL storePetmail( void);
BOOL PETMAIL_sendPetMail( int cindex, int aindex,
int havepetindex, int haveitemindex, char* text , int color );
#ifdef _PETMAIL_DEFNUMS
void CHAR_AutoPickupMailPet( int charaindex, int petindex );
#endif
int PETMAIL_getPetMailTotalnums( void);
void PETMAIL_delPetMailTotalnums( int numflg);
void PETMAIL_setPetMailTotalnums( int numflg);
int PETMAIL_CheckIsMyOffmsg( int fromindex, char *tocdkey, char *tocharaname);
#endif