Java-Gaming.org    
Featured games (81)
games approved by the League of Dukes
Games in Showcase (498)
Games in Android Showcase (115)
games submitted by our members
Games in WIP (562)
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] 2 3 4
1  Game Development / Game Play & Game Design / Adding networking capabilities on: 2010-03-17 11:44:03
I added networking to my game, but I'm wondering where the best place is to send network messages.

My first idea was to add the network code to each action in the game wich results in this:
EndTurnAction

I think that is rather messy, as half of the class is networking code. So my second Idea was to move all network code in some kind of facade like

replace:
1  
2  
3  
4  
      case NETWORK_SNAIL_GAME: 
         endTurnInSnailGameMode();
         break;
 


with:
1  
2  
3  
      case NETWORK_SNAIL_GAME: 
         NetworkFacade.getInstance().endTurnInSnailGameMode(session);
         break;


 Now all the network code is grouped in 1 class NetworkFacade. Along with the catch blocks and GUI dialogs...

and then my last idea was to create a wrapper around the EndTurnAction class called the NetworkEndTurnAction class that ends the turn and sends a network message. But then I have to change the way I create new EndTurn Actions. if network then create network wrapper else create normal action?

An action is created in the ActionFactory like this:
1  
2  
3  
4  
5  
6  
7  
8  
9  
public class ActionFactory { 
  public static CWAction buildEndTurnAction() {
     ActionBag endTurnAction = new ActionBag("End Turn");
     endTurnAction.add(new ClearInGameStateAction());
     endTurnAction.add(new EndTurnAction());
     endTurnAction.setActionText("end_turn");
     return endTurnAction;
   }
 }


This is just 1 action ofcourse there are many more actions. Wich of the above 3 ideas would be the cleanest most beautifull/amazing/super way? Any hints on how this is normally done?
2  Game Development / Game Play & Game Design / Re: Actions on: 2009-03-19 14:51:28
That's awesome cylab, you come up with 2 solutions! I had to read them a couple of times to understand what you are saying but I got it now.
Actually storing all these game objects into 1 context object really simplified code on other places as well, think 1 parameter instead of 6...

and Jono you already came to the conclusion, I want to replay from the user perspective, and time is not an issue since it is an tbs, maybe i'll save the turn.
Solved!
3  Discussions / Miscellaneous Topics / Re: Worst OS ever? on: 2009-03-17 18:14:39
I used win ME for a good amount of time, and most of the time i was searching for tools to make it run faster, Installing freeware etc. I don't think ME ran faster after I installed my 'freeware tools'. Maybe if I didn't install anything it would run at the same speed == not using your pc. I think I formatted about every 6 months because it was going unbearable slow.
4  Game Development / Game Play & Game Design / Re: Actions on: 2009-03-17 12:20:34
I didn't say but the game doesn't change unless through an action.
5  Discussions / General Discussions / Re: TDD and Game Dev on: 2009-03-16 19:04:26
I wrote some junit tests(Cool, and they payed off when I was moving things around, but when it becomes time consuming I look at other stuff.
6  Game Development / Game Play & Game Design / Actions on: 2009-03-16 17:32:53
Can't sleep at night cus of this action mess that looked promosing at the start... let me explain.
I have an action object for each 'action' in my game like selecting a unit, moving from a to b, Attacking,etc
Each action has a doAction and undoAction method.
The idea for this was to allow to go back 1 step in a undo list, this worked using the swing Undomanager.

An example of that
Before the action is executed I set the (first) clicked tile in session, actions are stored in a map by name:
1  
2  
3  
4  
5  
session.setClick(1,tile)
Action selectAction = actions.get("Select")
selectAction.doAction()
if selectAction.canUndo()
  undoManager.add(selectAction)


selectAction.java
1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
14  
15  
16  
17  
18  
19  
20  
21  
22  
23  
24  
25  
26  
27  
28  
29  
30  
31  
32  
33  
34  
35  
36  
37  
38  
39  
40  
41  
/**
 * Select a unit and make it the active unit in the game. This is the first action
 * for a unit.
 */

public class SelectAction extends AbstractAction {
  private MapRenderer mapRenderer;
  private InGameSession inGameSession;
  private Game game;

  public SelectAction(Game game, MapRenderer mapRenderer, InGameSession inGameSession) {
    super("Select");
    this.game = game;
    this.inGameSession = inGameSession;
    this.mapRenderer = mapRenderer;
  }

  public void doAction() {
    selectUnit((Unit) inGameSession.getClick(1).getUnit());
    inGameSession.setMode(InGameSession.MODE.UNIT_SELECT);
  }

  private void selectUnit(Unit selectedUnit) {
    game.setActiveUnit(selectedUnit);
    mapRenderer.setActiveUnit(selectedUnit);
    mapRenderer.removeZones();
    mapRenderer.showMoveZone();
    mapRenderer.showArrows(true);
  }

  public void undoAction() {
    deselectActiveUnit();
    inGameSession.setMode(InGameSession.MODE.DEFAULT);
  }

  private void deselectActiveUnit() {
    game.setActiveUnit(null);
    mapRenderer.setActiveUnit(null);
    mapRenderer.removeZones();
    mapRenderer.showArrows(false);
  }
}


Now I want to replay the actions that happened in the game.
But I always reuse the same Action, I don't create new action objects... Action objects have a lot of constructor parameters and I want to execute actions @ places that don't have access to these objects.
Also the actions get their input from a session object limiting it's use. a MoveAction can only move from session tile 1 to session tile 2.
Following the Command pattern an Action can't have setters, it should get all information from the constructor parameters that's why I used the session object.

When I would save a replay it probably look like
Select 0 0
Move 0 0 11
Select 2 2
....
Every game has a replay system, how do they do it? & how can I use Action objects to replay all the actions.
7  Game Development / Game Play & Game Design / Re: MVC pattern on: 2009-02-04 20:01:35
But it is such an informative thread Grin no srry, I'll look at the date next time.
8  Game Development / Game Play & Game Design / Re: MVC pattern on: 2009-02-04 14:02:13
well I want to add my experience Grin
I've been breaking my head about what are models/controllers and views.

Model: Data, with simple actions does not interact with the surroundings
View: Renders the model, by events or by polling
They are both self contained, view does not change the model, model does not change the view.

Then comes the controller, which seems to get a different description each time i read about them.
Quote
Controllers are responsible for querying the world around their assigned entity, formulating a good action, and returning that to whichever Manager class is asking for an action.  Controllers have no ability to update the world - they just return instructions to a manager class such as 'Walk North' or 'Open Door'.  The manager class is responsible for checking the validity of this instruction and actually moving the game object or opening the door. 

I still don't get it. Maybe that's because I add functions to the game objects with validation instead of gameobjects that are just data with getter and setters. Could somebody explain the controller again  Undecided from the click from the user to the unit moving. Maybe then I can kick it into my head.

Quote
Managers conceptually should contain all the game logic.  Lately I've been orienting these around game states - which correspond to screens - same as renderers.  There is one master manager that keeps track of game state and calls an update method on any active 'children' managers. 

So Rule#1 a Unit can only attack if it has not been destroyed.

1  
2  
3  
4  
unitManager.attack(Unit attack, Unit defender) {
if !attacker.isDestroyed()
  attacker.attack(defender)
}

I did it a bit differently, I added an attack function to the unit and then where the rule should be checked I ask a rules object if the attack can be done.
ie. unit attack code:

1  
2  
3  
4  
attack(Unit attack, Unit defender) {
if rules.canAttack(attacker,defender)
attack(defender)
}


comes down to the same thing...

I have another question:
If a unit dies a dying animation is shown which ends after x ms. after that the unit should be garbage collected. This is the only time that I have the gui remove the unit from the model.

ie
1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
unit.die() {
setState(DYING)
}

unitSprite {
if state == DYING
anim = animDying

if dyingAnim has elapsed remove unit from model
unit.destroy -> will remove the unit from the model, but is called from the gui!
}


how can I avoid that?
9  Game Development / Newbie & Debugging Questions / passive rendered game on: 2009-01-13 12:56:38
What are the drawbacks of using repaint on swing components instead of using a game loop?
relative to the problems in a turn based game:
animated units, static terrain, animated menu, explosion animation, blinking stars, rain, snow(small images moving over the whole screen)
units should be 20% darker when inactive, and they stop animating.

I know
that painting and input both are passed in the awt event thread
that java2d can use software/hardware rendering

I don't know howto update the animations, should I use a swing timer and call update using that? or use gifs and let java update them for me.
But how do you stop a animated gif?

I though about creating a swing timer and let it call repaint every second. To allow a scrolling background for example.
10  Game Development / Newbie & Debugging Questions / Re: Networked Gaming on: 2008-12-12 02:12:20
Interesting topic! Mr_Light your making this into a tutorial or what  Smiley

To answer your q
well, you can split on spaces and have a string for each parameter.
search for array split

But that won't work for user W A C K O because it will return 5 whitespaces.
So to work around that you can prefix the username with the length of the username

1 = login
9 = amount to read
W A C K O = name
1 9W A C K O

I've been struggling with the same problem.
11  Discussions / Miscellaneous Topics / Your password must contain a mix of upper and lower case letters, as well as dig on: 2008-12-02 20:28:30
I can login again, after I forgot my password...
But why did I forget my password I never do.

Your password must contain a mix of upper and lower case letters, as well as digits.  is the reason why. I have like 4 passwords and none of them uses a uppercase letter, so I changed one of the 4 abit and the next time i visit the site I have to think(ouch) and try 3 passwords before i'm locked out  Shocked

Isn't this a bit too restrictive? Email sites don't even require this and this forum does?

12  Games Center / Archived Projects / Re: Turnbased simultaneous strategy on: 2008-11-05 21:36:30
I did a test play again the creator I had some trouble to start(because I was joining as spectator, loosing focus when returning to chat,...)
But after a while I figured it out:

There is no big end turn button you have to click ready
Max allowed units is 4(so all is not lost when you can't create any units anymore)
The game is fullscreen so all attention goes into the game which is good no distractions.
The gui in the fullscreen window does need work, overlapping Panels, every repaint the chatbox changes position(from left to right) and defaults to somewhere in the middle of the scrollArea (which is very annoying)

After that It was cool to move or should i say attack around, build new units, etc. promising game I will certainly return for another game.
Btw I have to say registration went very smooth.
13  Game Development / Newbie & Debugging Questions / Re: Active rendering + modal dialog? on: 2008-10-11 17:18:26
ok, I was thinking to work around the thread blocking.

But for example the JFileChooser just blocks all threads?
How can Swing still work if all threads are waiting?

I have a JDesktopPane and already created a modal JInternalFrame by setting the glasspane visible and ignoring mouse clicks from an online guide.
14  Game Development / Newbie & Debugging Questions / Active rendering + modal dialog? on: 2008-10-11 14:37:53
Hi, I'm active rendering swing

but when I display a modal dialog the gui doesn't respond anymore(I have to resize the component to see changes)
My gues is that a modal dialog just blocks all other threads.
Would it be possible to allow my active rendering thread to keep running+displaying a modal dialog?
15  Game Development / Game Play & Game Design / State-Controller-View-Model on: 2008-10-08 14:46:15
Hi,

I can't figure out how these objects should interact with each other
using Active rendering

I'll try to say what I have now:
State -> Handles one gui(MainMenu, InGame), is painted/updated every gameLoop
Controller -> a list of functions that can be applied to the model, should that contain mouseLeftClick() handles left clicks or select() handles left click logic :/
View -> paint/update itself, direct access to model
Model -> send notification when something changed to the view
UserInput -> Swing Actions a view invokes an Action and the action then handles the request(the actions will needs view and controller objects)

Should the State paint/update the gui? or should the state call paint/update on the controller and then paint/update the gui.
16  Game Development / Newbie & Debugging Questions / Re: reading/storing configuration on: 2008-09-29 13:53:47
I found the successor of Properties,... Preferences!

stores/reads xml
it has getBoolean() amongst others.
17  Game Development / Newbie & Debugging Questions / Re: Buttons on: 2008-09-27 10:12:40
Lookup David Brackeen on google search for his 2003 book search for the Animation class, that's all you need to animate a bunch of images.

when left is pressed(and hold) you use the leftAnimation
when released you use the standardAnimation.

and a sprite has 1 animation
18  Game Development / Newbie & Debugging Questions / reading/storing configuration on: 2008-09-26 13:44:05
Hi,

I'm trying to read a config file like this:

1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
14  
<MapRules>
   <Rule>
      <Name>TerrainsToBeFoggedWithinLos</Name>
      <Value>FOREST</Price>
   </Rule>
   <Rule>
      <Name>BuildingsToBeFoggedWithinLos</Name>
      <Value>CITY,FACTORY,PORT</Price>
   </Rule>
   <Rule>
      <Name>FogOn</Name>
      <Value>true</Price>
   </Rule>  
</MapRules>


I know howto read it out the xml file(using org.w3c.dom) ,
but I don't know how to store it(in a good way) into java

I want to get the correct type, support lists

If i would create a hashmap:

1  
2  
3  
4  
5  
  private static HashMap<String, Object> rules;

  public static Object getRule(String rule) {
    return rules.get(rule);
  }


Then my ide complains that it is unsafe to get it directly
    List<TerrainType> foggedTerrains = (List) Rules.getRule("TerrainsToBeFoggedWithinLos");
    List<BuildingType> foggedBuildings = (List) Rules.getRule("BuildingsToBeFoggedWithinLos");

Should I create getInt, getByte, getList ? or ...
19  Game Development / Newbie & Debugging Questions / Removing GameObjects(Units) on: 2008-08-30 17:53:13
Hi,

I'm having troubles to remove an entity and it's bound sprite object when it should die.
a unit is an entity
an entity has 3 states:
IDLE, DESTROYED,

My design:
gameState has ref to model and gui
when model changes event is sent to gui
gui can read from the model

So:
2 units batter
1 units hp is 0
that unit changes to the DESTROYED state

the gui sprite reads the state and changes to the explosion animation:
inside the sprite:
if ent.getState() == destroyed
 setAnim(explosion)
 
I know how long the explosion anim would take
...
the explosion anim is done.

Now how should I remove the entity in the model...
I know howto remove an entity: map.getTile(0,0).setEntity(null) and that's it.
But

I can only remove it when the explosion time has elapsed.
else the sprite won't paint itselfs(ie the explosion) anymore
I can not remove it from within the gui(see my design)

my painting code:
for(Entity ent : map.getAllEntities()) {
   if(spriteCache.contains(ent) {
    spriteCache.get(ent).paintComponent(g);
   } else {
   // Create new sprite for this ent.
   }
}

So if i remove the entity in the model it will not be painted anymore :/

I can think of one way remove the explosionAnim from the unitSprite and add it to the main gui
then if ent.state == destroyed play the anim and when done remove the sprite bound to the ent.

What other solutions are there. or what is the general way to handle this problem.
20  Game Development / Game Play & Game Design / Re: Need some advice in creating my game the right way. on: 2008-04-22 15:51:46
Chapter5 on http://www.brackeen.com/javagamebook/#download includes a full screen game,
think you might be interested in the ScreenManager.

good luck with your game
21  Game Development / Game Play & Game Design / Re: Need some advice in creating my game the right way. on: 2008-04-22 09:40:35
You can look at this discussion:
http://www.java-gaming.org/forums/index.php?topic=15140.15
22  Game Development / Newbie & Debugging Questions / Re: Games & Gui on: 2008-04-21 16:38:38
Though this isn't what you're asking about, here is some feedback.

The usual thing to do is to override the paintComponent method of the panel and draw whatever part of the map is visible.  Instead of changing the position of the panel, just store variables indicating which tile is currently at the top-left and draw whatever tiles are currently visible.

Additionally, it would be better if you couldn't scroll past the edge of the map, though that's a separate issue.

I didn't play the game; I just looked at it and scrolled around.

Noo, you misunderstand me  Cheesy
The 'InfoPanels' that show tile & unit information that's are the ones that flicker badly when moved using setPosition()
I do scroll using a leftTop Point.

Agreed need to fix the out of bound scrolling(having problems with it)

and draw whatever tiles are currently visible.
I just draw every Tile in the map, aren't drawing operations outside the panel bounds ignored?
23  Game Development / Newbie & Debugging Questions / Re: Games & Gui on: 2008-04-13 12:01:25
I solved it  Grin

First remove the panel
update the position
add the panel again
24  Game Development / Newbie & Debugging Questions / Re: Games & Gui on: 2008-04-12 20:43:40
Swing doesn't flicker when I don't move stuff around(except for the Tile Image)

1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
14  
15  
16  
17  
18  
19  
20  
21  
22  
    
  public void moveOverTile(Tile t) {
    Point leftTop = mapPanel.getLeftTop();
    Dimension mapPanelDim = mapPanel.getSize();
    if (t == null) {
      return;
    }

    // Is the current Tile position on the left side of the mapPanel(viewArea)
   boolean move = leftTop.x + (t.getCol() * map.getTileSize()) <= mapPanel.getWidth() / 2;

    // check for change
   if (leftSide != move) {
      leftSide = move;

      if (leftSide) {
        tileInfo.setAbsolutePosition(mapPanelDim, TileInfo.Position.LOWER_RIGHT);
      } else {
        tileInfo.setAbsolutePosition(mapPanelDim, TileInfo.Position.LOWER_LEFT);
      }
    }
}


TileInfo:
1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
14  
15  
16  
17  
18  
19  
20  
21  
  public void setAbsolutePosition(Dimension dim, Position pos) {
    Point currentLocation = getLocation();
    int x = 0, y = 0;
    switch (pos) {
      case LOWER_LEFT:
        x = LEFT_MARGIN;
        y = dim.height - HEIGHT - BUTTOM_MARGIN;
        break;
      case LOWER_RIGHT:
        x = dim.width - WIDTH - LEFT_MARGIN;
        y = dim.height - HEIGHT - BUTTOM_MARGIN;
        break;
    }

    // If one coordinate changed we need to change it's position!
   if (x != currentLocation.x || y != currentLocation.y) {
      setLocation(x, y);
    } else {
      System.out.println("stop calling this function, i already changed...");
    }
  }


I don't see the System.out message so that's good :p
before i was setting the location for every update, but that wasen't the cause of the problem... I still get Flickering.

When setLocation is called i can see a rectangle from old to new position being drawen in the background color(grey)
the rectangle has the same height as TileInfo.getHeight and the width is the same as TileInfo.getWidth()
what can be the cause of this rectangle?
I think it's some kind of dirty rectangle but that's supposed to be blocked?

I disabled automatic repaintings as in http://www.java-gaming.org/forums/index.php?topic=15140.15
so how does that rectangle get's there anyway?
25  Game Development / Newbie & Debugging Questions / Games & Gui on: 2008-04-12 01:59:20
Ok here it goes.

I'm making a simple 2D tile game, would it be smart to goto slick instead of java2d as i'm doing now?
I only paint images, all 2D.
atm i'm using swing Actively rendering and it flickers as you can see here(move your mouse to the left and right edge)
http://www.kwbbz.be/Downloads/Java/versions/test/test.jnlp
the tile image itself also flickers(while it doesn't get moved around)
I don't know how to fix it, I need a hud to display stuff and I only know Swing
When I won't use Swing is everything drawen at a fixed pixel position?
26  Game Development / Performance Tuning / Re: fps drops after brightening tile images on: 2008-04-10 09:07:42
got it! I first need to copy the other image  Cheesy

1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
14  
15  
16  
17  
18  
19  
  public BufferedImage grabImage(int width, int height, BufferedImage srcImg, int col, int row) {
    BufferedImage copy;
    Graphics2D graphics;
    int transparency = srcImg.getColorModel().getTransparency();

    // Create new Image
   copy = this.gc.createCompatibleImage(width, height, transparency);

    // create a graphics context for the new Image
   graphics = copy.createGraphics();

    // copy image from srcImg to copy
   graphics.drawImage(srcImg, 0, 0, width, height,       // copy img rectangle
           (col * width), row * height,                  // source img top Left rectangle cord
           ((col + 1) * width), (height * (row + 1)),    // source img lower Right rectangle cord
           null);
    graphics.dispose();
    return copy;
  }

solved, on to the next
27  Game Development / Performance Tuning / Re: fps drops after brightening tile images on: 2008-04-09 23:19:22
oops indeed i created the effect time after time...

1  
2  
3  
4  
5  
6  
7  
8  
9  
  
  // Create additional darker Terrain images, used for Fog
   for (BufferedImage img : terrainImages) {
      BufferedImage darkerCopy;
      darkerCopy = new BufferedImage(img.getWidth(), img.getWidth(), BufferedImage.OPAQUE);
      Graphics2D g = (Graphics2D) darkerCopy.getGraphics();
      imgSFX.drawBrighterImage(g, darkerCopy, 0, 0, 0.5F);
      darkTerrainImages.add(darkerCopy);
    }


I'm trying to make the darker images in the constructor of my map, but it shows a black square when i paint.
is there something wrong with the code above? I don't see it.

OPAQUE means all pixels should be drawen
It's not giving a null pointer exception so it's there already
I used the 0.5 before should make it a bit darker. but not black!

1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
  private void paintTerrain(Graphics2D g, Terrain terrain, boolean fogged) {
    if (terrain != null) {
      BufferedImage buf;
      if (fogged) {
        buf = darkTerrainImages.get(terrain.getType().ordinal());
      } else {
        buf = terrainImages.get(terrain.getType().ordinal());
      }
      g.drawImage(buf, 0, 0, null);
    }
  }


@CaptainJester
I would like to stick to java2D atm
28  Game Development / Performance Tuning / fps drops after brightening tile images on: 2008-04-09 20:41:02
Hi when running at no limit i get 100 fps
when i run this code for every tile on my map (30x30) the fps drops to 8.
Is there a better way to brighten/shade Bufferedimages?

1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
14  
15  
16  
17  
18  
19  
20  
21  
22  
23  
24  
25  
26  
    /* Draw the image with changed brightness, by using a RescaleOp.
    Any alpha channel is unaffected. */

  public void drawBrighterImage(Graphics2D g2d, BufferedImage im,  int x, int y, float brightness) {
    if (im == null) {
      System.out.println("drawBrighterImage: input image is null");
      return;
    }

    if (brightness < 0.0f) {
      System.out.println("Brightness must be >= 0.0f; setting to 0.5f");
      brightness = 0.5f;
    }
    // brightness may be less than 1.0 to make the image dimmer

    RescaleOp brigherOp;
    if (hasAlpha(im)) {
      float[] scaleFactors = {brightness, brightness, brightness, 1.0f};
      // don't change alpha
     // without the 1.0f the RescaleOp fails, which is a bug (?)
     float[] offsets = {0.0f, 0.0f, 0.0f, 0.0f};
      brigherOp = new RescaleOp(scaleFactors, offsets, null);
    } else   // not transparent
     brigherOp = new RescaleOp(brightness, 0, null);

    g2d.drawImage(im, brigherOp, x, y);
  }
29  Game Development / Game Play & Game Design / Re: mvc view on: 2008-04-07 15:00:58
ok, so I made my turn based game, client/server with cmv.

Defenitions:
ClientModelController: Take gui pixel locations/network col,row locations transform them to Tiles call GameController functions
ServerModelController: Take col, row locations, transform to tiles call GameController functions
GameController: Take Tile positions, make game changes holds game Logic

So far the GameController didn't do anything else then changing the game.

But now I want to add a 'travel over active units' function so when i press tab the next unit is selected, where would I put all the units of a player?
Can a GameController have a get function? like getUnits(Player p)
and then store those in clientModelController? Undecided

here is the src of the GameController:
http://jadvancedwars.cvs.sourceforge.net/jadvancedwars/trunk/src/common/controller/GameController.java?revision=1.9&view=markup
and of the ClientModelController:
http://jadvancedwars.cvs.sourceforge.net/jadvancedwars/trunk/src/client/controller/ClientModelController.java?revision=1.10&view=markup

The player class atm contains only player data like.
1  
2  
3  
4  
  private int id;             // Unique Number for identification within a map.
 private String name;        // Unique Name for this player, used in the gui
 private Color color;        // Unique
 private int budget;         // Amount of money that can be spend

So it's not an option to store in there.

I know how to code the function, just not sure where to put the units/player
30  Games Center / Showcase / Re: Multiplayer top-down view shooter on: 2008-03-20 21:50:58
Hi, mayby a dumb question

atm I use a String msg to talk between server/client. I'm just wondering what does Mina uses?
does it send some kind of byte sequence that forms a command object, does it send whole objects?

or in short, how did you 'talked' on the network.
I browsed through the src networking folder but couldn't see what was going on.

and what are your toughts about http://www.brackeen.com/javagamebook/#download chapter6? have you used it? would it be more game friendly then mina?
Pages: [1] 2 3 4
 

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

The first screenshot will be displayed as a thumbnail.

BurntPizza (28 views)
2014-09-21 02:42:18

BurntPizza (18 views)
2014-09-21 01:30:30

moogie (19 views)
2014-09-21 00:26:15

UprightPath (27 views)
2014-09-20 20:14:06

BurntPizza (29 views)
2014-09-19 03:14:18

Dwinin (45 views)
2014-09-12 09:08:26

Norakomi (74 views)
2014-09-10 13:57:51

TehJavaDev (100 views)
2014-09-10 06:39:09

Tekkerue (50 views)
2014-09-09 02:24:56

mitcheeb (71 views)
2014-09-08 06:06:29
List of Learning Resources
by Longor1996
2014-08-16 10:40:00

List of Learning Resources
by SilverTiger
2014-08-05 19:33:27

Resources for WIP games
by CogWheelz
2014-08-01 16:20:17

Resources for WIP games
by CogWheelz
2014-08-01 16:19:50

List of Learning Resources
by SilverTiger
2014-07-31 16:29:50

List of Learning Resources
by SilverTiger
2014-07-31 16:26:06

List of Learning Resources
by SilverTiger
2014-07-31 11:54:12

HotSpot Options
by dleskov
2014-07-08 01:59:08
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!