Fixed wrong icon frame with arrow used in kart list
This commit is contained in:
parent
f47b410d92
commit
b2c741a4b5
@ -102,11 +102,17 @@ RaceGUIBase::RaceGUIBase()
|
||||
{
|
||||
m_icons_frame = irr_driver->getTexture("icons-frame.png");
|
||||
}
|
||||
m_icons_kart_list = irr_driver->getTexture("icons-frame.png");
|
||||
if (!m_icons_frame)
|
||||
{
|
||||
Log::error("RaceGuiBase",
|
||||
"Can't find 'icons-frame.png' texture, aborting.");
|
||||
}
|
||||
if (!m_icons_kart_list)
|
||||
{
|
||||
Log::error("RaceGuiBase",
|
||||
"Can't find 'icons-frame.png' texture, aborting.");
|
||||
}
|
||||
|
||||
m_gauge_full = irr_driver->getTexture(FileManager::GUI_ICON, "gauge_full.png");
|
||||
m_gauge_full_bright = irr_driver->getTexture(FileManager::GUI_ICON, "gauge_full_bright.png");
|
||||
@ -1036,7 +1042,7 @@ void RaceGUIBase::drawPlayerIcon(AbstractKart *kart, int x, int y, int w,
|
||||
const core::rect<s32> pos(x, y, x+w, y+w);
|
||||
|
||||
//to bring to light the player's icon: add a background
|
||||
if (is_local && m_icons_frame != NULL)
|
||||
if (is_local && m_icons_kart_list != NULL)
|
||||
{
|
||||
video::SColor colors[4];
|
||||
for (unsigned int i=0;i<4;i++)
|
||||
@ -1046,8 +1052,8 @@ void RaceGUIBase::drawPlayerIcon(AbstractKart *kart, int x, int y, int w,
|
||||
100+(int)(100*cosf(M_PI/2*i+World::getWorld()->getTime()*2)));
|
||||
}
|
||||
const core::rect<s32> rect(core::position2d<s32>(0,0),
|
||||
m_icons_frame->getSize());
|
||||
draw2DImage(m_icons_frame, pos, rect,NULL, colors, true);
|
||||
m_icons_kart_list->getSize());
|
||||
draw2DImage(m_icons_kart_list, pos, rect,NULL, colors, true);
|
||||
}
|
||||
|
||||
// Fixes crash bug, why are certain icons not showing up?
|
||||
|
@ -190,6 +190,9 @@ protected:
|
||||
/** The frame around player karts in the mini map. */
|
||||
video::ITexture* m_icons_frame;
|
||||
|
||||
/** The frame around player karts in the kart list. */
|
||||
video::ITexture* m_icons_kart_list;
|
||||
|
||||
/** Texture for the lap icon*/
|
||||
video::ITexture* m_lap_flag;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user