Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions conf/conf-example-strict.ini
Original file line number Diff line number Diff line change
Expand Up @@ -72,14 +72,14 @@ OffSet = 3
#---------------------------------------------
# Custom Ban / Kick Messages
# Keywords
# PLAYER_NAME = Player Name
# SERVER_NAME = Server Name
# LOG_FILE = Log File
# DATE_TIME = Date + Time

Ban Message = DATE_TIME: PLAYER_NAME on SERVER_NAME
Kick Message = DATE_TIME: PLAYER_NAME on SERVER_NAME
Report Message = Player Name: PLAYER_NAME, Server: SERVER_NAME, Date: DATE_TIME:, Logfile: LOG_FILE
# $PLAYER_NAME = Player Name
# $SERVER_NAME = Server Name
# $LOG_FILE = Log File
# $DATE_TIME = Date + Time

Ban Message = $DATE_TIME: $PLAYER_NAME on $SERVER_NAME
Kick Message = $DATE_TIME: $PLAYER_NAME on $SERVER_NAME
Report Message = Player Name: $PLAYER_NAME, Server: $SERVER_NAME, Date: $DATE_TIME:, Logfile: $LOG_FILE


[Server 1]
Expand Down
16 changes: 8 additions & 8 deletions conf/conf-example.ini
Original file line number Diff line number Diff line change
Expand Up @@ -73,14 +73,14 @@ OffSet = 3
#---------------------------------------------
# Custom Ban / Kick Messages
# Keywords
# PLAYER_NAME = Player Name
# SERVER_NAME = Server Name
# LOG_FILE = Log File
# DATE_TIME = Date + Time

Ban Message = DATE_TIME: PLAYER_NAME on SERVER_NAME
Kick Message = DATE_TIME: PLAYER_NAME on SERVER_NAME
Report Message = Player Name: PLAYER_NAME, Server: SERVER_NAME, Date: DATE_TIME:, Logfile: LOG_FILE
# $PLAYER_NAME = Player Name
# $SERVER_NAME = Server Name
# $LOG_FILE = Log File
# $DATE_TIME = Date + Time

Ban Message = $DATE_TIME: $PLAYER_NAME on $SERVER_NAME
Kick Message = $DATE_TIME: $PLAYER_NAME on $SERVER_NAME
Report Message = Player Name: $PLAYER_NAME, Server: $SERVER_NAME, Date: $DATE_TIME:, Logfile: $LOG_FILE


[Server 1]
Expand Down
12 changes: 6 additions & 6 deletions modules/bans.py
Original file line number Diff line number Diff line change
Expand Up @@ -146,12 +146,12 @@ def checkBans(self):
self.saveBanInfo()

def formatMessage(self, template, player_name, server_name, log_file, date_time, guid, ip):
tmp = template.replace("LOG_FILE", log_file)
tmp = tmp.replace("DATE_TIME", date_time)
tmp = tmp.replace("SERVER_NAME", server_name)
tmp = tmp.replace("PLAYER_NAME", player_name)
tmp = tmp.replace("GUID", guid)
tmp = tmp.replace("IP", ip)
tmp = template.replace("$LOG_FILE", log_file)
tmp = tmp.replace("$DATE_TIME", date_time)
tmp = tmp.replace("$SERVER_NAME", server_name)
tmp = tmp.replace("$PLAYER_NAME", player_name)
tmp = tmp.replace("$GUID", guid)
tmp = tmp.replace("$IP", ip)
return tmp

def addBan(self, unique_id, info, logname, ban_template, report_template, time): #{ID,Reason}
Expand Down
8 changes: 4 additions & 4 deletions modules/logs_battleye.py
Original file line number Diff line number Diff line change
Expand Up @@ -170,10 +170,10 @@ def scan_battleye_logs(self, x):
sys.exit()

def kick_ban_msg(self, template, player_name, server_name, log_file, date_time):
tmp = string.replace(template, "PLAYER_NAME", player_name)
tmp = string.replace(tmp, "SERVER_NAME", server_name)
tmp = string.replace(tmp, "LOG_FILE", log_file)
tmp = string.replace(tmp, "DATE_TIME", date_time)
tmp = string.replace(template, "$PLAYER_NAME", player_name)
tmp = string.replace(tmp, "$SERVER_NAME", server_name)
tmp = string.replace(tmp, "$LOG_FILE", log_file)
tmp = string.replace(tmp, "$DATE_TIME", date_time)
return tmp

def update_bans(self, logname, data, time="-1", update=False):
Expand Down