- Joined
- Jun 21, 2008
- Messages
- 95
- Reaction score
- 3
I don't know if this has been released before, but i'm gonna release it anyways 
Remember to backup your files before doing this.
Run this query in MySQL:
Go to CommandProcessor.java
Find:
Under it add
Find:
Under it add
Now go to where it says
Look for
Replace it with
Now directly under it, add:
Recompile, and player commands such as @exp, @rebirth, @str, etc should be in playerlog instead of GM log! (hopefully, if you did it right)
Credits to myself and whoever coded this first if anyone did.
NOTE: I am not held responsible if this code is faulty or if you screw up. It works on my server. o_o

Remember to backup your files before doing this.
Run this query in MySQL:
Code:
DROP TABLE IF EXISTS `odinms`.`playerlog`;
CREATE TABLE `odinms`.`playerlog` (
`id` int(11) NOT NULL auto_increment,
`cid` int(11) NOT NULL default '0',
`command` tinytext NOT NULL,
`when` timestamp NOT NULL default CURRENT_TIMESTAMP,
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=1562 DEFAULT CHARSET=latin1;
Go to CommandProcessor.java
Find:
Code:
private static List<Pair<MapleCharacter,String>> gmlog = new LinkedList<Pair<MapleCharacter,String>>();
Under it add
Code:
private static List<Pair<MapleCharacter,String>> playerlog = new LinkedList<Pair<MapleCharacter,String>>();
Find:
Code:
gmlog.clear();
Under it add
Code:
synchronized (playerlog) {
Connection con = DatabaseConnection.getConnection();
try {
PreparedStatement ps = con.prepareStatement("INSERT INTO playerlog (cid, command) VALUES (?, ?)");
for (Pair<MapleCharacter,String> logentry : playerlog) {
ps.setInt(1, logentry.getLeft().getId());
ps.setString(2, logentry.getRight());
ps.executeUpdate();
}
ps.close();
} catch (SQLException e) {
log.error("error persisting cheatlog", e);
}
playerlog.clear();
}
Now go to where it says
Code:
if (line.charAt(0) == '!' && isGM || line.charAt(0) =='@') {
Look for
Code:
synchronized (gmlog) {
gmlog.add(new Pair<MapleCharacter, String>(player, line));
}
Code:
if (line.charAt(0) == '!' && isGM) {
synchronized (gmlog) {
gmlog.add(new Pair<MapleCharacter, String>(player, line));
}
}
Now directly under it, add:
Code:
if (line.charAt(0) =='@') {
synchronized (playerlog) {
playerlog.add(new Pair<MapleCharacter, String>(player, line));
}
}
Recompile, and player commands such as @exp, @rebirth, @str, etc should be in playerlog instead of GM log! (hopefully, if you did it right)
Credits to myself and whoever coded this first if anyone did.
NOTE: I am not held responsible if this code is faulty or if you screw up. It works on my server. o_o