Merge pull request #2768 from myk002/myk_textures

add textures used by new gui/control-panel
develop
Myk 2023-02-01 17:49:48 -08:00 committed by GitHub
commit 6513b591bd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 13 additions and 0 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 639 B

@ -1694,6 +1694,7 @@ static const LuaWrapper::FunctionReg dfhack_textures_module[] = {
WRAPM(Textures, getRedPinTexposStart),
WRAPM(Textures, getIconsTexposStart),
WRAPM(Textures, getOnOffTexposStart),
WRAPM(Textures, getControlPanelTexposStart),
WRAPM(Textures, getThinBordersTexposStart),
WRAPM(Textures, getMediumBordersTexposStart),
WRAPM(Textures, getPanelBordersTexposStart),

@ -46,6 +46,11 @@ DFHACK_EXPORT long getIconsTexposStart();
*/
DFHACK_EXPORT long getOnOffTexposStart();
/**
* Get the first texpos for the control panel icons. 10x2 grid.
*/
DFHACK_EXPORT long getControlPanelTexposStart();
/**
* Get the first texpos for the DFHack borders. Each is a 7x3 grid.
*/

@ -23,6 +23,7 @@ static long g_green_pin_texpos_start = -1;
static long g_red_pin_texpos_start = -1;
static long g_icons_texpos_start = -1;
static long g_on_off_texpos_start = -1;
static long g_control_panel_texpos_start = -1;
static long g_thin_borders_texpos_start = -1;
static long g_medium_borders_texpos_start = -1;
static long g_panel_borders_texpos_start = -1;
@ -127,6 +128,8 @@ void Textures::init(color_ostream &out) {
&g_icons_texpos_start);
g_num_dfhack_textures += load_textures(out, "hack/data/art/on-off.png",
&g_on_off_texpos_start);
g_num_dfhack_textures += load_textures(out, "hack/data/art/control-panel.png",
&g_control_panel_texpos_start);
g_num_dfhack_textures += load_textures(out, "hack/data/art/border-thin.png",
&g_thin_borders_texpos_start);
g_num_dfhack_textures += load_textures(out, "hack/data/art/border-medium.png",
@ -187,6 +190,10 @@ long Textures::getOnOffTexposStart() {
return g_on_off_texpos_start;
}
long Textures::getControlPanelTexposStart() {
return g_control_panel_texpos_start;
}
long Textures::getThinBordersTexposStart() {
return g_thin_borders_texpos_start;
}