- Mesaj
- 55
- Çözümler
- 1
- Beğeni
- 12
- Puan
- 439
- Ticaret Puanı
- 0
ALdığım Hata:
Shop_manager.cpp:821:96: error: no matching function for call to 'LogManager::ShopLog(DWORD&, DWORD&, const char [22], DWORD&)'
LogManager::instance().ShopLog(dwOwnerID, dwItemID, "%u is buying the item", dwBuyerID);
^
In file included from Shop_manager.cpp:25:
log.h:80:8: note: candidate: 'void LogManager::ShopLog(DWORD, DWORD, DWORD)'
void ShopLog(DWORD dwOwnerID, DWORD dwItemID, DWORD dwBuyerID);
^~~~~~~~~~~~~~
log.h:80:8: note: candidate expects 3 arguments, 4 provided
Aşağıdaki "%u is buying the item" için nasıl argüman eklemem lazim log.cpp ve log.h için ?
shop_manager.cpp:
LogManager::instance().ShopLog(dwOwnerID, dwItemID, "%u is buying the item", dwBuyerID);
Log.cpp:
void LogManager::ShopLog(DWORD dwOwnerID, DWORD dwItemID, DWORD dwBuyerID)
{
Query("INSERT INTO Shop_log (owner , itemid , buyer ) VALUES (%s', '%s', '%s')", dwOwnerID, dwItemID, dwBuyerID);
}
log.h:
void ShopLog(DWORD dwOwnerID, DWORD dwItemID, DWORD dwBuyerID);