From: lordhavoc Date: Mon, 29 Oct 2001 03:28:21 +0000 (+0000) Subject: no longer needs ui/mousepointer.lmp X-Git-Tag: RELEASE_0_2_0_RC1~768 X-Git-Url: https://de.git.xonotic.org/?p=xonotic%2Fdarkplaces.git;a=commitdiff_plain;h=659171da82bb0cc43ee0e2bde1c6115bc0e9d0f8 no longer needs ui/mousepointer.lmp git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@964 d7cf8633-e32d-0410-b094-e92efae38249 --- diff --git a/ui.c b/ui.c index 042b3a59..1e10d337 100644 --- a/ui.c +++ b/ui.c @@ -22,11 +22,33 @@ static ui_item_t *ui_keyrealitem; static ui_t *ui_list[MAX_UI_COUNT]; -static qpic_t *ui_mousepointer; +//static qpic_t *ui_mousepointer; +static rtexture_t *ui_mousepointertexture; + +static byte pointerimage[256] = +{ + 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x02, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, + 0x02, 0x06, 0x07, 0x07, 0x07, 0x07, 0x06, 0x01, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, + 0x02, 0x06, 0x05, 0x05, 0x05, 0x04, 0x01, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, + 0x02, 0x06, 0x05, 0x05, 0x04, 0x01, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, + 0x02, 0x06, 0x05, 0x04, 0x05, 0x06, 0x01, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, + 0x02, 0x06, 0x04, 0x01, 0x04, 0x05, 0x06, 0x01, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, + 0x02, 0x05, 0x01, 0xFF, 0x01, 0x04, 0x05, 0x06, 0x01, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, + 0x02, 0x01, 0xFF, 0xFF, 0xFF, 0x01, 0x04, 0x05, 0x06, 0x01, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, + 0x01, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x01, 0x04, 0x01, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x01, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, + 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, +}; void ui_start(void) { - ui_mousepointer = Draw_CachePic("ui/mousepointer.lmp"); +// ui_mousepointer = Draw_CachePic("ui/mousepointer.lmp"); + ui_mousepointertexture = R_LoadTexture("mousepointer", 16, 16, pointerimage, TEXF_ALPHA | TEXF_PRECACHE); ui_mouse_x = vid.width * 0.5; ui_mouse_y = vid.height * 0.5; ui_alive = true; @@ -34,7 +56,8 @@ void ui_start(void) void ui_shutdown(void) { - ui_mousepointer = NULL; +// ui_mousepointer = NULL; + ui_mousepointertexture = NULL; ui_alive = false; } @@ -386,6 +409,7 @@ void ui_draw(void) it = ui_keyrealitem; Draw_AdditivePic(it->draw_x, it->draw_y, it->draw_pic); - Draw_Pic(ui_mouse_x, ui_mouse_y, ui_mousepointer); +// Draw_Pic(ui_mouse_x, ui_mouse_y, ui_mousepointer); + Draw_GenericPic(ui_mousepointertexture, 1, 1, 1, 1, ui_mouse_x, ui_mouse_y, 16, 16); } }