
Originally Posted by
Callejero
Hello fellow'm trying to add a message to the GS when the shop is relogean, now get the message but not relogea the shop that month would be missing? the code
void ShopManager::Reload()
{
for( int i = 0; i < this->m_ShopList.size(); i++ )
{
this->m_ShopList[i].Init();
this->m_ShopList[i].m_ShopNumber = i;
char FilePath[MAX_PATH] = { 0 };
sprintf(FilePath, "Shop\\Shop%d.xml", i);
MsgBox("Shop Loaded")
return;
if( _access(gDirPath.GetNewPath(FilePath), 4) != -1 )
{
if( this->m_ShopList[i].LoadShopItem(gDirPath.GetNewPath(FilePath)) )
{
this->m_ShopList[i].m_Loaded = true;
}
}
}
}
replace with this
PHP Code:
void ShopManager::Reload()
{
for( int i = 0; i < this->m_ShopList.size(); i++ )
{
this->m_ShopList[i].Init();
this->m_ShopList[i].m_ShopNumber = i;
char FilePath[MAX_PATH] = { 0 };
sprintf(FilePath, "Shop\\Shop%d.xml", i);
if( _access(gDirPath.GetNewPath(FilePath), 4) != -1 )
{
if( this->m_ShopList[i].LoadShopItem(gDirPath.GetNewPath(FilePath)) )
{
this->m_ShopList[i].m_Loaded = true; }
}
}
//reload message
MsgBox("Shop Loaded");
}