in reply to GUI Package for easy drawing options
As far as Tk "not looking good"...it looks as good as the amount of "detailing" you want to put into it.
Gtk2 is coming on strong, but unless you are "expert" at objects, signals, and gui design, it will be harder to work with than Tk, plus Tk is definitely better tested on Windows, and easier to install ( it comes with ActiveStatePerl.)
Getting back to your design, I will tell you right away, you will have to work out some sort of "data transmission protocol" to keep your player's screens in "sync". What I mean is, you will not be able to "send objects thru tcp", you will be able to send hashes(or whatever) of positional(and gui details) data to your clients, then they will have to "update" their screens with that data.
For learning about it, I wrote a multiplayer "scrabble clone", which uses Tk Canvas, and Net::Easy::TCP. Its at ztk-babel client server game with chat. Feel free to look at it, and use it's code if you can figure it out. Right now, I'm playing with a poker game, using the same code, but I've turned it into an "object-oriented" design, which you may want to do. Why. It will get extremely complex trying to keep track of all the player's data, and if you make each player a blessed object, with internal methods, you will be able to simplify things. As you can see in ztk-babel, I use hash tables to send data, and I've reached the "breaking point of complexity". If I were to redo it, I would use a more OO design. Another pointer, is that Net::EasyTCP makes it easy to exchange "hashes of data", plus it has built in encryption and "port protection" , which will be important if you try to play your game on the "open internet", where you will get "port scanned and hacked" within minutes.
|
|---|