the game where you go into mines and start crafting! but for consoles (forked directly from smartcmd's github)
1#include "stdafx.h"
2
3#ifdef _WINDOWS64
4#include "Windows64\KeyboardMouseInput.h"
5
6int Mouse::getX()
7{
8 return KMInput.GetMouseX();
9}
10
11int Mouse::getY()
12{
13 // Return Y in bottom-up coordinates (OpenGL convention, matching original Java LWJGL Mouse)
14 RECT rect;
15 GetClientRect(KMInput.GetHWnd(), &rect);
16 return (rect.bottom - 1) - KMInput.GetMouseY();
17}
18
19bool Mouse::isButtonDown(int button)
20{
21 return KMInput.IsMouseDown(button);
22}
23
24bool Keyboard::isKeyDown(int key)
25{
26 // Map Keyboard constants to Windows virtual key codes
27 if (key == Keyboard::KEY_LSHIFT) return KMInput.IsKeyDown(VK_LSHIFT);
28 if (key == Keyboard::KEY_RSHIFT) return KMInput.IsKeyDown(VK_RSHIFT);
29 if (key == Keyboard::KEY_ESCAPE) return KMInput.IsKeyDown(VK_ESCAPE);
30 if (key == Keyboard::KEY_RETURN) return KMInput.IsKeyDown(VK_RETURN);
31 if (key == Keyboard::KEY_BACK) return KMInput.IsKeyDown(VK_BACK);
32 if (key == Keyboard::KEY_SPACE) return KMInput.IsKeyDown(VK_SPACE);
33 if (key == Keyboard::KEY_TAB) return KMInput.IsKeyDown(VK_TAB);
34 if (key == Keyboard::KEY_UP) return KMInput.IsKeyDown(VK_UP);
35 if (key == Keyboard::KEY_DOWN) return KMInput.IsKeyDown(VK_DOWN);
36 if (key == Keyboard::KEY_LEFT) return KMInput.IsKeyDown(VK_LEFT);
37 if (key == Keyboard::KEY_RIGHT) return KMInput.IsKeyDown(VK_RIGHT);
38 if (key >= Keyboard::KEY_A && key <= Keyboard::KEY_Z)
39 return KMInput.IsKeyDown('A' + (key - Keyboard::KEY_A));
40 return false;
41}
42#endif
43
44void glReadPixels(int,int, int, int, int, int, ByteBuffer *)
45{
46}
47
48void glClearDepth(double)
49{
50}
51
52void glVertexPointer(int, int, int, int)
53{
54}
55
56void glVertexPointer(int, int, FloatBuffer *)
57{
58}
59
60void glTexCoordPointer(int, int, int, int)
61{
62}
63
64void glTexCoordPointer(int, int, FloatBuffer *)
65{
66}
67
68void glNormalPointer(int, int, int)
69{
70}
71
72void glNormalPointer(int, ByteBuffer *)
73{
74}
75
76void glEnableClientState(int)
77{
78}
79
80void glDisableClientState(int)
81{
82}
83
84void glColorPointer(int, int, int, int)
85{
86}
87
88void glColorPointer(int, bool, int, ByteBuffer *)
89{
90}
91
92void glDrawArrays(int,int,int)
93{
94}
95
96void glNormal3f(float,float,float)
97{
98}
99
100void glGenQueriesARB(IntBuffer *)
101{
102}
103
104void glBeginQueryARB(int,int)
105{
106}
107
108void glEndQueryARB(int)
109{
110}
111
112void glGetQueryObjectuARB(int,int,IntBuffer *)
113{
114}
115
116void glShadeModel(int)
117{
118}
119
120void glColorMaterial(int,int)
121{
122}
123
124//1.8.2
125void glClientActiveTexture(int)
126{
127}
128
129void glActiveTexture(int)
130{
131}
132
133void glFlush()
134{
135}
136
137void glTexGeni(int,int,int)
138{
139}
140
141#ifdef _XBOX
142// 4J Stu - Added these to stop us needing to pull in loads of media libraries just to use Qnet
143#include <xcam.h>
144DWORD XCamInitialize(){ return 0; }
145VOID XCamShutdown() {}
146
147DWORD XCamCreateStreamEngine(
148 CONST XCAM_STREAM_ENGINE_INIT_PARAMS *pParams,
149 PIXCAMSTREAMENGINE *ppEngine
150 ) { return 0; }
151
152DWORD XCamSetView(
153 XCAMZOOMFACTOR ZoomFactor,
154 LONG XCenter,
155 LONG YCenter,
156 PXOVERLAPPED pOverlapped
157) { return 0; }
158
159XCAMDEVICESTATE XCamGetStatus() { return XCAMDEVICESTATE_DISCONNECTED; }
160#endif