class:
int CShop::Buy(LPCHARACTER ch, BYTE pos)
I want to print this way.but it does not and gives the core.
time_t rawtime;
struct tm *info;
char buffer[80];
time( &rawtime );
info = localtime( &rawtime );
strftime(buffer,80,"%x - %I:%M%p", info);
char szQuery[512];
snprintf(szQuery, sizeof(szQuery), "INSERT INTO log.log_kulfe VALUES((SELECT id FROM player.player WHERE name = '%s'),'%s','%s','%d','%d',NOW())", ch->GetName(),item->GetVnum(),item->GetName(), dwPrice,item->GetCount());
SQLMsg *msg = DBManager::instance().DirectQuery(szQuery);
game.core
in CShop::Buy (this=0x2a298830, ch=0x37a41800, pos=20 '\024')
at shop.cpp:839
#4 0x0829a570 in CShopManager::Buy (this=0xbfcfa990, ch=0x37a41800,
pos=20 '\024') at shop_manager.cpp:420
Thank you in advance.