My version...
Log.h (search for "DragonSlayLog" and add below)
Log.cpp (search for "DragonSlayLog" and add after that void)
C
- void LogManager::PlayerEchange(const char* owner, const char* victim, const char* item, DWORD yang, DWORD map_index)
- {
- Query("INSERT INTO player_echange%s (owner, victim, item, yang, map_index, date) VALUES('%s', '%s', '%s', %u, %d, NOW())", get_table_postfix(), owner, victim, item, yang, map_index);
- }
exchange.cpp (search for this)
Add below
Search for this
Add below
Create a table in Log
SQL
- DROP TABLE IF EXISTS `player_echange`;
- CREATE TABLE `player_echange` (
- `id` int(11) NOT NULL AUTO_INCREMENT,
- `owner` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL,
- `victim` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL,
- `item` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL,
- `yang` int(11) NOT NULL DEFAULT 0,
- `map_index` int(11) NOT NULL DEFAULT 0,
- `date` datetime(0) NULL,
- PRIMARY KEY (`id`) USING BTREE,
- UNIQUE INDEX `id`(`id`) USING BTREE
- ) ENGINE = InnoDB AUTO_INCREMENT = 10 CHARACTER SET = utf8 COLLATE = utf8_general_ci ROW_FORMAT = Dynamic;
Best regards, nikita322