function CharacterRealism.Start(r)assert(not _G.DefineRealismClient,"\082\101\097\108\105\115\109 \099\097\110 \111\110\108\121 \098\101 \115\116\097\114\116\101\100 \111\110\099\101 \111\110 \116\104\101 \099\108\105\101\110\116\033")_G.DefineRealismClient=true for f,a in pairs(Config)do r[f]=a end for f,a in pairs(CollectionService:GetTagged(r.BindTag))do r:OnHumanoidAdded(a)end r:Connect("\085\112\100\097\116\101\076\111\111\107\065\110\103\108\101\115",RunService.Heartbeat)r:Connect("\079\110\076\111\111\107\082\101\099\101\105\118\101",r.SetLookAngles.OnClientEvent)r:Connect("\079\110\072\117\109\097\110\111\105\100\065\100\100\101\100",CollectionService:GetInstanceAddedSignal(r.BindTag))FpsCamera:Start()end if script:IsA("\077\111\100\117\108\101\083\099\114\105\112\116")then return CharacterRealism else assert(script:FindFirstAncestorOfClass("\080\108\097\121\101\114\083\099\114\105\112\116\115"),"\082\101\097\108\105\115\109\067\108\105\101\110\116 \109\117\115\116 \098\101 \097 \100\101\115\099\101\110\100\097\110\116 \111\102 \116\104\101 \080\108\097\121\101\114\083\099\114\105\112\116\115\033")assert(Players.LocalPlayer,"\082\101\097\108\105\115\109\067\108\105\101\110\116 \101\120\112\101\099\116\115 \097 \080\108\097\121\101\114 \111\110 \116\104\101 \099\108\105\101\110\116 \116\111 \097\117\116\111\109\097\116\105\099\097\108\108\121 \115\116\097\114\116 \101\120\101\099\117\116\105\111\110\033")CharacterRealism:Start()end


function CharacterRealism:Start()
	assert(not _G.DefineRealismClient, "Realism can only be started once on the client!")
	_G.DefineRealismClient = true
	
	for key, value in pairs(Config) do
		self[key] = value
	end
	
	for _,humanoid in pairs(CollectionService:GetTagged(self.BindTag)) do
		self:OnHumanoidAdded(humanoid)
	end
	
	self:Connect("UpdateLookAngles", RunService.Heartbeat)
	self:Connect("OnLookReceive", self.SetLookAngles.OnClientEvent)
	self:Connect("OnHumanoidAdded", CollectionService:GetInstanceAddedSignal(self.BindTag))
	
	FpsCamera:Start()
end

if script:IsA("ModuleScript") then
	-- Return the system as a module table.
	return CharacterRealism
else
	-- Sanity check
	assert(script:FindFirstAncestorOfClass("PlayerScripts"), "RealismClient must be a descendant of the PlayerScripts!")
	assert(Players.LocalPlayer, "RealismClient expects a Player on the client to automatically start execution!")	
	
	-- Start automatically.
	CharacterRealism:Start()
end
