Java-Gaming.org    
Featured games (79)
games approved by the League of Dukes
Games in Showcase (476)
Games in Android Showcase (106)
games submitted by our members
Games in WIP (533)
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 / Re: Game world objects on server and client on: 2007-03-22 12:45:16
Thanks tigeba, I think I get it Smiley

Jeff, do you mean the lg3d-wonderland project at https://lg3d-wonderland.dev.java.net/ ?
It that's the one, I need to contact them for access to their cvs server (which keeps asking me for a pwd when I try to checkout the source).
2  Game Development / Networking & Multiplayer / Re: Game world objects on server and client on: 2007-03-20 15:18:24
Thanks for your replies!

Quote
If you give us some more details about what you are trying to achieve, someone might be able to give you a firmer answer.

OK I have a "Character" class on the server and client that represents the players' characters. It has some attributes (name, skills, experience points, position) which values are changed on the server when the clients sends valid actions. The updates should be replicated to the clients (also to clients that don't "own" a character, if they have a character that "sees" the other)

Can you give a code example on how you would declare the classes in your solution endolf?

tigeba, I understand your solution for replication, except I don't know how the client and server classes' common interface fits in.

If I use a interface, what about the common attributes of the SimObject? Wouldn't it be better to have a base class which stores that data?

1  
2  
3  
4  
SimObject extends SimObjectBase implements ManagedObject, SimEventListener
{
   ..
}


Or maybe that's what you (endolf) mean with using a reference to a real object:

1  
2  
3  
4  
5  
SimObject implements ManagedObject, SimEventListener
{
   SimObjectBase data;
   ..
}

3  Game Development / Networking & Multiplayer / Game world objects on server and client on: 2007-03-19 17:31:42
Hi,

obviously persisent game world objects on the server need to implement the ManagedObject interface.

The game world objects of my app are the same on client and server (besides that I don't need them persistent on the client).

Should I use the same game world object (as ManagedObject) in my client or is there better solution?

Also how would you replicate the server objects to the client?

Greetings from Vienna
4  Game Development / Networking & Multiplayer / Re: Client Deployment on: 2007-03-14 17:45:09
It works, thanks a lot
5  Game Development / Networking & Multiplayer / Client Deployment on: 2007-03-14 16:56:41
I made a little chat client and I want it to send it to a friend for testing (actually to impress him).
I created a jar of my chatClient, but I am not sure what additional files I need to send him.
Obviously sgs/lib/sgs-client.jar, but it doesn't seem to work outside the SGS directory structure.

How can I seperate the sgs-client.jar from the server?

Regards,
Alexander
6  Game Development / Networking & Multiplayer / Re: Problems running the SGS on: 2007-03-14 14:18:05
First thanks to Jeff for the detailed description how to run 0.9 in eclipse.
Works great now!

Two Pitfalls I encountered:
1.) You must use a unix-style slash (/) in the .properties file for paths (e.g. com.sun.sgs.app.root=data/HelloWorld)
2.) There is a typo in VM arguments, the filenames start with "sgs-" not "sys-"
7  Game Development / Newbie & Debugging Questions / Re: Questions about Java on: 2007-03-11 18:24:55
I would start out by learning from a beginners book (can't recommend one, since I only got "java in a nutshell", which requires some programming knowledge)
8  Game Development / Newbie & Debugging Questions / Re: main - why doesn't it exit after a JFrame is created? on: 2007-03-09 19:01:19
thanks fletchergames!
9  Game Development / Newbie & Debugging Questions / main - why doesn't it exit after a JFrame is created? on: 2007-03-09 17:20:18
I am wondering why a program like the below does not destroy the JFrame right after it's creation, actually when main is left:

import java.awt.*;
import javax.swing.*;
import java.awt.event.*;

public class HelloWorld {
  public static void main(String[] args) {
    JFrame f = new JFrame("This is a test");
    f.addWindowListener(new WindowAdapter() {
       public void windowClosing(WindowEvent event) {
          System.exit(0);
       }
    });
    f.setVisible(true);
  }
}

After the setVisible there is no wait loop (do (while !bExit) {sleep(1);}...) or a message dispatcher (the latter being covered by swing I guess). The JFrame has only one reference, which is local to main. It should be destroyed when the end of main is reached, which happens almost immediately.

Especially strange is, the above program terminates when I leave out the setVisible. Huh
Pages: [1]
 

Add your game by posting it in the WIP section,
or publish it in Showcase.

The first screenshot will be displayed as a thumbnail.

pw (22 views)
2014-07-24 01:59:36

Riven (20 views)
2014-07-23 21:16:32

Riven (17 views)
2014-07-23 21:07:15

Riven (20 views)
2014-07-23 20:56:16

ctomni231 (48 views)
2014-07-18 06:55:21

Zero Volt (44 views)
2014-07-17 23:47:54

danieldean (35 views)
2014-07-17 23:41:23

MustardPeter (38 views)
2014-07-16 23:30:00

Cero (53 views)
2014-07-16 00:42:17

Riven (52 views)
2014-07-14 18:02:53
HotSpot Options
by dleskov
2014-07-08 03:59:08

Java and Game Development Tutorials
by SwordsMiner
2014-06-14 00:58:24

Java and Game Development Tutorials
by SwordsMiner
2014-06-14 00:47:22

How do I start Java Game Development?
by ra4king
2014-05-17 11:13:37

HotSpot Options
by Roquen
2014-05-15 09:59:54

HotSpot Options
by Roquen
2014-05-06 15:03:10

Escape Analysis
by Roquen
2014-04-29 22:16:43

Experimental Toys
by Roquen
2014-04-28 13:24:22
java-gaming.org 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‑gaming.org
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!