|
| 17 Dec 2016 06:23 PM |
Hey could anyone spot what I'm doing wrong? Iterating through "settings" does not print anything. Also, "hi" does print.
server::
local settings = require(game.ReplicatedStorage.settings)
game.Players.PlayerAdded:connect(function(plr) table.insert(settings,plr.Name) settings[plr.Name] = "hi" end)
client::
wait(5) local settings = require(game.ReplicatedStorage.settings)
print("hi") for i,v in pairs(settings) do print(i,v) end
r+ |
|
|
| Report Abuse |
|
|
|
| 17 Dec 2016 06:28 PM |
Can't really help you unless you give us the module script "code".
And here:
settings[plr.Name] = "hi"
should be:
settings(plr, "Hi") --Being that function "setting" changes the players name from those two variables
you cannot make an event or "function" "equal" to something.
If the module is just a table then why is it in a module????
|
|
|
| Report Abuse |
|
|
|
| 17 Dec 2016 07:00 PM |
the module is just its default state:
module = {}
return module
r+ |
|
|
| Report Abuse |
|
|
TimeTicks
|
  |
| Joined: 27 Apr 2011 |
| Total Posts: 27115 |
|
|
| 17 Dec 2016 07:09 PM |
you cant set a module like that. you need to set it from within the module itself using one of its own functions
|
|
|
| Report Abuse |
|
|
| |
|