Input.h
资源名称:3DRPG.rar [点击查看]
上传用户:cjwanglu
上传日期:2013-07-10
资源大小:4744k
文件大小:1k
源码类别:
游戏
开发平台:
Visual C++
- #include <dinput.h>
- #include <dinputd.h>
- #include <d3dx9.h>
- #include "Game.h"
- #include "Terrain.h"
- #include <mmsystem.h>
- #define MK_MIN 0x100
- #define MK_LEFT 0x100 //>255
- #define MK_RIGHT 0x101
- #define MK_MID 0x102
- class CInput
- {
- public:
- CInput(HINSTANCE hInstance,HWND hwnd,int nIcon);
- virtual ~CInput();
- void Control(bool* flag,D3DXVECTOR3 * p1,float * up,bool * shoot,
- POSS * NumOfPos,bool * CallPress,bool * ButtonPress,
- bool * Result,POSITION * ViewPos,COLLIPE * col,
- CTerrain * m_pTerrain,NPOSITION * BossPos,bool * nomoney);
- LRESULT Update();
- LRESULT GetKeyState(DWORD Keycode);
- bool control;
- bool * mygod;
- bool * motherfuck;
- bool run;
- void GetOut(bool * hihi);
- private:
- float m_Up;
- float m_PreUp;
- LPDIRECTINPUT8 m_pInput;
- LPDIRECTINPUTDEVICE8 m_pInputDevice;
- char m_cKeyboardState[256];
- char m_cKeyboardStateOld[256];
- DIMOUSESTATE m_MouseState;
- DIMOUSESTATE m_MouseStateOld;
- LPDIRECTINPUTDEVICE8 m_pMouseInput;
- HINSTANCE m_hInst;
- HWND m_hWnd;
- int NIcon;
- };