Posted 05 April 2013 - 09:53 AM
Hello! im busy with my login system and i have some questions
the client need to recieve the username and password from the master server
so how can the client ask for the usernames and passwords?
i thought this code?
so if the server get this he start the command: 'getUser' and then he reads the file where the usernames are and then sends back 'ok' if its a good name
if the name is wrong he would say 'not' and if he gets nothing then he just has no connection…
so is this the good code or need it to be something else?
so another question how to make a log file in the server that is displayed on a 4x3 monitor?
and with a log file i mean that you can see if a user is logging in to a client you will see who has logged in and the client computer id.
something like this:
and how to get the 'os.time()' always be right on time?
and another question:
if the usernames are stored in the user file and u will reset ur password or delete ur username how to do that? or do i need for every single username a file with the pass and user in it?
the client need to recieve the username and password from the master server
so how can the client ask for the usernames and passwords?
i thought this code?
rednet.send(serverid, "getUser, ..usernameInput..")
id, msg = rednet.receive(5)
if msg == "ok" then
........
so if the server get this he start the command: 'getUser' and then he reads the file where the usernames are and then sends back 'ok' if its a good name
if the name is wrong he would say 'not' and if he gets nothing then he just has no connection…
so is this the good code or need it to be something else?
so another question how to make a log file in the server that is displayed on a 4x3 monitor?
and with a log file i mean that you can see if a user is logging in to a client you will see who has logged in and the client computer id.
something like this:
print("Server ID: 'computerID' | JJ.os Server | os.time()
print("---------------------------------------------------")
log thingiess....
so this is what ur see on the monitor and then the log is under the prints that will allways stay if the log will be too longand how to get the 'os.time()' always be right on time?
and another question:
if the usernames are stored in the user file and u will reset ur password or delete ur username how to do that? or do i need for every single username a file with the pass and user in it?