Difference between revisions of "Talk:Login with Roaming Profiles"
From ComputerCraft Wiki
(→Should be posted in "Programs" instead?: new section) |
|||
Line 4: | Line 4: | ||
My argument is that this does not belong on the wiki. My reason is: we have forums for this. That simple. | My argument is that this does not belong on the wiki. My reason is: we have forums for this. That simple. | ||
+ | |||
+ | Just wanted to make a quick note here - | ||
+ | |||
+ | if validSender then | ||
+ | for i,v in ipairs(users) do | ||
+ | if message == v then | ||
+ | password = passwords[i] | ||
+ | valid = true | ||
+ | else | ||
+ | valid = false | ||
+ | end | ||
+ | end | ||
+ | |||
+ | That section of code is why it doesn't work - after the 'valid = true', there needs to be a 'break' or it will continue to iterate. | ||
+ | |||
+ | if validSender then | ||
+ | for i,v in ipairs(users) do | ||
+ | if message == v then | ||
+ | password = passwords[i] | ||
+ | valid = true | ||
+ | break | ||
+ | else | ||
+ | valid = false | ||
+ | end | ||
+ | end |
Revision as of 22:11, 22 October 2012
Does not work. Not authorised
Should be posted in "Programs" instead?
My argument is that this does not belong on the wiki. My reason is: we have forums for this. That simple.
Just wanted to make a quick note here -
if validSender then
for i,v in ipairs(users) do if message == v then password = passwords[i] valid = true else valid = false end end
That section of code is why it doesn't work - after the 'valid = true', there needs to be a 'break' or it will continue to iterate.
if validSender then
for i,v in ipairs(users) do if message == v then password = passwords[i] valid = true break else valid = false end end