Thought i wanted to share a simple chatserver i made.
Uppdate: added zip to download.
Chatserver - Simplified V.1.7
Note: if you want to edit the port server will be running on change settings on line 19 example under.
Dim $server = [SERVER-IP,PORT,Max_length_tcp_recive,MAX_concurrent_connections] ;[Server-IP,Port,Max_length_tcp_recive,Max_clients]
<*>telnet server-ip to connect.
<*>Show message of today on connect.(motd.txt can be modified on the fly, no need to restart server.)
<*>Register to use.(users registeded inn users.ini)
<*>Login to speech.
<*>Broadcasts userlogins to everyone, aswell as logout.
<*>Only 1 login per username.
<*>Send messages to everyone.
<*>Send private messages, to other users.
<*>Setstate, sets your current state afk, surfing etc... (Message is broadcasted and visible when listall command is used)
<*>Listall, lists all user currently logged on.
<*>Listchat, lists log over old chat.(only public chat)
<*>help, works the same way as motd, where you are able to edit help.txt while server is running.
<*>supports 99 concurrent connections. edit $server to change.
<*>If you try to login after you have allready logged on, server still thinks you are the same as before you tried to login again.
I basicly wanted to learn how to use socket server and handling different sockets with diferent variables at once.
Server code based off dnsi's AU3 MultiConnect-Socket Server! found here.
rar-file contains, everything needed to understand how users.ini, motd.txt and help.txt file work.
Edited by jokke, 06 June 2007 - 09:37 AM.