Hi !
Featured games (90)
games approved by the League of Dukes
Games in Showcase (707)
Games in Android Showcase (208)
games submitted by our members
Games in WIP (781)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
   Home   Help   Search   Login   Register   
  Show Posts
Pages: [1]
1  Game Development / Networking & Multiplayer / GLO advice + ~bug found in SwordWorld demo on: 2006-06-30 23:53:48

(1) I would like some advice regarding the design of GLOs, in particular the sort of scale that one GLO should occupy (in terms of object size/responsibilities). i.e.:

If I want to represent AI players in, say a local world of 50 players (Human and AI), should I just have one GLO to represent all the AI players, or an individual GLO for each one? Should I avoid using GLOs at all for AI players?

 I am aware that this all depends on the type of application/load/users/world size etc., but just some ideas or tips more than anything would be useful.

(2) I believe I have found a 'bug' in the SwordWorld java code, though it might be deliberate or already have been fixed in newer versions: For ages I could not figure out why my simple server program (which is very similar to was never 'remembering' players (by this I mean it never seemed to find existing GLOs for players logging on repeated time). Looking at, the problem (if it is considered one) lies in the fact that when a GLO is _not_ found (the initial lookup gives == null), the ensuing operation to create it does not include the player name just used:

i.e. the line: 
            playerRef = simTask.createGLO(playerTemplate);

should be

             playerRef = simTask.createGLO(playerTemplate, playerName)

Without that, the GLO created in the absence of a searched-for GLO is 'nameless', 'never' to be found again.  Grin

Best wishes

2  Game Development / Networking & Multiplayer / ByteBuffer allocations and object members in GLOs on: 2006-06-27 23:16:37

I have a question which I think has an obvious answer, but I will ask it anyway :-) Regarding the ByteBuffers etc. required to represent a message to be sent from server to client, say if I have a GLO which needs to send players information about other players present in the GLO (room)

* When and how should this be declared? Should I always create the buffer on the fly (e.g. with allocate), or would it be better to use an object member and therefore a reususable buffer? In the simple SwordWorld example, for instance, you do a ByteBuffer.allocate() and put() a String into the buffer, and send it, for each request. If I make it an object member (i.e. in the class definition for a GLO), won't I get problems with serialisability?

What is the right approach (or at least, what are some good guidelines?)

3  Game Development / Networking & Multiplayer / Re: Help getting remote clients to work on: 2006-06-21 16:25:28
Okay sorry but I seem to have 'fixed' the problem, sorry! I need to vary the address used depending on whether the client is LAN or WAN-side
4  Game Development / Networking & Multiplayer / Re: Help getting remote clients to work on: 2006-06-21 16:00:54
I'm am wondering if the problem is in a combination of the parameters I use for FakeDiscovery (client) and deploy.xml (server):

I have just got another client to connect via the LAN by ensuring the host field in FakeDiscovery ( is used as the host field in the deploy (, as opposed to Why is this, and how can I get it to work for remote clients?

As you can tell my networking knowledge is limited at best.
5  Game Development / Networking & Multiplayer / Help getting remote clients to work on: 2006-06-21 15:26:08
Hello, I have a toy example very like the SworldWorld program 'working' - the server runs fine, and clients programs connect when both are run on the same machine. Recently I got my friend to try and connect from their machine, but the program would close seconds after starting and no user/password box would ever pop up. I thought that this would be due to firewalls or something. But:

I have disabled my firewall, and even a client on the same LAN can't connect! I know it is not a port issue since I can reach, say, a web server running on the same port I run the game server on.

Am I doing something really stupid?

Thanks for any help
Greg Scott
6  Game Development / Networking & Multiplayer / firstBoot meaning? on: 2006-06-08 15:56:08

I've been playing with the SwordWorld demo and I would like someone to clarify when firstBoot is set to true/false and how you can force it to happen again. My understanding is:

* firstBoot is true if the server has no persistent record of the application having run (i.e. in the database), false otherwise
* By deleting persistant_store in the release/sgs-ea1 directory, you effectively wipe the memory so firstBoot will be true for the next time you start the app

But this doesn't seem to happen every time. For instance, I might delete the directory and re-run the server but firstBoot is not true.

Should I be doing something else/in addition? Could someone clear this up for me?

7  Game Development / Networking & Multiplayer / Re: Representing geography in SGS on: 2006-04-17 22:05:03
On a related note, could someone offer guidance as to a reasonable approach to maintaining consistency between players in a physical/geographical world (such as a small multiplayer game). In particular, does one

* Have a player broadcast information about their whereabouts and movements directly to all other players, bypassing the server or
* Make sure every such thing goes through the server?

Thanks for any help
8  Game Development / Networking & Multiplayer / Representing geography in SGS on: 2006-04-16 19:11:54

I was wondering if someone from the SGS team could give some advice regarding how a physical game world could be represented within the SGS framework (i.e. in terms of GLOs etc).

I understand the tutorial well, and the idea of having GLOs representing entities (players, NPCs, etc.) but what approach should I take if I want to create, say, a mulptiplayer/RPG-type city with buildings and roads, i.e. one in which there is real space and coordinates etc. Does one try and divide it up into GLOs, or have one big GLO? Obviously I don't want to start out on the wrong foot, and I'm sure my query is a common one. I especially don't want to hard-code the design of the world into the source code, clearly, rather I'd like to have the world created on startup by, for example, parsing an XML file representation (created in a world designer program etc.)

Any suggestions, examples or pointers would be greatly appreciated. Thank you and keep up the good work.

Greg Scott
Pages: [1]
Galdo (428 views)
2017-01-12 13:44:09

Archive (583 views)
2017-01-02 05:31:41

0AndrewShepherd0 (1055 views)
2016-12-16 03:58:39

0AndrewShepherd0 (979 views)
2016-12-15 21:50:57

Lunch (1113 views)
2016-12-06 16:01:40

ral0r2 (1345 views)
2016-11-23 16:08:26

ClaasJG (1439 views)
2016-11-10 17:36:32

CoffeeChemist (1423 views)
2016-11-05 00:46:53

jay4842 (1506 views)
2016-11-01 19:04:52

theagentd (1253 views)
2016-10-24 17:51:53
List of Learning Resources
by elect
2016-09-09 09:47:55

List of Learning Resources
by elect
2016-09-08 09:47:20

List of Learning Resources
by elect
2016-09-08 09:46:51

List of Learning Resources
by elect
2016-09-08 09:46:27

List of Learning Resources
by elect
2016-09-08 09:45:41

List of Learning Resources
by elect
2016-09-08 08:39:20

List of Learning Resources
by elect
2016-09-08 08:38:19

Rendering resources
by Roquen
2016-08-08 05:55:21 is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!