Hi !
Featured games (91)
games approved by the League of Dukes
Games in Showcase (757)
Games in Android Showcase (229)
games submitted by our members
Games in WIP (844)
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]
EgonOlsen (45 views)
2018-06-10 19:43:48

EgonOlsen (27 views)
2018-06-10 19:43:44

EgonOlsen (47 views)
2018-06-10 19:43:20

DesertCoockie (211 views)
2018-05-13 18:23:11

nelsongames (128 views)
2018-04-24 18:15:36

nelsongames (127 views)
2018-04-24 18:14:32

ivj94 (868 views)
2018-03-24 14:47:39

ivj94 (129 views)
2018-03-24 14:46:31

ivj94 (780 views)
2018-03-24 14:43:53

Solater (144 views)
2018-03-17 05:04:08
Java Gaming Resources
by philfrei
2017-12-05 19:38:37

Java Gaming Resources
by philfrei
2017-12-05 19:37:39

Java Gaming Resources
by philfrei
2017-12-05 19:36:10

Java Gaming Resources
by philfrei
2017-12-05 19:33:10

List of Learning Resources
by elect
2017-03-13 14:05:44

List of Learning Resources
by elect
2017-03-13 14:04:45

SF/X Libraries
by philfrei
2017-03-02 08:45:19

SF/X Libraries
by philfrei
2017-03-02 08:44:05 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!