diff --git a/public b/public index 98068b0..13f4a83 160000 --- a/public +++ b/public @@ -1 +1 @@ -Subproject commit 98068b00b2678a8bb98a5979c4192c306af65657 +Subproject commit 13f4a8383c8a53551647118e5252f78a8ef00939 diff --git a/src/channel/Channel.ts b/src/channel/Channel.ts index 54101b8..c0600d1 100644 --- a/src/channel/Channel.ts +++ b/src/channel/Channel.ts @@ -982,6 +982,17 @@ export class Channel extends EventEmitter { if (part.id !== this.crown.participantId) return; } } + + if (this.flags.player_colors) { + if (this.getSetting("color") !== part.color) { + this.changeSettings( + { + color: part.color + }, + true + ); + } + } } const clientMsg: OutgoingSocketEvents["n"] = { @@ -1128,7 +1139,7 @@ export class Channel extends EventEmitter { banner?: string ) { const now = Date.now(); - if (t < 0 || t > 300 * 60 * 1000) return; + if (t < 0 || t > config.maxBanMinutes * 60 * 1000) return; let shouldUpdate = false; diff --git a/src/channel/config.ts b/src/channel/config.ts index a22fffb..ce5d7ae 100644 --- a/src/channel/config.ts +++ b/src/channel/config.ts @@ -11,6 +11,7 @@ interface ChannelConfig { sendLimit: boolean; chownOnRejoin: boolean; channelDestroyTimeout: number; + maxBanMinutes: number; } export const config = ConfigManager.loadConfig( @@ -44,6 +45,7 @@ export const config = ConfigManager.loadConfig( fullChannel: "test/awkward", sendLimit: false, chownOnRejoin: true, - channelDestroyTimeout: 1000 + channelDestroyTimeout: 1000, + maxBanMinutes: 60 } );