local z=(script:FindFirstAncestor("\067\109\100\114\065\100\100\105\116\105\111\110\115")).Packages local A=script:FindFirstAncestor("\085\073")local Y=require(z.Roact)local m=require(A.CmdrContext)local W=require(script.EventController)local a=require(script.EventTypes)local H=Y.Component:extend("\069\118\101\110\116\077\097\110\097\103\101\114")function H.render(z)return Y.createElement(m.Consumer,{render=function(z)local A={}for m,a in pairs(a)do A[m]=Y.createElement(W,{Component=a,ListenTo=a.listenTo,MaxQuantity=a.maxQuantity;Cmdr=z})end return Y.createFragment(A)end})end return H
local Packages = script:FindFirstAncestor("CmdrAdditions").Packages
local UI = script:FindFirstAncestor("UI")

local Roact = require(Packages.Roact)

local CmdrContext = require(UI.CmdrContext)

local EventController = require(script.EventController)
local EventTypes = require(script.EventTypes)

local EventManager = Roact.Component:extend("EventManager")

function EventManager:render()
	return Roact.createElement(CmdrContext.Consumer, {
		render = function(cmdr)
			local eventControllers = {}

			for eventType, component in pairs(EventTypes) do
				eventControllers[eventType] = Roact.createElement(EventController, {
					Component = component,
					ListenTo = component.listenTo,
					MaxQuantity = component.maxQuantity,
					Cmdr = cmdr
				})
			end

			return Roact.createFragment(eventControllers)
		end
	})
end

return EventManager