Esempio n. 1
0
bool Game_Init(HWND hwnd)
{
	srand((unsigned int)time(NULL));
	Direct3D_Init(hwnd,SCREENW,SCREENH,false);
	DirectInput_Init(hwnd);

	//create pointer to the back buffer
	d3ddev->GetBackBuffer(0, 0, D3DBACKBUFFER_TYPE_MONO, &backbuffer);

	//create a font
	font = MakeFont("Arial", 24);


	BuildGameWorld();

	start = GetTickCount();

	return true;
}
Esempio n. 2
0
boolean I_Init(void)
{
    if(initOk)
        return true; // Already initialized.

#ifdef __CLIENT__

    // Select drivers.
    iMouse = &qtMouse;
#ifdef WIN32
    iMouse = &win32Mouse;
    DirectInput_Init();
#endif

    Mouse_Init();
    Joystick_Init();

#endif // __CLIENT__

    initOk = true;
    return true;
}