function module.new(F,u)local A=setmetatable({},methods)A.ChatService=F A.PlayerObj=nil A.Name=u A.ExtraData={}A.Channels={}A.MutedSpeakers={}A.eDestroyed=Instance.new("\066\105\110\100\097\098\108\101\069\118\101\110\116")A.eSaidMessage=Instance.new("\066\105\110\100\097\098\108\101\069\118\101\110\116")A.eReceivedMessage=Instance.new("\066\105\110\100\097\098\108\101\069\118\101\110\116")A.eReceivedUnfilteredMessage=Instance.new("\066\105\110\100\097\098\108\101\069\118\101\110\116")A.eMessageDoneFiltering=Instance.new("\066\105\110\100\097\098\108\101\069\118\101\110\116")A.eReceivedSystemMessage=Instance.new("\066\105\110\100\097\098\108\101\069\118\101\110\116")A.eChannelJoined=Instance.new("\066\105\110\100\097\098\108\101\069\118\101\110\116")A.eChannelLeft=Instance.new("\066\105\110\100\097\098\108\101\069\118\101\110\116")A.eMuted=Instance.new("\066\105\110\100\097\098\108\101\069\118\101\110\116")A.eUnmuted=Instance.new("\066\105\110\100\097\098\108\101\069\118\101\110\116")A.eExtraDataUpdated=Instance.new("\066\105\110\100\097\098\108\101\069\118\101\110\116")A.eMainChannelSet=Instance.new("\066\105\110\100\097\098\108\101\069\118\101\110\116")A.eChannelNameColorUpdated=Instance.new("\066\105\110\100\097\098\108\101\069\118\101\110\116")A.Destroyed=A.eDestroyed.Event A.SaidMessage=A.eSaidMessage.Event A.ReceivedMessage=A.eReceivedMessage.Event A.ReceivedUnfilteredMessage=A.eReceivedUnfilteredMessage.Event A.MessageDoneFiltering=A.eMessageDoneFiltering.Event A.ReceivedSystemMessage=A.eReceivedSystemMessage.Event A.ChannelJoined=A.eChannelJoined.Event A.ChannelLeft=A.eChannelLeft.Event A.Muted=A.eMuted.Event A.Unmuted=A.eUnmuted.Event A.ExtraDataUpdated=A.eExtraDataUpdated.Event A.MainChannelSet=A.eMainChannelSet.Event A.ChannelNameColorUpdated=A.eChannelNameColorUpdated.Event A.RecievedUnfilteredMessage=A.eReceivedUnfilteredMessage.Event return A end return module
--///////////////////////// Constructors
--//////////////////////////////////////

function module.new(vChatService, name)
	local obj = setmetatable({}, methods)

	obj.ChatService = vChatService

	obj.PlayerObj = nil

	obj.Name = name
	obj.ExtraData = {}

	obj.Channels = {}
	obj.MutedSpeakers = {}

	-- Make sure to destroy added binadable events in the InternalDestroy method.
	obj.eDestroyed = Instance.new("BindableEvent")
	obj.eSaidMessage = Instance.new("BindableEvent")
	obj.eReceivedMessage = Instance.new("BindableEvent")
	obj.eReceivedUnfilteredMessage = Instance.new("BindableEvent")
	obj.eMessageDoneFiltering = Instance.new("BindableEvent")
	obj.eReceivedSystemMessage = Instance.new("BindableEvent")
	obj.eChannelJoined = Instance.new("BindableEvent")
	obj.eChannelLeft = Instance.new("BindableEvent")
	obj.eMuted = Instance.new("BindableEvent")
	obj.eUnmuted = Instance.new("BindableEvent")
	obj.eExtraDataUpdated = Instance.new("BindableEvent")
	obj.eMainChannelSet = Instance.new("BindableEvent")
	obj.eChannelNameColorUpdated = Instance.new("BindableEvent")

	obj.Destroyed = obj.eDestroyed.Event
	obj.SaidMessage = obj.eSaidMessage.Event
	obj.ReceivedMessage = obj.eReceivedMessage.Event
	obj.ReceivedUnfilteredMessage = obj.eReceivedUnfilteredMessage.Event
	obj.MessageDoneFiltering = obj.eMessageDoneFiltering.Event
	obj.ReceivedSystemMessage = obj.eReceivedSystemMessage.Event
	obj.ChannelJoined = obj.eChannelJoined.Event
	obj.ChannelLeft = obj.eChannelLeft.Event
	obj.Muted = obj.eMuted.Event
	obj.Unmuted = obj.eUnmuted.Event
	obj.ExtraDataUpdated = obj.eExtraDataUpdated.Event
	obj.MainChannelSet = obj.eMainChannelSet.Event
	obj.ChannelNameColorUpdated = obj.eChannelNameColorUpdated.Event

	--- DEPRECATED:
	--- Mispelled version of ReceivedUnfilteredMessage, retained for compatibility with legacy versions.
	obj.RecievedUnfilteredMessage = obj.eReceivedUnfilteredMessage.Event

	return obj
end

return module
