NetRumble – options menu, bots and video

As I said in the previous post I was thinking about the best way to automate the gameplay in the game and I decided to go with the artificial intelligence and implemented some logic in order for the ships to move around and shoot and make some sense doing so. Basically, they just wonder around the arena up to a maximum distance from the center (for them not to get stuck in corners) until they get close enough to an enemy ship in which case they initiate the pursuit and try to shoot them. A small trick for them not to just get stuck to each other was to define a minimum distance that they try to maintain from the enemy.

Since the number of options was growing I’ve added an options menu where it’s possible to configure desired resolution, to run or not in full screen, enable/disable bots and others.

Following is a video of the 2 bots as seen by the client (host is the green one) using VFC to reduce the network load. It’s possible to see in the video the varying quantity of data received (in Bytes per Second - shown on the bottom to the left) by the client depending on the distance of the enemy and asteroids. It’s also clear that there the enemy makes some “jumps” when he’s coming from outside the larger circle (which indicate the different consistency zones) due to inconsistency between the opponents’ known position and “real” position.

Net Rumble Gameplay with VFC
Technorati Tags: ,,,,

2 thoughts on “NetRumble – options menu, bots and video”

  1. Hello, Nice work so far! Im curious about your conclusions of VFC and if you managed to solve the remaining issues. I was planning to restruct NetRumble in the same way as you did (Sending all data through the host and just updating nearby players) when I randomly stumbled upon your blog. Im gonna try to create a team based capture the flag space shooter game for fun. What was your experience regarding the latency – Would the game benefit from implementing a predection based positioning in the client?

    Hope everything went well with the report!

    Thanks in advance,

    Peter Nero, [email protected]

  2. Hello and welcome,
    It’s nice to see it’s not just me reading this stuff.

    About the change to client-server there are a couple tricks I noted here in the blog. If you stumble upon some difficulty I’ll be glad to help. You can email me at [email protected]

    The game definitely needs some kind of client-based prediction so it can support the announced number of players. I implemented the most basic one, which is to keep making the same movement/firing for all players in the game. This is corrected by periodic status messages that re-position the ships. From here on there’s a lot of space to evolve since you can make those corrections smoother to avoid leaps in ships positions.

    Hope your progress is going fine.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.