Main     News     FAQs     Docs     Links     License     Download     Support     Live Demo

Naken Chat

Developing Your Own Client

This document is for programmers who want to create a program that can connect to the Naken Chat server. First thing you need to know is that Naken Chat is purely simple plain text. This may change if I add encryption which is a possible future feature. A Naken Chat client can be simply a text area that displays everything the client receives and a text box that the user can type in and push a button or some other trigger to send the text to the server.

Another great hint for doing a "user list" box is there is a hidden .Z command. If the client sends over a .Z, the server will then give you info on how to populate the user list (without having to send a .w or .f command every time you want to update). So here's the information that Naken Chat will send if .Z is turned on:

@ on a line by itself tells the Naken Chat client to clear the user list
+ means add a string to the user list
- means subtract a string to the user list

So if you're sitting on the chat, and .Z is turned on, if someone logs on the server will send: +[3]mike telling the client to add [3]mike to the list. If the user on line 3 then types: .n indrek, the server will send first -[3]mike and then +[3]indrek. Easy eh?

As far as the colors go, the applet I wrote knows what to color a line by the first char in the line. If the first character in the line is a > then then line will be green. If it's < then it's blue. If it's # then it's red. Etc, etc.





Copyright 1997-2010 - Michael Kohn

Please visit my many other projects, including free J2ME Java games for Mobile phones, graphics and sound programs, chat software, and much more at http://www.mikekohn.net.

This page was designed to work with all standard HTML compatible webbrowsers including Firefox, IE, Safari, and Links.