Ray Kelm

  • About
    • Home
    • News

User Login

  • Create account
  • Reset password

Projects

  • SDL_gui
  • Cyclone
  • roaddemo
  • rtChess
  • exemel
  • gp2x
  • robot

Options

Recent News

  • leJOS NXJ for Mindstorms NXT
  • Chumby at work
  • Chumby!
  • And...
  • Busy busy busy...

News Tags

  • news (46)
  • cyclone (15)
  • SDL_gui (14)
  • robot (7)
  • chumby (3)
  • lego (3)
  • exemel (2)
  • nms (1)
  • work (1)
  • dev (1)
  • robofest (1)
  • rtChess (1)
  • roaddemo (1)
  • osgi (1)

Links

  • DataSlab Hosting
  • SellMySoftwareOnline!
  • SDL
  • YAAARC
  • FIRST
  • Arduino

Overview

Cyclone is an experiment in game technology. It's primary purpose is to help me learn more about game programming. So, as such, the design is probably somewhat uncommon.

This document describes the second generation of cyclone, which is still in development. The original version is currently available for download elsewhere on this site.

The primary requirements are as follows:

  • Is a top-view shoot-em-up with a space theme.
  • Will use 2 dimensional graphics.
  • Must support multiplayer in a secure fashion, considering that the code is open.
  • Must run on linux and win32.

I personally like top-view shooters, and there aren't nearly enough. 2D is simpler than 3D, although I might consider changing this requirement at some point in the future. Multiplayer is always fun, so that has to be there.

Initially, I wrote the code to support the top-view shooter as an excercise in how to use SDL in a real game application. This code has served it's purpose, and this design document is the pattern for the rewrite of the code. The original network code used UDP, then TCP. I plan to use this code to test the feasability of using TCP or UDP for internet play, although I really don't care if the game is playable over the internet at this point; local network play is my goal.

Cyclone Client Server Protocol Detail

Network Overview

I have decided to implement the network code using a client-server model. The client will send user commands to the server, which will execute all of the game logic. The server will report position information to the client for display. This model has more inherant latency, but it is the most secure model I could envision.

For the initial implementation, the server is going to be a seperate application. In later implementations, the two will be merged so that a user can host a game.

Also, initially there will be no computer controlled ships. Eventually, I want to include them, and subject them to the same constraints that human players have, in that they communicate to the server, and only see the updates that a normal player would see.

Cyclone Server Design Detail

Gameplay Overview

The user controls a ship which is flying though space. The size of the universe is fixed, and wraps around at the edges, so that it appears to be infinite in size.

The ship will be selectable by the user at the start of the game. Different ships have different statistics. Some of the numeric values will need to be adjusted to get good balanced gameplay. Additional ship types will be determined later.

One key thing is that there need to be many types of weapons available. Weapons can only be used if the correct powerups are found and collected. Additional weapons will be determined later.

User Interface

The first screen the user will see is the "select-server" screen, in which the user will either pick a server from a list of known servers, or enter the IP address or hostname. Once the server is selected, it will be contacted, and the different types of available ships will be displayed, along with their stats. The user will select a ship, and enter a nickname, then enter into the game.

The upper right corner of the screen will display a radar-like overlay which shows the proximity of other ships and powerups. The upper left corner of the screen will display a ship statistics overlay, such as health and weapon availability. The main area of the screen will display the top-down view of the game.

The universe background is generated on the client side, with the server only giving the position of the player in the universe with 16 bit resolution.

Initially all of the graphics will be contained on the client side, with the intention of later downloading the graphics from the server if they are not already present.

Cyclone Client Design Detail

Ship Details

  • Light: 300 hps, 200 pixels/sec top speed, 180 deg/sec max rotation
  • Medium: 400 hps, 150 pixels/sec top speed, 135 deg/sec max rotation
  • Heavy: 500 hps, 100 pixels/sec top speed, 90 deg/sec max rotation

Weapon Details

Pulse Cannon

A single shot cannon that takes a small amount of time to recharge. A hit does a maximum of 100 damage points, and the damage is determined by the time the shot had to travel. The shot travels at 600 pixels/second in a straight line, and after 1 second it does zero damage. The damage formula is as follows: 100.0 * (1-t)

Percussion Missiles

These shoot either one or two at a time. Each travels at 300 pixels/sec in a straight line. The missile explodes on impact, or at the end of the 2 seconds lifespan. An impact causes 100 damage points. A nearby explosion causes damage related to the distance from the explosion to the enemy. Distance is measured in pixels. The damage formula is 50.0 - D, where no damage occurs after 50 pixels of distance.

Heat-Seeking Missiles

These shoot either one or two at a time. Each travels at 250 pixels/sec, and tracks the nearest target, with a maximum rotation speed is 90 deg/sec. The missile explodes on impact, or at the end of it's 3 second lifespan. The damage is fixed at 100 damage points. A nearby explosion using this damage formula 25.0-D, where no damage occurs after 25 pixels of distance.

Armor-Piercing Missiles

These shoot either one or two at a time. Each travels at 400 pixels/sec in a straight line. The missile does not explode, and disintegrates after 1 second. A direct hit does 200 damaga points.

Lasers

Lasers are line of sight, with an instantaneous travel rate. Lasers can only shoot in short bursts, lasting 1/2 second. The distance the laser projects is 200 pixels, and the damage inflicted is related to the duration of the contact, and the distance to the target. The formula is: (200-D) * T.

Cyclone pages

  • Cyclone
  • Cyclone changelog
  • Cyclone screenshots
  • Cyclone downloads

Copyright © Ray Kelm. All rights reserved.

Valid XHTML 1.0 Strict Valid CSS!