#pragma once

#include <windows.h>
#include <stdio.h>
#include <stdlib.h>
#include <iostream>
#include <fstream>
#include <cstring>
#include <Dbghelp.h>
#include <time.h>

//函数指针声明
	//HBITMAP GMCBytesToHBitmap(char *libfile,int type,int restype,int index,int no);
	//HBITMAP GMCBytesToHBitmapMask(char *libfile,int type,int restype,int index,int no);
	//HBITMAP GMCBytesToHBitmapTrans(char *libfile,int type,int restype,int index,int no);
	//char * GMCGetSuffix();
	//int GMCLoadALibhead(char* Libpath,int mod);
	typedef HBITMAP (*BytesToHBitmap)(char *libfile,int type,int restype,int index,int no);
	typedef HBITMAP (*BytesToHBitmapTrans)(char *libfile,int type,int restype,int index,int no);
	typedef HBITMAP (*BytesToHBitmapMask)(char *libfile,int type,int restype,int index,int no);
	typedef int (*LoadALibhead)(char* Libpath,int mod);
	typedef char *  (*GetSuffix)();

	
	//extern char g_gameName[9+1];
	extern void InitGMC(HINSTANCE hDLLDrv);
	extern char * Plugin_GetLIBName();

	
	extern BytesToHBitmap GMCBytesToHBitmap ;
	extern BytesToHBitmapTrans GMCBytesToHBitmapTrans ;
	extern BytesToHBitmapMask GMCBytesToHBitmapMask ;
	extern LoadALibhead GMCLoadALibhead ;
	extern GetSuffix GMCGetSuffix ;

	typedef char *  (*SGetSuffix)();//srp
	typedef void (*GetFromFile)(char *infilename);//srp
	typedef int (*GetText)(char * text,int scriptType,int scriptIndex,int startAddress);//srp
	typedef int (*SetText)(char * text,int scriptType,int scriptIndex,int startAddress,int textLen);//srp
	typedef void (*SShowSayBox)(HINSTANCE hInst,HWND hwnd);//传入默认的文字
	
	extern void InitSRP(HINSTANCE hDLLDrv,char *ingameName);//srp

	extern SGetSuffix SRPGetSuffix ;//srp
	extern SetText SRPSetText ;//srp
	extern GetText SRPGetText ;//srp
	extern GetFromFile SRPGetFromFile ;//srp
	extern SShowSayBox SRPShowSayBox ;//srp
	