Core/Channels: Revamp of channel system

* Core/Chat: general cleanup and revamping: (#17576) (fbbb03212e)
* Core/Channel: restore accidentally deleted line, fixes channels not honoring ownership setting (7c71417993)
* Channel Followup: avoid setting an invisible gm as Channel owner (#17597) (8a8362ef15)
* Core/Channel: change the way channels are stored and sent to client, fixes multiple channels per zone when using different locales (#17980)
This commit is contained in:
ariel-
2016-10-03 06:06:33 -03:00
parent 4b5e5bbd72
commit 59a9bc5ca0
14 changed files with 1328 additions and 801 deletions

View File

@@ -271,7 +271,7 @@ void CharacterDatabaseConnection::DoPrepareStatements()
" ON DUPLICATE KEY UPDATE LogGuid = VALUES (LogGuid), EventType = VALUES (EventType), PlayerGuid = VALUES (PlayerGuid), Flags = VALUES (Flags), Value = VALUES (Value), Timestamp = VALUES (Timestamp)", CONNECTION_ASYNC);
// Chat channel handling
PrepareStatement(CHAR_SEL_CHANNEL, "SELECT announce, ownership, password, bannedList FROM channels WHERE name = ? AND team = ?", CONNECTION_SYNCH);
PrepareStatement(CHAR_SEL_CHANNEL, "SELECT name, announce, ownership, password, bannedList FROM channels WHERE name = ? AND team = ?", CONNECTION_SYNCH);
PrepareStatement(CHAR_INS_CHANNEL, "INSERT INTO channels(name, team, lastUsed) VALUES (?, ?, UNIX_TIMESTAMP())", CONNECTION_ASYNC);
PrepareStatement(CHAR_UPD_CHANNEL, "UPDATE channels SET announce = ?, ownership = ?, password = ?, bannedList = ?, lastUsed = UNIX_TIMESTAMP() WHERE name = ? AND team = ?", CONNECTION_ASYNC);
PrepareStatement(CHAR_UPD_CHANNEL_USAGE, "UPDATE channels SET lastUsed = UNIX_TIMESTAMP() WHERE name = ? AND team = ?", CONNECTION_ASYNC);