📄 suoha_main.h
字号:
/********************************************************************************
$History: Suoha_main.h
Date .................. Modification ......................................
08/14/2002 version 1.1.0 zhangzg
$End
*******************************************************************************/
#ifndef _MMI_GAME_H_
#define _MMI_GAME_H_
#define LEFT_B1 2
#define TOP_B1 160-HEIGHT_BUTTON-2
#define LEFT_B2 120-WIDTH_BUTTON-2
#define TOP_B2 160-HEIGHT_BUTTON-2
#define POSITON_TXT 1
#define SUOHA_ISACTING 1 //4 进入mainwin_states的初始状态
#define SUOHA_ISSTAKING 2 //4如果按下了下注的按钮,处在这样的状态
#define SUOHA_ISCHECKING 4 //4 查看当前的下注的情况
// SUOHA_ISDISPLAYING,
#define SUOHA_COMPUTER_THINKING 16//when the computer is thingking, the program does not receive any message
#define SUOHA_ISENDING 32
//timer states
#define TIMER_TCOMPUTER 1 //turn computer
#define TIMER_TPLAYER 2 //turn player
#define TIMER_INTERACTIVE 3 //interactive
#define TIMER_FANGQI 4 //player or computer quits
#define TIMER_QUANSUO 5 //player quansuo
//timer states for start animation
#define TIMER_START_ANI_UP 1
#define TIMER_START_ANI_DOWN 2
#define TIMER_START_ANI_ONEUP 3
#define TIMER_START_ANI_ONEDOWN 4
#define TIMER_START_ANI_EXTEND 5
#define TIMER_START_ANI_PIC2 6
//kbd or tim must repond some events according to the states below
typedef enum
{
SUOHA_START_ANI, //suoha is starting and welcome animation is showing
SUOHA_OPP_SELECT, //select an opponent among three ones to play with
SUOHA_SAVE_MONEY,
SUOHA_MAIN_WINDOW, //main window of playing
SUOHA_MON_PUB, //publish the money of player and opponent after one case
}T_SUOHA_WIN_STATES;
typedef enum
{
COMPUTER_CARD,
PLAYER_CARD,
ACTIONS,
STAKES
}T_SUOHA_MAINWIN_THINGTYPE;
//the structure is an abstract of those things, such as the opponents, cards and so on.
//It can be linked as a link. As well, It also present a focus thing
typedef struct
{
MfwRect rect;
T_SUOHA_MAINWIN_THINGTYPE thingtype;
unsigned short codenum;
BOOL isenabled;
//T_SUOHA_MAINWIN_FOCUSTHINGS *nextfocus;
}T_SUOHA_MAINWIN_FOCUSTHINGS;//when the main window is redrawn(the system causes), the strings in some zones must be redrawn
typedef struct
{
//MfwRect rect;
char curr_str[30];
BOOL isEmpty;
UBYTE attr;
}T_SUOHA_CURR_STR;
//flash write and read( money )
/***************************************************************************
****************************************************************************/
int Suoha_Aktivate(MfwMnu* m, MfwMnuItem* i);
int Suoha_Pre(MfwMnu* m, MfwMnuItem* i);
T_MFW_HND Suoha_Start(T_MFW_HND win_parent,char *character);
T_MFW_HND Suoha_Create(T_MFW_HND parent_window);
static int Suoha_Win_Cb(MfwEvt e, MfwWin *w);
static int Suoha_Kbd_Cb(MfwEvt e, MfwKbd *k);
static int Suoha_Tim_Cb(MfwEvt e, MfwTim *t);
void Suoha_Destroy(T_MFW_HND own_window);
//void Suoha_Display_Start_Picture();
#endif
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -