strutZ
Australian OT Member {AKA Beastn}
- Joined
- Nov 16, 2014
- Messages
- 1,393
- Solutions
- 7
- Reaction score
- 552
Title proberly makes no sense... basically i am changing the player report bug function in tfs 1.2. i want it to get the date and insert it into my database.
Here is what i got.
Here is what i got.
Code:
void Game::playerReportBug(uint32_t playerId, const std::string& message, const Position position, uint8_t category)
{
Database* db = Database::getInstance();
std::ostringstream query;
query << "INSERT INTO `reports` (`player`, `mappos`, `playerpos`, `comment`) VALUES (" << player->getName() << ',' << position << ',' << player->getPosition() << ',' << db->escapeString(comment) << ')';
db->executeQuery(query.str());
}