Author |
Topic: Standalone gameroom client -- what, why, how? (Read 7144 times) |
|
leo
Forum Guru
Gender:
Posts: 278
|
|
Standalone gameroom client -- what, why, how?
« on: Dec 31st, 2007, 2:28am » |
Quote Modify
|
Lost in the dark depths of the bot developer section of the forum there are a few discussions about making a standalone client application for playing in the gameroom of the arimaa.com server. I think this should be discussed here in the general section because it concerns mostly human players, not bots. What is a standalone gameroom client? It's a program installed on your computer, through which you can play in the gameroom without you needing to run your web browser. Why have a standalone gameroom client? Some people have problems running the web applets to play in the gameroom. A standalone client would stay away from the compatibility struggles that rage on the web. Loading the web applets can take time on slow connections. I'm not sure whether the web browsers are allowed to conserve them in their cache. A standalone client would start instantly on your computer. All these downloads are a big load on the server. A standalone client would only need to exchange move updates and a few other data about the state of the gameroom - who logged in and out, are there new games open to sit at or ongoing to watch, etc. The standalone client would allow you to save your games directly onto your local drive, and watch them even if you are offline. How to make this standalone client? There seems to be many software developers among the Arimaa community, starting with Omar Syed himself. One obvious choice is to compile the currently existing Flash client as a standalone application, but I'm not sure this is possible for all platforms. It would require adding some more functionalities that are currently taken care of by the web page, not the Flash applet. Some people have started several projects mentioned here and there in the bot developer section. All use different cross-platform frameworks and languages and it will be hard to get everybody to work together, but I started this thread in the hope this is possible. This thread is also for everybody to share their opinions about what functionalities the standalone client should offer, or whether it would be a huge time waster that would never be up and running. And I wish a happy new year to everybody and a lot of fun for the participants of the World Championship.
|
|
IP Logged |
|
|
|
leo
Forum Guru
Gender:
Posts: 278
|
|
Re: Standalone gameroom client -- what, why, how?
« Reply #1 on: Dec 31st, 2007, 3:17am » |
Quote Modify
|
Pheeew, here I finally digged up all the links I could find to the forum threads: * by monste9, in Ruby (I guess monste9 is Froody, from our yesterday chat about the standalone client) * by corsix, in C++/Lua * by Libor, in C#/.NET * by borg, in Java And useful technical stuff is here: http://arimaa.com/arimaa/protocol/ http://arimaa.com/arimaa/jsClient/specs/ http://arimaa.com/arimaa/download/ http://arimaa.com/arimaa/graphics/
|
|
IP Logged |
|
|
|
omar
Forum Guru
Arimaa player #2
Gender:
Posts: 1003
|
|
Re: Standalone gameroom client -- what, why, how?
« Reply #2 on: Jan 2nd, 2008, 1:29am » |
Quote Modify
|
Thanks for digging up these links Leo. I like that a stand alone client would provide the ability to save/load games locally. Having to install some software is probably the biggest negative. Also getting the software to work across the major platforms would be a challenge.
|
|
IP Logged |
|
|
|
froody
Forum Guru
I <3 nurpinar
Gender:
Posts: 103
|
|
Re: Standalone gameroom client -- what, why, how?
« Reply #3 on: Jan 8th, 2008, 12:53am » |
Quote Modify
|
Yep, the client based on RubyGo is my project. I'll try to do some work on it soon. I'd like to get it displaying my postal games but I'm still not clear about the protocol. Using 'action=mygames' the server returns a list of my games that look like this: 7=opponent=arimaa_master%13timecontrol=1d/14d/100/14d/0%13createdts=1198 359710%13postal=1%13role=w%13rated=1%13gid=79914%13 But how do I get the board position of that postal game?
|
|
IP Logged |
“Arimaa holds its master in its own bonds, shackling the mind and brain so that the inner freedom of the very strongest must suffer”
|
|
|
leo
Forum Guru
Gender:
Posts: 278
|
|
Re: Standalone gameroom client -- what, why, how?
« Reply #4 on: Jan 8th, 2008, 8:24am » |
Quote Modify
|
I suppose you retrieve the game ID for the game you want to display, then you feed this ID into the gamestate call (see toward the middle of the protocol page) which sends you the information you need. I think your client should take the complete move list, not just the board position, in order to check for repetitions.
|
|
IP Logged |
|
|
|
froody
Forum Guru
I <3 nurpinar
Gender:
Posts: 103
|
|
Re: Standalone gameroom client -- what, why, how?
« Reply #5 on: Jan 8th, 2008, 3:53pm » |
Quote Modify
|
How do I get the gsurl and tid of a postal game that is already in progress? The only actions that return this are creategame and reserveseat.
|
|
IP Logged |
“Arimaa holds its master in its own bonds, shackling the mind and brain so that the inner freedom of the very strongest must suffer”
|
|
|
leo
Forum Guru
Gender:
Posts: 278
|
|
Re: Standalone gameroom client -- what, why, how?
« Reply #6 on: Jan 8th, 2008, 4:39pm » |
Quote Modify
|
You are right, there is something unclear in the protocol. I first misread that the gid was required for sitting at an ongoing game or retrieving its state, but it is not the case. I don't understand how one can select an ongoing game. I hope Omar can find time to clear this up for us.
|
|
IP Logged |
|
|
|
omar
Forum Guru
Arimaa player #2
Gender:
Posts: 1003
|
|
Re: Standalone gameroom client -- what, why, how?
« Reply #7 on: Jan 12th, 2008, 4:44pm » |
Quote Modify
|
Good question. Actually my documentation for 'Reserve Seat' part was not right. You can specify role='v' if you want to get the gsurl and tid for just viewing a game. I've updated the protocol documentation. Thanks for noticing this froody.
|
|
IP Logged |
|
|
|
froody
Forum Guru
I <3 nurpinar
Gender:
Posts: 103
|
|
Re: Standalone gameroom client -- what, why, how?e
« Reply #8 on: Jan 18th, 2008, 10:42pm » |
Quote Modify
|
I did some work on RubyArimaa today. It can now retrieve and view postal games. It should work on all platforms. To run it you'll need Ruby and Tk installed. zip: http://phm.36bit.com/RubyArimaa_0_14_1.zip tar.gz: http://phm.36bit.com/RubyArimaa-0.14.1.tar.gz screenshot: http://phm.36bit.com/RubyArimaa.jpg Click the horse-camel button to connect to the server. The 'list' command in the console should display all your current games. Then typing 'open [game number]' will open a window displaying the game. You can move the pieces around but that's all. The elephant-dog button allows you to open a game file and step through a game using the '>' button. Next thing to do is checking for legal moves and animating the steps. To answer your questions (from April 07), Camelback: Yes, you're welcome to help. No, I haven't setup a Rubyforge project yet. I will do so if more people are working on the project. No, you don't need to know anything about go. Ruby and Tk experience is useful though. Using the go client as a base is nice because a lot of code is similar. Leo: Ruby is a wonderful language, and very easy/fun to learn. Hope you take a look at it. I'd also like to write some bot stuff in Ruby, too. I'll write some utility code for manipulating the board, etc, then anyone that knows a bit of ruby will be able to quickly put together their own bot and experiment with different ideas. This book is very entertaining if you want to learn ruby: http://poignantguide.net/ruby/
|
|
IP Logged |
“Arimaa holds its master in its own bonds, shackling the mind and brain so that the inner freedom of the very strongest must suffer”
|
|
|
leo
Forum Guru
Gender:
Posts: 278
|
|
Re: Standalone gameroom client -- what, why, how?
« Reply #9 on: Jan 19th, 2008, 3:39am » |
Quote Modify
|
I tried it and it worked although I was getting a lot of Tcl/Tk script error popups. Adapting an application can be trickier than devising one from scratch, but I'll try to understand how the Ruby source works, especially the nchess6.rb file which you modified to encode Arimaa game state. But errr... Ruby looks as cryptic as any other programming language - I don't buy the hype. For the 'learn to play better' item of the TODO list I can't help but you seem to be doing fine.
|
|
IP Logged |
|
|
|
froody
Forum Guru
I <3 nurpinar
Gender:
Posts: 103
|
|
Re: Standalone gameroom client -- what, why, how?
« Reply #10 on: Jan 30th, 2008, 4:16pm » |
Quote Modify
|
http://phm.36bit.com/RubyArimaa_0_14_5.zip New version. Quite a lot of changes. I'd really like to know which platforms it will run on. Should work on everything but I only test on ubuntu linux. Follow the install instructions from http://rubygo.rubyforge.org/ Click the elephant and dog button to play out a human vs human game. Right click flips the board. Does all the game logic work as it should? (pushing/pulling/freezing/trapping) Press 'done' to end the turn. 'undo' will undo the step.
|
« Last Edit: Jan 30th, 2008, 4:19pm by froody » |
IP Logged |
“Arimaa holds its master in its own bonds, shackling the mind and brain so that the inner freedom of the very strongest must suffer”
|
|
|
froody
Forum Guru
I <3 nurpinar
Gender:
Posts: 103
|
|
Re: Standalone gameroom client -- what, why, how?
« Reply #11 on: Feb 3rd, 2008, 5:28pm » |
Quote Modify
|
Wheeee. Just sent my first move to the gameroom using RubyArimaa.
|
|
IP Logged |
“Arimaa holds its master in its own bonds, shackling the mind and brain so that the inner freedom of the very strongest must suffer”
|
|
|
camelback
Forum Guru
Arimaa perl monger
Gender:
Posts: 144
|
|
Re: Standalone gameroom client -- what, why, how?
« Reply #12 on: Feb 3rd, 2008, 7:12pm » |
Quote Modify
|
Congrats froody!, great job looking forward to use it.
|
|
IP Logged |
|
|
|
The_Jeh
Forum Guru
Arimaa player #634
Gender:
Posts: 460
|
|
Re: Standalone gameroom client -- what, why, how?
« Reply #13 on: Feb 3rd, 2008, 7:41pm » |
Quote Modify
|
I'm using Windows XP, and I get the error message having to do with the method 'create' being undefined. Fritzlein, I heard you might have overcome similar difficulties. If so, please fill me in.
|
|
IP Logged |
|
|
|
froody
Forum Guru
I <3 nurpinar
Gender:
Posts: 103
|
|
Re: Standalone gameroom client -- what, why, how?
« Reply #14 on: Feb 3rd, 2008, 9:07pm » |
Quote Modify
|
I'm not sure if it was Fritzlein, but I seem to remember someone who tested it had the same error. I just realized that the way I'm making the image objects is different to how RubyGo works, so I might change it to be like RubyGo. But you tried RubyGo and that didn't work either? You can't play a human vs human go game? Does the board draw in RubyArimaa if you skip the error message? Does the board draw in RubyGo?
|
|
IP Logged |
“Arimaa holds its master in its own bonds, shackling the mind and brain so that the inner freedom of the very strongest must suffer”
|
|
|
|