Welcome, Guest. Please Login or Register.
Nov 22nd, 2024, 5:13pm

Home Home Help Help Search Search Members Members Login Login Register Register
Arimaa Forum « Chat room 2010 development and tests »


   Arimaa Forum
   Arimaa
   Site Discussion
(Moderator: supersamu)
   Chat room 2010 development and tests
« Previous topic | Next topic »
Pages: 1 2  Reply Reply Notify of replies Notify of replies Send Topic Send Topic Print Print
   Author  Topic: Chat room 2010 development and tests  (Read 4597 times)
leo
Forum Guru
*****





   


Gender: male
Posts: 278
Chat room 2010 development and tests
« on: Jun 26th, 2010, 12:34pm »
Quote Quote Modify Modify

For anyone interested in discussing the development of the next gen Arimaa chatroom, this is the place.
 
I've made an interface, just an empty shell for now, to discuss layout.
 
Before testing it, please have a look at what you should see in your browser on startup:
 

 
That's the chat tools. Random dummy messages should fill the chat log as time goes. Please check that the log automatically scrolls down to the bottom each time a line comes in.
 

 
That's the archive calendar. Please check it for math bugs if you have time.
 

 
Don't try to send chat messages for now, no server is implemented for now.
 
For the moment I'd like to discuss the layout and the collapsable panel system, to see if it's a good system for a chat room or not.
 
I've tested several layouts before, including one nifty one with fixed panels over a scrollable page but internet exploder blasted all the elements all over the place so I opted for a simple two column system.
 
Please let me know if you see useless scrollbars appear or weird behaviors of any kind. Half of the things don't work in IE8 for the moment so try with a real browser instead. The latest versions of Firefox, Chrome and Safari display everything OK.
 
Here it is : http://aa.leoki.ws/ch2/
 
Next, there will be much to discuss, most notably for the server side and the communications. I have some ideas to improve performance and avoid loss of messages, etc. More about it later.
 
Thank you for any feedback. Please indicate which OS and browsers you used (including versions).
 
Some forum links that can be helpful:
 
Recent chatroom features discussion
 
2008 chatroom thread
 
I sure forgot to tell half of the things I should have. That's the developer's documentation sickness syndrom. I'll add them later.
« Last Edit: Jun 30th, 2010, 12:38pm by leo » IP Logged
Eltripas
Forum Guru
*****




Meh-he-kah-naw

   


Gender: male
Posts: 225
Re: Chat room 2010 development and tests
« Reply #1 on: Jun 26th, 2010, 2:39pm »
Quote Quote Modify Modify

I love it, especially the shared board.
IP Logged
Hippo
Forum Guru
*****




Arimaa player #4450

   


Gender: male
Posts: 883
Re: Chat room 2010 development and tests
« Reply #2 on: Jun 26th, 2010, 3:30pm »
Quote Quote Modify Modify

I would prefere North on top of the shared board.
Is there any functionality on the shared board already?
IP Logged

Isaac Grosof
Forum Guru
*****



Longtime Arimaa Fan

   


Gender: male
Posts: 175
Re: Chat room 2010 development and tests
« Reply #3 on: Jun 26th, 2010, 3:42pm »
Quote Quote Modify Modify

In the calendar section, indicate the day of the week somewhere. Also, once the chatting is functional, I would like a preview post button.
IP Logged

Sorry about that one thing.
leo
Forum Guru
*****





   


Gender: male
Posts: 278
Re: Chat room 2010 development and tests
« Reply #4 on: Jun 26th, 2010, 4:41pm »
Quote Quote Modify Modify

@Eltripas: Thanks! For two years I've been dreaming of implementing that shared board Wink or hoping someone else would.
 
@Hippo: Board orientation option added to the to-do list. No, there is no functionality on the board yet. It will have a set of commands that can be either clicked or typed such as "/b h b3" (archiving jargon for "highlight square b3") or "/b p b3 gh" (put gold horse on b3) (mouse-drag horse icon onto the square). I'll tell more about it in the days to come, I need to sort my brains first.
 
@722caasi: That's two of the things I forgot to mention and ask. Which should be the first day of the week? And I envisioned an input preview that refreshes at each key stroke (especially for some commands and codes that might be a bit difficult at first, for instance the short move notation codes adapted for picture conversion) but wasn't sure anybody wanted that. Now it's clear.
« Last Edit: Jul 14th, 2010, 5:20am by leo » IP Logged
Fritzlein
Forum Guru
*****



Arimaa player #706

   
Email

Gender: male
Posts: 5928
Re: Chat room 2010 development and tests
« Reply #5 on: Jun 26th, 2010, 4:56pm »
Quote Quote Modify Modify

Leo, the concept of a shared board is fantastic, exactly what I need to give a workshop at the Arimaa Festival.  I'm more eager for this feature than all the others combined!
 
You're doing a great service to the Arimaa community.
IP Logged

leo
Forum Guru
*****





   


Gender: male
Posts: 278
Re: Chat room 2010 development and tests
« Reply #6 on: Jun 26th, 2010, 5:00pm »
Quote Quote Modify Modify

Thank you Fritz! Smiley The shared board is a tiny gadget that is much much simpler than a game interface though, and I'm not sure it can serve the purpose of the workshop. Should I add an option to make it larger and with the marble background?
« Last Edit: Jun 30th, 2010, 12:41pm by leo » IP Logged
Fritzlein
Forum Guru
*****



Arimaa player #706

   
Email

Gender: male
Posts: 5928
Re: Chat room 2010 development and tests
« Reply #7 on: Jun 26th, 2010, 5:29pm »
Quote Quote Modify Modify

I'm not fussed about the background, but a larger size would be great.
 
I'm not sure what features of the plan window I would miss if they weren't there, but I could, for example, do without a move list.  Checking legality of moves and removing captured pieces would be nice.  Simply being able to move pieces around in full view of others, however, is the essential functionality.
IP Logged

leo
Forum Guru
*****





   


Gender: male
Posts: 278
Re: Chat room 2010 development and tests
« Reply #8 on: Jun 27th, 2010, 3:05pm »
Quote Quote Modify Modify

I'll make the control panel resizable then, and the board adjust its size accordingly.
 
However offering step arrows and legality check as in a game client might make both the client code and the server code incredibly complicated: What if somebody sends the first step of a pulling move while somebody else sends another move? How to discard the second message gracefully? What if somebody sends an undo command while another step has been sent by somebody else meanwhile? Or if someone ends the turn while someone else is still playing the current color? And how to distinguish between square highlighting and arrow clicking?
 
I understand that in a workshop there should be only one person manipulating the board though, so it could be possible to implement a special mode in which the board is locked for everybody but one user.
 
Another solution would be to have a queue of users who want to change something on the board, but do we really want that much complexity for the chat room?
 
There are tons of such questions that haunt me since I started coding version 2, and they are not always easy to express because each one depends on what basic choices of functioning are selected, and there are several.
 
My hope is that maybe I missed *the* simple solution and someone will tell it here. For the moment I walk on my toes trying to keep everything very basic and less bug prone. I see the shared board as a white board on which everybody can write (with some delay due to the current technology).
 
I hope the discussions in the following weeks will lead to the "perfect" chat room (perfect for our needs, that is). I prefer not to rush coding for the moment.
« Last Edit: Jun 30th, 2010, 12:41pm by leo » IP Logged
jdb
Forum Guru
*****



Arimaa player #214

   


Gender: male
Posts: 682
Re: Chat room 2010 development and tests
« Reply #9 on: Jun 27th, 2010, 4:36pm »
Quote Quote Modify Modify

on Jun 26th, 2010, 5:29pm, Fritzlein wrote:
 Simply being able to move pieces around in full view of others, however, is the essential functionality.

 
I agree. Anything on top of this may not be needed.
IP Logged
Fritzlein
Forum Guru
*****



Arimaa player #706

   
Email

Gender: male
Posts: 5928
Re: Chat room 2010 development and tests
« Reply #10 on: Jun 27th, 2010, 5:26pm »
Quote Quote Modify Modify

on Jun 27th, 2010, 3:05pm, leo wrote:
I'll make the control panel resizable then, and the board adjust its size accordingly.

That will be a nice functionality.
 
Quote:
I understand that in a workshop there should be only one person manipulating the board though, so it could be possible to implement a special mode in which the board is locked for everybody but one user.

I doubt locking the board will be necessary.  This is a case where anti-social behavior is entirely visible, i.e. we would know who was doing it, so it would be less likely to happen.  For a workshop it is actually desirable not to have the board locked, so that someone else could suggest a move on the board rather than having to figure out notation to describe it so that the presenter can make it.
 
Quote:
Another solution would be to have a queue of users who want to change something on the board, but do we really want that much complexity for the chat room?

I would vote against the queue as unnecessary complexity.  Let's see whether we can cooperate socially first.  If social cooperation doesn't work, we can address the problems that arise.
 
Quote:
However offering step arrows and legality check as in a game client might make both the client code and the server code incredibly complicated:

Legality check is different from step arrows.  You could implement the former server-side only and the latter not at all.
 
Quote:
What if somebody sends the first step of a pulling move while somebody else sends another move?  How to discard the second message gracefully?

Just discard the second message ungracefully as an illegal step.  See whether the chat room users can work out a graceful way to cooperate with a minimal interface.
 
Quote:
What if somebody sends an undo command while another step has been sent by somebody else meanwhile?

Process the commands in order.  If the step gets there first, it is undone by the undo that comes second.  If the undo gets there first, it happens, and then the step happens second if it is legal, or not if not.
 
Quote:
Or if someone ends the turn while someone else is still playing the current color?

Then the step that arrives for the player whose turn it is not must be discarded.
 
Quote:
And how to distinguish between square highlighting and arrow clicking?

Make it easy on yourself.  Input moves with click and drag rather than arrows and highlights.  Then all legality can be checked server-side.  For a minimal interface, you can put the responsibility on the players to know not to move frozen pieces and know that dislodgement must be completed, etc.
 
Quote:
For the moment I walk on my toes trying to keep everything very basic and less bug prone.

Good!  Better to have simple functionality that works instead of complex functionality that often breaks.
 
Quote:
I prefer not to rush coding for the moment.

I don't want to rush you.  If the shared board is not ready by September, I will give the workshop by other means, or perhaps not give one at all.  No worries.  Don't feel pressure to do more than you want to or to do it faster than you have free time for it.  Contributing to the community should be fun and feel good, or else why would you do it?  Enjoy!  Smiley
« Last Edit: Jun 27th, 2010, 5:27pm by Fritzlein » IP Logged

leo
Forum Guru
*****





   


Gender: male
Posts: 278
Re: Chat room 2010 development and tests
« Reply #11 on: Jun 28th, 2010, 4:31pm »
Quote Quote Modify Modify

Thank you for all the feedback Fritz and jdb. I'm actually the one putting pressure on myself and resisting the temptation of implementing a ton of things. I'm sorry if my wording sounded otherwise. The chatroom will be ready well before september, no worries.
 
Regarding the shared board, I suddenly realized what itched in the back of my mind: The more functionality in the chatroom, the more delay at the server in serving each request, because everything must be serialized to avoid collision in the data and log files. In a normal game there are only two players and they never send a move at the same time. But a shared board is a mess Smiley It will be much smoother and ready for more complexity when we all have websocket-enabled browsers though.
 
I've been thinking of the resizable shared board and hit a problem: The squares on it are filled with text and icons, the same we have in the chat log (plus the ones I'm adding now such as arrows and symbols) and the icons don't look good when stretched: pixel porridge.
 
So another idea came up: I've interrupted the development of the new notation converter tool, but it already contains functions for loading a game log (without legality check though), displaying a clickable list of it and displaying the position at any move or step. Since I'm currently exploring SVG graphics (you know, the vector graphics that are on all phones and browsers except IE), I thought I could transform that tool into a workshop window with a fully sizable game board (but no real game interface). It would be used in parallel to the chatroom for the workshop and it would run on its own server script, thus lightening the chatroom load.
 
I'll keep you posted with the progress.
 
As soon as the chat room interface is more or less finished there will be a big discussion about optimizing the http requests to the server and avoiding losses and duplicates (they are mutually exclusive in a simple system, lol)
« Last Edit: Jun 30th, 2010, 12:42pm by leo » IP Logged
Fritzlein
Forum Guru
*****



Arimaa player #706

   
Email

Gender: male
Posts: 5928
Re: Chat room 2010 development and tests
« Reply #12 on: Jun 28th, 2010, 5:47pm »
Quote Quote Modify Modify

Having a workshop window separate from the chat room sounds like a fine alternative, not only for the festival but also for everyday use.  Thanks for the updates.
IP Logged

leo
Forum Guru
*****





   


Gender: male
Posts: 278
Re: Chat room 2010 development and tests
« Reply #13 on: Jun 30th, 2010, 12:53pm »
Quote Quote Modify Modify

I've been turning the problem on all its facets and realized that since a separate shared board would need login and authentication from the chatroom anyway, I might as well make it a big pane that would get inserted to the left of the control panel of the chatroom. That way the board would benefit from a lot of useful scripts and state data already there. There is a way for javascript to share data between windows though but it doesn't always work consistently across browsers.
« Last Edit: Jul 14th, 2010, 5:21am by leo » IP Logged
omar
Forum Guru
*****



Arimaa player #2

   


Gender: male
Posts: 1003
Re: Chat room 2010 development and tests
« Reply #14 on: Jul 1st, 2010, 7:18am »
Quote Quote Modify Modify

Wow, the new chatroom interface is looking great.
 
on Jun 28th, 2010, 4:31pm, leo wrote:
As soon as the chat room interface is more or less finished there will be a big discussion about optimizing the http requests to the server and avoiding losses and duplicates (they are mutually exclusive in a simple system, lol)

 
Since HTML5 WebSockets are taking a while to become ubiquitous, I had considered using a socket bridge for the next version of the JavaScript client. I have not experimented with these yet, but I did find some that look suitable.
 
Here is a Java to JavaScript socket bridge:
http://stephengware.com/projects/javasocketbridge/
 
Here is a Flash to JavaScript socket bridge:
http://devpro.it/xmlsocket/
 
The Java one will give a pop-up and require the user to accept it to run. But it is more powerful since it uses a conventional socket as opposed to an XMLSocket. Also it can connect to any server and does not require running a policy file daemon on the server it connects to.
 
Both do require running a daemon on the server to accept connections and process requests. This daemon is usually referred to as a websocket server. Apache is eventually supposed to have a module to make this easier, but it is not complete since the HTML5 WebSocket specs aren't yet settled. For the backend of the Flash V2 client which uses XMLSockets I have written a websocket server in Perl. So I can send you that code if you would like.
IP Logged
Pages: 1 2  Reply Reply Notify of replies Notify of replies Send Topic Send Topic Print Print

« Previous topic | Next topic »

Arimaa Forum » Powered by YaBB 1 Gold - SP 1.3.1!
YaBB © 2000-2003. All Rights Reserved.