This is a bit of a mouthful to explain.
I’m developing a scale replica of the Ignalina Nuclear Power Plant in Roblox, where players will have to correctly operate the plant to generate power and earn money for doing so.
There are hundreds of fuctional switches (thousands counting the non-functional ones, yes I am aware this is a lot to handle rendering) that will correspond to some value, such as a water valve or electrical breaker and stuff like that. These values are held in a ModuleScript located in ReplicatedStorage titled ReactorData; it holds all the data that can be set and read by the game.
What I am trying to achieve is to have some way to “connect” a switch to a value from this table. I want the server to, upon receiving a message that switch X has been pressed, and modify switch X’s corresponding value. I have no idea how to do this; I’ve tried putting a module in switches that returns a value from ReactorData, but upon testing this did not work and wouldn’t actually set values.
This might be easier to explain visually; here’s a basic MS Paint diagram of how things will work.
Any help would be greatly appreciated! If I’m not very clear please feel free to ask me for more details on something.
