RoboCatz.com
About FLL | Navigation | Playbook | Strategy | Models | Techniques | RobotC | Programming | Robot News |

-- studentExhibition ModuleScript in the ReplicatedStorage area

--[[
Updated: 5/27/2023

This module is: studentExhibition and is stored in the ReplicatedStorage area

This module will create the artwork and animations used for the art installations
These exhibits will be stored in an array in the baseplateScript

]]
local StudentExhibition = {}
local ReplicatedStorage = game:GetService("ReplicatedStorage")
local s = require(ReplicatedStorage.genericShapes)
local b = require(ReplicatedStorage.artInstallationRoom)

function StudentExhibition.newQbert(x, z)
	local exhibitRoom = { room=b.new({x=x, z=z}), name="newQbert", parts={}, onInteraction=nil }
	exhibitRoom.draw = function() 
		for i=1,5 do
			exhibitRoom.parts[i] = s.panel({x=i*3-15,y=i,z=-25, thickness=1, color=Color3.new(math.random()*90,math.random()*90,math.random()*90), rotateby=Vector3.new(0,90,0), material=Enum.Material.Foil})
		end
		local s1 = s.sphere({x=0, y=20, z=-45, color="green", material=Enum.Material.Foil, size=40})
		local c1 = s.cube({x=0, y=20, z=-45, color="red", material=Enum.Material.Foil, size=36, opacity=0.5})
		local negativeSpace = s.subtract(c1, s1)
		exhibitRoom.parts[#exhibitRoom.parts+1] = negativeSpace
	end
	exhibitRoom.onInteraction = function(thePart)
		local touchingPartsTable = thePart:GetTouchingParts()
		for i=1,#touchingPartsTable do
			s.fill(touchingPartsTable[i], Color3.new(0, 0.34902, 1))
			s.material(touchingPartsTable[i], Enum.Material.Wood)
		end
	end
	exhibitRoom.defineInteractions = function()
		for i=1,#exhibitRoom.parts do exhibitRoom.parts[i].Touched:Connect(exhibitRoom.onInteraction) end
	end
	exhibitRoom.animate = function(...) 
		for i=1,#exhibitRoom.parts do
			--s.fill(exhibitRoom.parts[i], Color3.new(math.random(),math.random(),math.random()))
		end
	end
	return exhibitRoom
end


function StudentExhibition.newXpert(x, z)
	local exhibitRoom = { room=b.new({x=x, z=z}), name="newXpert", parts={}, onInteraction=nil }
	exhibitRoom.draw = function()
		for i=1,15 do
			local size = 3 + math.random(1,10)/10

			exhibitRoom.parts[#exhibitRoom.parts+1] = s.cube({ anchored=false, x=math.random()*80-40, y=size/2+math.random(2,6), z=math.random()*75-85, size=size, color=Color3.new(math.random(),math.random(),math.random()), material=Enum.Material.Foil, rotateBy=Vector3.new(math.random(0,90),math.random(0,90),math.random(0,90))})
			exhibitRoom.parts[#exhibitRoom.parts+1] = s.sphere({ anchored=false, x=math.random()*80-40, y=size/2+math.random(2,6), z=math.random()*75-85, size=size, color=Color3.new(math.random(),math.random(),math.random()), material=Enum.Material.Glass })
			exhibitRoom.parts[#exhibitRoom.parts+1] = s.square({ anchored=false, x=math.random()*80-40, y=size/2+math.random(2,6), z=math.random()*75-85, size=size, color=Color3.new(math.random(),math.random(),math.random()), material=Enum.Material.Glass, rotateBy=Vector3.new(math.random(0,90),math.random(0,90),math.random(0,90))})
			exhibitRoom.parts[#exhibitRoom.parts+1] = s.circle({ anchored=false, x=math.random()*80-40, y=size/2+math.random(2,6), z=math.random()*75-85, size=size, color=Color3.new(math.random(),math.random(),math.random()), material=Enum.Material.Glass, rotateBy=Vector3.new(math.random(0,90),math.random(0,90),math.random(0,90))})
			exhibitRoom.parts[#exhibitRoom.parts+1] = s.panel({ anchored=false, x=math.random()*80-40, y=size/2+math.random(2,6), z=math.random()*75-85, width=size*0.75, height=size*1.5, thickness=0.5, color=Color3.new(math.random(),math.random(),math.random()), material=Enum.Material.Glass, rotateBy=Vector3.new(math.random(0,90),math.random(0,90),math.random(0,90))})
		end

	end
	exhibitRoom.onInteraction = function(thePart)
	end
	exhibitRoom.defineInteractions = function()
		for i=1,#exhibitRoom.parts do exhibitRoom.parts[i].Touched:Connect(exhibitRoom.onInteraction) end
	end
	exhibitRoom.animate = function(...)
		local targetModulus=math.random(0,9)
		for i=1,#exhibitRoom.parts do
			if(i%targetModulus==0) then s.fill(exhibitRoom.parts[i], Color3.new(math.random(),math.random(),math.random())) end
		end
		wait(0.5)
	end
	return exhibitRoom
end


function StudentExhibition.newOvert(x, z)
	local exhibitRoom = { room=b.new({x=x, z=z}), name="newOvert", parts={}, onInteraction=nil }
	exhibitRoom.draw = function()
		for i=1,15 do
			exhibitRoom.parts[#exhibitRoom.parts+1] = s.cube(math.random()*80-40, 5, math.random()*75-85, "orange", Enum.Material.Foil)
			exhibitRoom.parts[#exhibitRoom.parts+1] = s.sphere(math.random()*80-40, 5, math.random()*75-85, 10, "orange", Enum.Material.Glass)
		end
	end
	exhibitRoom.onInteraction = function(thePart)
		local touchingPartsTable = thePart:GetTouchingParts()
		for i=1,#touchingPartsTable do
			s.fill(touchingPartsTable[i], Color3.new(0.6, 0.6, 0.6 + math.random(0,40)/100))
			s.material(touchingPartsTable[i], Enum.Material.Wood)
		end
	end
	exhibitRoom.defineInteractions = function()
		for i=1,#exhibitRoom.parts do exhibitRoom.parts[i].Touched:Connect(exhibitRoom.onInteraction) end
	end
	exhibitRoom.animate = function(...) 
		--s.fill(exhibitRoom.parts[1], Color3.new(math.random(),math.random(),math.random()))
		--s.fill(exhibitRoom.parts[2], Color3.new(math.random(),math.random(),math.random()))
	end
	return exhibitRoom
end


-- FROM MH
function StudentExhibition.newMatti(x, z)
	local exhibitRoom = { room=b.new({x=x, z=z}), name="newMatti", parts={}, onInteraction=nil }
	exhibitRoom.draw = function()
		for i=1,100 do
			exhibitRoom.parts[i] = s.panel({x=-0,y=15,z=-35, color=Color3.new(0.603922, 0.14902, 1),rotateby=Vector3.new(0,90,0), material=Enum.Material.Foil})
		end
		exhibitRoom.parts[#exhibitRoom.parts+1] = s.panel({x=-0,y=15,z=-30, color=Color3.new(0.603922, 0.14902, 1),rotateby=Vector3.new(0,90,0), material=Enum.Material.Foil})
		exhibitRoom.parts[#exhibitRoom.parts+1] = s.panel({x=-0,y=10,z=-25, color=Color3.new(1, 0.6, 0.109804),rotateby=Vector3.new(0,90,0), material=Enum.Material.Neon})   -- Neon
		exhibitRoom.parts[#exhibitRoom.parts+1] = s.panel({x=-0,y=5,z=-20, color=Color3.new(1, 0.6, 0.109804),rotateby=Vector3.new(0,90,0), material=Enum.Material.Water})
		--	local m1=s.union(exhibitRoom.parts[1],{exhibitRoom.parts[2],exhibitRoom.parts[3]})
		--s.material(m1,Enum.Material.Neon)
		--exhibitRoom.parts[1]=m1
	end
	exhibitRoom.onInteraction = function(thePart)
		local touchingPartsTable = thePart:GetTouchingParts()
		for i=1,#touchingPartsTable do
			print(`Touching Part {i}`)
			s.fill(touchingPartsTable[i], Color3.new(0, 0.34902, 1))
			s.material(touchingPartsTable[i], Enum.Material.Wood)
		end
	end
	exhibitRoom.defineInteractions = function()
		for i=1,#exhibitRoom.parts do exhibitRoom.parts[i].Touched:Connect(exhibitRoom.onInteraction) end
	end
	exhibitRoom.animate = function()
		for i=1,#exhibitRoom.parts do
			s.fill(exhibitRoom.parts[i],Color3.new(math.random()*90,math.random()*90,math.random()*90))
		end
	end
	return exhibitRoom
end

-- FROM MH
function StudentExhibition.newMyArt1(x, z)
	local exhibitRoom = { room=b.new({x=x, z=z}), name="newMyArt1", parts={}, onInteraction=nil }
	exhibitRoom.draw = function()
		for i=1,50 do
			exhibitRoom.parts[i] = s.cube({x=math.random()*x-x/2, y=math.random()*30+6, z=math.random()*z-z-15, color="red", material=Enum.Material.Foil})
		end
		exhibitRoom.parts[#exhibitRoom.parts+1] = s.sphere({position=exhibitRoom.room.center, color="red", material=Enum.Material.Foil})
		exhibitRoom.parts[#exhibitRoom.parts+1] = s.sphere(-10, 5, -30, 8, "red", Enum.Material.Glass)
	end
	exhibitRoom.onInteraction = function(thePart)
		local touchingPartsTable = thePart:GetTouchingParts()
		for i=1,#touchingPartsTable do
			s.fill(touchingPartsTable[i], Color3.new(0, 0.34902, 1))
			s.material(touchingPartsTable[i], Enum.Material.Wood)
			s.resizeBy(touchingPartsTable[i], Vector3.new(-1, 0, -1))
		end
	end
	exhibitRoom.defineInteractions = function()
		for i=1,#exhibitRoom.parts do exhibitRoom.parts[i].Touched:Connect(exhibitRoom.onInteraction) end
	end
	exhibitRoom.animate = function(...) 
		for i=1,#exhibitRoom.parts do
			s.fill(exhibitRoom.parts[i], Color3.new(math.random(),math.random(),math.random()))
		end
		wait(0.5)
	end
	return exhibitRoom
end

-- FROM MH
function StudentExhibition.bob(x, z)
	local exhibitRoom = { room=b.new({x=x, z=z}), name="bob", parts={}, onInteraction=nil }
	exhibitRoom.draw = function()
		for i=1,100 do
			exhibitRoom.parts[i] = s.sphere({x=math.random()*x-x/2, y=math.random()*30, z=math.random()*z-z-15, color="red", material=Enum.Material.Neon})
		end
		exhibitRoom.parts[#exhibitRoom.parts+1] = s.sphere({position=exhibitRoom.room.center, color="red", material=Enum.Material.Foil})
		exhibitRoom.parts[#exhibitRoom.parts+1] = s.sphere(-10, 5, -30, 8, "red", Enum.Material.Glass)
	end
	exhibitRoom.onInteraction = function(thePart)
		local touchingPartsTable = thePart:GetTouchingParts()
		for i=1,#touchingPartsTable do
			s.fill(touchingPartsTable[i], Color3.new(0, 0.34902, 1))
			s.material(touchingPartsTable[i], Enum.Material.Wood)
			s.resizeBy(touchingPartsTable[i], Vector3.new(-1, 0, -1))
		end
	end
	exhibitRoom.defineInteractions = function()
		for i=1,#exhibitRoom.parts do exhibitRoom.parts[i].Touched:Connect(exhibitRoom.onInteraction) end
	end
	exhibitRoom.animate = function(...) 
		for i=1,#exhibitRoom.parts do
			s.fill(exhibitRoom.parts[i], Color3.new(math.random(),math.random(),math.random()))
		end
	end
	return exhibitRoom
end

-- FROM MH
function StudentExhibition.mati(x, z)
	local exhibitRoom = { room=b.new({x=x, z=z}), name="mati", parts={}, onInteraction=nil }
	exhibitRoom.draw = function()
		for i=1,100 do
			--	exhibitRoom.parts[i] = s.sphere({x=math.random()*x-x/2, y=math.random()*30, z=math.random()*z-z-15, color="red", material=Enum.Material.Neon})
		end
		exhibitRoom.parts[#exhibitRoom.parts+1] = s.square({x=-10,y=10,z=-35, color=Color3.new(0.603922, 0.14902, 1),rotateby=Vector3.new(0,90,0), material=Enum.Material.Foil})
		exhibitRoom.parts[#exhibitRoom.parts+1] = s.square(-10, 5, -30, 8, "red", Enum.Material.Glass)
		exhibitRoom.parts[#exhibitRoom.parts+1] = s.square({x=-5,y=5,z=-35, color=Color3.new(1, 0.6, 0.109804),rotateby=Vector3.new(0,0,90), material=Enum.Material.Neon})
		--	local m1=s.union(exhibitRoom.parts[1],{exhibitRoom.parts[2],exhibitRoom.parts[3]})
		--s.material(m1,Enum.Material.Neon)
		--exhibitRoom.parts[1]=m1
	end
	exhibitRoom.onInteraction = function(thePart)
		local touchingPartsTable = thePart:GetTouchingParts()
		for i=1,#touchingPartsTable do
			s.fill(touchingPartsTable[i], Color3.new(0, 0.34902, 1))
			s.material(touchingPartsTable[i], Enum.Material.Wood)
		end
	end
	exhibitRoom.defineInteractions = function()
		for i=1,#exhibitRoom.parts do exhibitRoom.parts[i].Touched:Connect(exhibitRoom.onInteraction) end
	end
	exhibitRoom.animate = function(...)
		for i=1,#exhibitRoom.parts do
			s.rotate(exhibitRoom.parts[i],Vector3.new(math.random()*90,math.random()*90,math.random()*90))
		end
	end
	return exhibitRoom
end

-- FROM MH
function StudentExhibition.tomato(x, z)
	local exhibitRoom = { room=b.new({x=x, z=z}), name="tomato", parts={}, onInteraction=nil }
	exhibitRoom.draw = function()
		for i=1,100 do
			--	exhibitRoom.parts[i] = s.sphere({x=math.random()*x-x/2, y=math.random()*30, z=math.random()*z-z-15, color="red", material=Enum.Material.Neon})
		end
		exhibitRoom.parts[#exhibitRoom.parts+1] = s.panel({x=-10,y=10,z=-35, color=Color3.new(0.603922, 0.14902, 1),rotateby=Vector3.new(0,90,0), material=Enum.Material.Foil})
		exhibitRoom.parts[#exhibitRoom.parts+1] = s.panel(-10, 5, -30, 8, "red", Enum.Material.Glass)
		exhibitRoom.parts[#exhibitRoom.parts+1] = s.panel({x=-5,y=5,z=-35, color=Color3.new(1, 0.6, 0.109804),rotateby=Vector3.new(0,0,90), material=Enum.Material.Neon})
		--	local m1=s.union(exhibitRoom.parts[1],{exhibitRoom.parts[2],exhibitRoom.parts[3]})
		--s.material(m1,Enum.Material.Neon)
		--exhibitRoom.parts[1]=m1
	end
	exhibitRoom.onInteraction = function(thePart)
		local touchingPartsTable = thePart:GetTouchingParts()
		for i=1,#touchingPartsTable do
			s.fill(touchingPartsTable[i], Color3.new(0, 0.34902, 1))
			s.material(touchingPartsTable[i], Enum.Material.Wood)
			s.resizeBy(touchingPartsTable[i], Vector3.new(-1, 0, -1))
		end
	end
	exhibitRoom.defineInteractions = function()
		for i=1,#exhibitRoom.parts do exhibitRoom.parts[i].Touched:Connect(exhibitRoom.onInteraction) end
	end
	exhibitRoom.animate = function(...)
		--print("iamdrawing")
		for i=1,#exhibitRoom.parts do
			s.rotate(exhibitRoom.parts[i],Vector3.new(math.random()*90,math.random()*90,math.random()*90))
		end
	end
	return exhibitRoom
end

-- FROM MH
function StudentExhibition.larryTheCukumber(x, z)
	local exhibitRoom = { room=b.new({x=x, z=z}), name="tomato", parts={}, onInteraction=nil }
	exhibitRoom.draw = function()
		for i=1,100 do
			--	exhibitRoom.parts[i] = s.sphere({x=math.random()*x-x/2, y=math.random()*30, z=math.random()*z-z-15, color="red", material=Enum.Material.Neon})
		end
		exhibitRoom.parts[#exhibitRoom.parts+1] = s.panel({x=-10,y=10,z=-35, color=Color3.new(0.603922, 0.14902, 1),rotateby=Vector3.new(0,90,0), material=Enum.Material.Foil})
		exhibitRoom.parts[#exhibitRoom.parts+1] = s.panel(-10, 5, -30, 8, "red", Enum.Material.Glass)
		exhibitRoom.parts[#exhibitRoom.parts+1] = s.panel({x=-5,y=5,z=-35, color=Color3.new(1, 0.6, 0.109804),rotateby=Vector3.new(0,0,90), material=Enum.Material.Neon})
		--	local m1=s.union(exhibitRoom.parts[1],{exhibitRoom.parts[2],exhibitRoom.parts[3]})
		--s.material(m1,Enum.Material.Neon)
		--exhibitRoom.parts[1]=m1
	end
	exhibitRoom.onInteraction = function(thePart)
		local touchingPartsTable = thePart:GetTouchingParts()
		for i=1,#touchingPartsTable do
			s.fill(touchingPartsTable[i], Color3.new(0, 0.34902, 1))
			s.material(touchingPartsTable[i], Enum.Material.Wood)
			s.resizeBy(touchingPartsTable[i], Vector3.new(-1, 0, -1))
		end
	end
	exhibitRoom.defineInteractions = function()
		for i=1,#exhibitRoom.parts do exhibitRoom.parts[i].Touched:Connect(exhibitRoom.onInteraction) end
	end
	exhibitRoom.animate = function(...)
		--print("iamdrawing")
		for i=1,#exhibitRoom.parts do
			s.rotate(exhibitRoom.parts[i],Vector3.new(math.random()*90,math.random()*90,math.random()*90))
		end
	end
	return exhibitRoom
end



-- FROM AM
function StudentExhibition.newfallingstars(x, z)
	local exhibitRoom = { room=b.new({x=x, z=z}), name="newfallingstars", parts={}, onInteraction=nil }
	exhibitRoom.draw = function()
		for i=1,20 do
			exhibitRoom.parts[#exhibitRoom.parts+1] = s.disc({x=math.random()*x-x/2, y=math.random()*30, z=math.random()*z-z-15, color="red",size=2, material=Enum.Material.Neon, rotateby=Vector3.new(math.random()*90,math.random()*90,math.random()*90)})
		end
		for i=21,40 do
			exhibitRoom.parts[#exhibitRoom.parts+1] = s.sphere({x=math.random()*x-x/2, y=math.random()*30, z=math.random()*z-z-15, color="red",size=6, material=Enum.Material.Neon})
		end
		exhibitRoom.parts[#exhibitRoom.parts+1] = s.sphere({position=exhibitRoom.room.center, color="red", material=Enum.Material.Foil})
		exhibitRoom.parts[#exhibitRoom.parts+1] = s.sphere(-10, 5, -30, 8, "red", Enum.Material.Glass)
	end
	exhibitRoom.onInteraction = function(thePart)
		local touchingPartsTable = thePart:GetTouchingParts()
		for i=1,#touchingPartsTable do
			s.fill(touchingPartsTable[i], Color3.new(0, 0.34902, 1))
			s.material(touchingPartsTable[i], Enum.Material.Wood)
			s.resizeBy(touchingPartsTable[i], Vector3.new(-1, 0, -1))
		end

	end
	exhibitRoom.defineInteractions = function()
		for i=1,#exhibitRoom.parts do exhibitRoom.parts[i].Touched:Connect(exhibitRoom.onInteraction) end
	end
	exhibitRoom.animate = function(...) 
		for i=1,#exhibitRoom.parts do
			--		s.fill(exhibitRoom.parts[i], Color3.new(math.random(),math.random(),math.random()))
		end
	end
	return exhibitRoom
end


-- FROM AM
function StudentExhibition.newAidastars(x, z)
	local exhibitRoom = { room=b.new({x=x, z=z}), name="newAidastars", parts={}, onInteraction=nil }
	exhibitRoom.draw = function()
		for i=1,20 do
			exhibitRoom.parts[#exhibitRoom.parts+1] = s.disc({x=math.random()*x-x/2, y=math.random()*30, z=math.random()*z-z-15, color="red",size=2, material=Enum.Material.Neon, rotateby=Vector3.new(math.random()*90,math.random()*90,math.random()*90)})
		end
		for i=21,40 do
			exhibitRoom.parts[#exhibitRoom.parts+1] = s.sphere({x=math.random()*x-x/2, y=math.random()*30, z=math.random()*z-z-15, color="red",size=6, material=Enum.Material.Neon})
		end
		exhibitRoom.parts[#exhibitRoom.parts+1] = s.sphere({position=exhibitRoom.room.center, color="red", material=Enum.Material.Foil})
		exhibitRoom.parts[#exhibitRoom.parts+1] = s.sphere(-10, 5, -30, 8, "red", Enum.Material.Glass)
	end
	exhibitRoom.onInteraction = function(thePart)
		s.fill(workspace.Part, Color3.new(0, 0.34902, 1))
		s.material(workspace.Part, Enum.Material.Neon)
	end
	exhibitRoom.defineInteractions = function()
		for i=1,#exhibitRoom.parts do exhibitRoom.parts[i].Touched:Connect(exhibitRoom.onInteraction) end
	end
	exhibitRoom.animate = function(...) 
		for i=1,#exhibitRoom.parts do
			s.fill(exhibitRoom.parts[i], Color3.new(math.random(),math.random(),math.random()))
		end
	end
	return exhibitRoom
end

-- FROM AM
function StudentExhibition.newAidaroblox(x, z)
	local exhibitRoom = { room=b.new({x=x, z=z}), name="newAidaroblox", parts={} }
	exhibitRoom.draw = function()

		for i=1,20 do
			exhibitRoom.parts[#exhibitRoom.parts+1] = s.sphere({x=math.random()*x-x/2, y=math.random()*30, z=math.random()*z-z-15, color="red",size=2, material=Enum.Material.Neon})  -- Neon
		end
		for i=21,40 do
			exhibitRoom.parts[#exhibitRoom.parts+1] = s.sphere({x=math.random()*x-x/2, y=math.random()*30, z=math.random()*z-z-15, color="red",size=6, material=Enum.Material.Neon}) -- Neon
		end
		exhibitRoom.parts[#exhibitRoom.parts+1] = s.sphere({position=exhibitRoom.room.center, color="red", material=Enum.Material.Neon})
		exhibitRoom.parts[#exhibitRoom.parts+1] = s.sphere(-10, 5, -30, 8, "red", Enum.Material.Glass)
	end
	exhibitRoom.onInteraction = function(thePart)
		local touchingPartsTable = thePart:GetTouchingParts()
		for i=1,#touchingPartsTable do
			s.fill(touchingPartsTable[i], Color3.new(0, 0.34902, 1))
			s.material(touchingPartsTable[i], Enum.Material.Wood)
			s.resizeBy(touchingPartsTable[i], Vector3.new(-1, 0, -1))
		end
	end
	exhibitRoom.defineInteractions = function()
		for i=1,#exhibitRoom.parts do exhibitRoom.parts[i].Touched:Connect(exhibitRoom.onInteraction) end
	end
	exhibitRoom.animate = function(...) 
		for i=1,#exhibitRoom.parts do
			s.fill(exhibitRoom.parts[i], Color3.new(math.random(),math.random(),math.random()))
		end
	end
	return exhibitRoom
end

-- FROM AM
function StudentExhibition.newAidaSpheres(x, z)
	local exhibitRoom = { room=b.new({x=x, z=z}), name="newAidaSpheres", parts={} }
	exhibitRoom.draw = function()
		for j=1,4 do
			for i=1,3 do
				exhibitRoom.parts[#exhibitRoom.parts+1] = s.sphere(-20+10*i, 20, -100+20*j, 6, Color3.fromRGB(85, 0, 255), Enum.Material.Neon)
				exhibitRoom.parts[#exhibitRoom.parts+1] = s.sphere({x=-20+10*i,y=12,z=-100+20*j, color=Color3.fromRGB(171, 54, 151), material=Enum.Material.Neon})
				exhibitRoom.parts[#exhibitRoom.parts+1] = s.sphere(-20+10*i, 4, -100+20*j, 20, Color3.fromRGB(149, 255, 170), Enum.Material.Neon)
			end		
		end
	end
	exhibitRoom.onInteraction = function(thePart)
		local touchingPartsTable = thePart:GetTouchingParts()
		for i=1,#touchingPartsTable do
			s.fill(touchingPartsTable[i], Color3.new(0, 0.34902, 1))
			s.material(touchingPartsTable[i], Enum.Material.Wood)
			s.resizeBy(touchingPartsTable[i], Vector3.new(-1, 0, -1))
		end
	end
	exhibitRoom.defineInteractions = function()
		for i=1,#exhibitRoom.parts do exhibitRoom.parts[i].Touched:Connect(exhibitRoom.onInteraction) end
	end
	exhibitRoom.animate = function(...) 
	end
	return exhibitRoom
end

-- from AM
function StudentExhibition.spiralStaircase(x, z)
	local exhibitRoom = { room=b.new({x=x, z=z}), name="spiralStaircase", parts={}, onInteraction=nil }
	exhibitRoom.draw = function()
		local numSpheres = 25
		local radiusOfCircle = 15
		for i=1,numSpheres do
			local xCoordinate = radiusOfCircle * math.cos(360*(i/numSpheres) * math.pi/180)
			local zCoordinate = radiusOfCircle * math.sin(360*(i/numSpheres) * math.pi/180)
			exhibitRoom.parts[#exhibitRoom.parts+1] = s.panel({x=xCoordinate+10,y=i,z=zCoordinate-30, thickness=1, color=Color3.new(0.666667, 0.666667, 1), rotateBy=Vector3.new(0, -360*(i/numSpheres), 0), material=Enum.Material.Glass})
			local xCoordinate = radiusOfCircle * math.cos((360*(i/numSpheres)+180) * math.pi/180)
			local zCoordinate = radiusOfCircle * math.sin((360*(i/numSpheres)+180) * math.pi/180)
			exhibitRoom.parts[#exhibitRoom.parts+1] = s.panel({x=xCoordinate+10,y=i,z=zCoordinate-30, thickness=1, color=Color3.new(0.666667, 0.666667, 1), rotateBy=Vector3.new(0, -360*(i/numSpheres), 0), material=Enum.Material.Glass})
		end
	end
	exhibitRoom.onInteraction = function(thePart)
		local touchingPartsTable = thePart:GetTouchingParts()
		for i=1,#touchingPartsTable do
			s.fill(touchingPartsTable[i], Color3.new(0.6, 0.368627, 1))
			s.material(touchingPartsTable[i], Enum.Material.Glass)
		end
	end
	exhibitRoom.defineInteractions = function()
		for i=1,#exhibitRoom.parts do exhibitRoom.parts[i].Touched:Connect(exhibitRoom.onInteraction) end
	end
	exhibitRoom.animate = function(...) 
		for i=1,#exhibitRoom.parts do
			--s.fill(exhibitRoom.parts[i], Color3.new(math.random(),math.random(),math.random()))
		end
	end
	return exhibitRoom
end

--FROM AM
function StudentExhibition.MegaBloxAida(x, z)
	local exhibitRoom = { room=b.new({x=x, z=z}), name="MegaBloxAida", parts={} }
	exhibitRoom.draw = function()
		for i=1,200 do
			exhibitRoom.parts[#exhibitRoom.parts+1] = s.cube({x=math.random()*x-x/2, y=math.random(1,5), z=math.random()*z-z-15, Color3.new(0.666667, 0.666667, 1),size=2, material=Enum.Material.Glass})  -- Neon
		end
		for i=21,40 do
			exhibitRoom.parts[#exhibitRoom.parts+1] = s.cube({x=math.random()*x-x/2, y=math.random()*30, z=math.random()*z-z-15, Color3.new(0.666667, 0.666667, 1), material=Enum.Material.Glass})
			exhibitRoom.parts[#exhibitRoom.parts+1] = s.cube({position=exhibitRoom.room.center,Color3.new(0.666667, 0.666667, 1) , material=Enum.Material.Glass})
			exhibitRoom.parts[#exhibitRoom.parts+1] = s.cube({x=math.random()*x-x/2, y=5, z=math.random()*z-z-15, size=8, color=Color3.new(0.666667, 0.666667, 1), material=Enum.Material.Glass})

		end
	end
	exhibitRoom.onInteraction = function(thePart)
		local touchingPartsTable = thePart:GetTouchingParts()
		for i=1,#touchingPartsTable do
			s.fill(touchingPartsTable[i], Color3.new(0.423529, 0.403922, 1))
			s.material(touchingPartsTable[i], Enum.Material.Glass)
			s.resizeBy(touchingPartsTable[i], Vector3.new(-1, 0, -1))
		end
	end
	exhibitRoom.defineInteractions = function()
		--for i=1,#exhibitRoom.parts do exhibitRoom.parts[i].Touched:Connect(exhibitRoom.onInteraction) end
	end
	exhibitRoom.animate = function()
		local targetModulus=math.random(0,9)
		for i=1,#exhibitRoom.parts do
			if(i%targetModulus==0) then s.fill(exhibitRoom.parts[i], Color3.new(0.333333, 0.666667, 0.6+math.random(0,40)/100)) end
		end
		wait(0.3)
	end
	return exhibitRoom
end

-- FROM Avrzm
function StudentExhibition.AvramRoblox(x, z)
	local exhibitRoom = { room=b.new({x=x, z=z}), name="newAvramroblox", parts={} }
	exhibitRoom.draw = function()

		for i=1,200 do
			exhibitRoom.parts[#exhibitRoom.parts+1] = s.sphere({anchored=false, x=math.random()*x-x/2, y=5, z=math.random()*z-z-15, color="red",size=2, material=Enum.Material.Neon})  -- Neon
		end
		for i=21,40 do
			exhibitRoom.parts[#exhibitRoom.parts+1] = s.sphere({x=math.random()*x-x/2, y=math.random()*30, z=math.random()*z-z-15, color="red",size=6, material=Enum.Material.Neon}) -- Neon
		end
		exhibitRoom.parts[#exhibitRoom.parts+1] = s.sphere({position=exhibitRoom.room.center, color="red", material=Enum.Material.Neon})
		exhibitRoom.parts[#exhibitRoom.parts+1] = s.sphere(-10, 5, -30, 8, "red", Enum.Material.Glass)
	end
	exhibitRoom.onInteraction = function(thePart)
		local touchingPartsTable = thePart:GetTouchingParts()
		for i=1,#touchingPartsTable do
			--s.fill(touchingPartsTable[i], Color3.new(0, 0.34902, 1))
			--	s.material(touchingPartsTable[i], Enum.Material.Wood)
			--		s.resizeBy(touchingPartsTable[i], Vector3.new(-1, 0, -1))
		end
	end
	exhibitRoom.defineInteractions = function()
		for i=1,#exhibitRoom.parts do exhibitRoom.parts[i].Touched:Connect(exhibitRoom.onInteraction) end
	end
	exhibitRoom.animate = function(...)
		local targetModulus=math.random(0,9)
		for i=1,#exhibitRoom.parts do
			if(i%targetModulus==0) then s.fill(exhibitRoom.parts[i], Color3.new(math.random(),math.random(),math.random())) end
		end
		wait(0.5)
	end
	return exhibitRoom
end

-- FROM AZ
function StudentExhibition.AvramsObby(x, z)
	local exhibitRoom = { room=b.new({x=x, z=z}), name="aVRAMZSOBBY", parts={}, onInteraction=nil }
	exhibitRoom.draw = function()  
		exhibitRoom.parts[#exhibitRoom.parts+1] =s.cube({x=-14,y=0.6,z=-10, color=Color3.new(0.64,0.64,0.65), material=Enum.Material.Plastic, rotateBy=Vector3.new(-180,0,0), size=Vector3.new(4,1,1), dummy=''  })
		exhibitRoom.parts[#exhibitRoom.parts+1] =s.cube({x=-14,y=0.6,z=-12, color=Color3.new(0.64,0.64,0.65), material=Enum.Material.Plastic, rotateBy=Vector3.new(-180,0,0), size=Vector3.new(4,1,1), dummy=''  })
		exhibitRoom.parts[#exhibitRoom.parts+1] =s.cube({x=-10,y=0.6,z=-20, color=Color3.new(0.64,0.64,0.65), material=Enum.Material.Plastic, rotateBy=Vector3.new(-180,0,0), size=Vector3.new(4,1,1), dummy=''  })
		exhibitRoom.parts[#exhibitRoom.parts+1] =s.cube({x=-18,y=0.6,z=-24, color=Color3.new(0.64,0.64,0.65), material=Enum.Material.Plastic, rotateBy=Vector3.new(-180,0,0), size=Vector3.new(4,1,1), dummy=''  })
		exhibitRoom.parts[#exhibitRoom.parts+1] =s.cube({x=-10,y=0.6,z=-28, color=Color3.new(0.64,0.64,0.65), material=Enum.Material.Plastic, rotateBy=Vector3.new(-180,0,0), size=Vector3.new(4,1,1), dummy=''  })
		exhibitRoom.parts[#exhibitRoom.parts+1] =s.cube({x=-14,y=0.6,z=-28, color=Color3.new(0.64,0.64,0.65), material=Enum.Material.Plastic, rotateBy=Vector3.new(-180,0,0), size=Vector3.new(4,1,1), dummy=''  })
		exhibitRoom.parts[#exhibitRoom.parts+1] =s.cube({x=-10,y=0.6,z=-36, color=Color3.new(0.64,0.64,0.65), material=Enum.Material.Plastic, rotateBy=Vector3.new(-180,0,0), size=Vector3.new(4,1,1), dummy=''  })
		exhibitRoom.parts[#exhibitRoom.parts+1] =s.cube({x=-18,y=0.6,z=-40, color=Color3.new(0.64,0.64,0.65), material=Enum.Material.Plastic, rotateBy=Vector3.new(-180,0,0), size=Vector3.new(4,1,1), dummy=''  })
		exhibitRoom.parts[#exhibitRoom.parts+1] =s.cube({x=34,y=13.6,z=-43, color=Color3.new(0.64,0.64,0.65), material=Enum.Material.Plastic, rotateBy=Vector3.new(0,0,0), size=Vector3.new(4,1,1), dummy=''  })
		exhibitRoom.parts[#exhibitRoom.parts+1] =s.cube({x=42,y=13.6,z=-43, color=Color3.new(0.64,0.64,0.65), material=Enum.Material.Plastic, rotateBy=Vector3.new(0,0,0), size=Vector3.new(4,1,1), dummy=''  })
		exhibitRoom.parts[#exhibitRoom.parts+1] =s.cube({x=42,y=13.6,z=-47, color=Color3.new(0.64,0.64,0.65), material=Enum.Material.Plastic, rotateBy=Vector3.new(0,0,0), size=Vector3.new(4,1,1), dummy=''  })
		exhibitRoom.parts[#exhibitRoom.parts+1] =s.cube({x=34,y=13.6,z=-47, color=Color3.new(0.64,0.64,0.65), material=Enum.Material.Plastic, rotateBy=Vector3.new(0,0,0), size=Vector3.new(4,1,1), dummy=''  })
		exhibitRoom.parts[#exhibitRoom.parts+1] =s.cube({x=38,y=13.6,z=-51, color=Color3.new(0.64,0.64,0.65), material=Enum.Material.Plastic, rotateBy=Vector3.new(0,0,0), size=Vector3.new(4,1,1), dummy=''  })
		exhibitRoom.parts[#exhibitRoom.parts+1] =s.cube({x=42,y=13.6,z=-51, color=Color3.new(0.64,0.64,0.65), material=Enum.Material.Plastic, rotateBy=Vector3.new(0,0,0), size=Vector3.new(4,1,1), dummy=''  })
		exhibitRoom.parts[#exhibitRoom.parts+1] =s.cube({x=34,y=13.6,z=-51, color=Color3.new(0.64,0.64,0.65), material=Enum.Material.Plastic, rotateBy=Vector3.new(0,0,0), size=Vector3.new(4,1,1), dummy=''  })
		exhibitRoom.parts[#exhibitRoom.parts+1] =s.cube({x=42,y=0.6,z=-63, color=Color3.new(0.64,0.64,0.65), material=Enum.Material.Plastic, rotateBy=Vector3.new(-180,0,0), size=Vector3.new(4,1,1), dummy=''  })
		exhibitRoom.parts[#exhibitRoom.parts+1] =s.cube({x=34,y=0.6,z=-63, color=Color3.new(0.64,0.64,0.65), material=Enum.Material.Plastic, rotateBy=Vector3.new(-180,0,0), size=Vector3.new(4,1,1), dummy=''  })
		exhibitRoom.parts[#exhibitRoom.parts+1] =s.cube({x=42,y=0.6,z=-67, color=Color3.new(0.64,0.64,0.65), material=Enum.Material.Plastic, rotateBy=Vector3.new(-180,0,0), size=Vector3.new(4,1,1), dummy=''  })
		exhibitRoom.parts[#exhibitRoom.parts+1] =s.cube({x=-18,y=0.6,z=-68, color=Color3.new(0.64,0.64,0.65), material=Enum.Material.Plastic, rotateBy=Vector3.new(-180,0,0), size=Vector3.new(4,1,1), dummy=''  })
		exhibitRoom.parts[#exhibitRoom.parts+1] =s.cube({x=-10,y=0.6,z=-68, color=Color3.new(0.64,0.64,0.65), material=Enum.Material.Plastic, rotateBy=Vector3.new(-180,0,0), size=Vector3.new(4,1,1), dummy=''  })
		exhibitRoom.parts[#exhibitRoom.parts+1] =s.cube({x=42,y=0.6,z=-84, color=Color3.new(0.64,0.64,0.65), material=Enum.Material.Plastic, rotateBy=Vector3.new(-180,0,0), size=Vector3.new(4,1,1), dummy=''  })
		exhibitRoom.parts[#exhibitRoom.parts+1] =s.cube({x=38,y=0.6,z=-88, color=Color3.new(0.64,0.64,0.65), material=Enum.Material.Plastic, rotateBy=Vector3.new(-180,0,0), size=Vector3.new(4,1,1), dummy=''  })
		exhibitRoom.parts[#exhibitRoom.parts+1] =s.cube({x=-12,y=0.6,z=-42, color=Color3.new(0.64,0.64,0.65), material=Enum.Material.Plastic, rotateBy=Vector3.new(-180,0,0), size=Vector3.new(4,1,1), dummy=''  })
		exhibitRoom.parts[#exhibitRoom.parts+1] =s.cube({x=-16,y=0.6,z=-42, color=Color3.new(0.64,0.64,0.65), material=Enum.Material.Plastic, rotateBy=Vector3.new(-180,0,0), size=Vector3.new(4,1,1), dummy=''  })
		exhibitRoom.parts[#exhibitRoom.parts+1] =s.cube({x=-12,y=0.6,z=-46, color=Color3.new(0.64,0.64,0.65), material=Enum.Material.Plastic, rotateBy=Vector3.new(-180,0,0), size=Vector3.new(4,1,1), dummy=''  })
		exhibitRoom.parts[#exhibitRoom.parts+1] =s.cube({x=-16,y=0.6,z=-46, color=Color3.new(0.64,0.64,0.65), material=Enum.Material.Plastic, rotateBy=Vector3.new(-180,0,0), size=Vector3.new(4,1,1), dummy=''  })
		exhibitRoom.parts[#exhibitRoom.parts+1] =s.cube({x=34,y=0.6,z=-50, color=Color3.new(0.64,0.64,0.65), material=Enum.Material.Plastic, rotateBy=Vector3.new(-180,0,0), size=Vector3.new(4,1,1), dummy=''  })
		exhibitRoom.parts[#exhibitRoom.parts+1] =s.cube({x=42,y=0.6,z=-50, color=Color3.new(0.64,0.64,0.65), material=Enum.Material.Plastic, rotateBy=Vector3.new(-180,0,0), size=Vector3.new(4,1,1), dummy=''  })
		exhibitRoom.parts[#exhibitRoom.parts+1] =s.cube({x=42,y=0.6,z=-54, color=Color3.new(0.64,0.64,0.65), material=Enum.Material.Plastic, rotateBy=Vector3.new(-180,0,0), size=Vector3.new(4,1,1), dummy=''  })

	end
	exhibitRoom.onInteraction = function(thePart)
		s.fill(workspace.Part, Color3.new(0, 0.34902, 1))
		s.material(workspace.Part, Enum.Material.Neon)
	end
	exhibitRoom.defineInteractions = function()
		for i=1,#exhibitRoom.parts do exhibitRoom.parts[i].Touched:Connect(exhibitRoom.onInteraction) end
	end
	exhibitRoom.animate = function(...) 
		for i=1,#exhibitRoom.parts do
			s.fill(exhibitRoom.parts[i], Color3.new(math.random(),math.random(),math.random()))
		end
	end
	return exhibitRoom
end


function StudentExhibition.destroy(activeRoom)
	print("Exiting " .. activeRoom.name)
	b.destroy(activeRoom.parts)
	-- Clear the installation of any works of art.  Leave the walls and floor alone.
end

return StudentExhibition