📄 mousezoneclass.h
字号:
//-----------------------------------------------------------------------------
// Name: MouseZoneClass.h
//
// Description: Class to simplify game menu navigation with the mouse
//
// File Function: Header file for the class
//
// Code:
// Copyright (c) 2002 LostLogic Corporation. All rights reserved.
//
// Local Files Required:
// MouseZoneClass.h
// MouseZoneClass.cpp
//-----------------------------------------------------------------------------
#ifndef MOUSEZONECLASS_H
#define MOUSEZONECLASS_H
#include <string.h>
#include <stdio.h>
#include <iostream.h>
#include <stdlib.h>
struct stHotSpot
{
short m_shZoneXPos;
short m_shZoneYPos;
short m_shZoneWidth;
short m_shZoneHeight;
bool m_bActive;
short m_shClickType;
char *m_szZoneName;
};
class MouseZoneClass
{
private:
int m_iMaxZones;
stHotSpot *m_HotSpots;
public:
MouseZoneClass( void );
~MouseZoneClass( void );
void vInitialize( int iMaxZones );
void vFreeZones( void );
int iAddZone( char *szZoneName, short shX, short shY, short shWidth, short shHeight, short shClickType );
int iRemoveZone( char *szZoneName );
bool bCheckZones( short shX, short shY, char *szZoneHit, bool bLeftDown, bool bRightDown );
};
#endif
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -