Gravity Force 20

Gravity Force 20 Tileset Construction Guide

Custom graphics

Creating a new tileset involves the following steps:

  • Create an image with several layers (destructible, indestructible and blinking)
  • Create a json file describing the level and if it include objects such as racegates, magnets or cannons.
  • Create a Tiled External Tileset and optionally define terrain
  • Email the files to levels@gravityforce20.com and we will make it available!

We recommend using an image size of 256x256 as this allows for plenty of tiles and is also nice to work with in Tiled. Since Gravity Force 20 uses pixel precise collision detection and destructible levels you need to create different images for different types of material. Use the appropriate suffix:

However, notice that you only need to include the types you actually use. For example the custom race gates only includes indestructible tiles.

JSON description

Each tileset must a description in JSON format with these mandatory fields:

              {
              	"id": "same as filename",
              	"name": "name of your tileset",
              	"author": "your name",
              	"tileSize": {
              		"x": 16,
              		"y": 16
              	},
              	"objects": []
              }
              
You must also define all tiles that represent some special object, such as landing platforms, racegates, magnets or cannons. For each such tile you must add one game object. The position of the gameobject is using pixel position and our tools will automatically determine which tile this refers to.

LandingPlatform

Landing platforms are used for refueling the ships. It typically requieres 3 tiles (left, middle, right). This means that you must define 3 objects! Specify the left most coordinate of the landing pad and use "size" to specify the width.

                {
                    "type": "LandingPlatform",
              	    "size": 8,
                    "x": 8,
                    "y": 8
                },
                {
                    "type": "LandingPlatform",
                    "size": 16,
                    "x": 16,
                    "y": 8
                },
                {
                    "type": "LandingPlatform",
              	    "size": 8,
                    "x": 32,
                    "y": 8
                }
              

RaceGate

Race gates are used in pairs on race levels. Specify the coordinate in the middle of the gate and use "nr" for the race gate number. Please define 1 to 8! Make sure to make them indestructible!

                {
                    "type": "RaceGate",
              	    "nr": 1,
                    "x": 8,
                    "y": 8
                }
              

FixedCannon

Fixed cannons simply shoot at a fixed direction (up, down, left or right). Cannons can be either destructible or not. Specify the coordinate inside the cannon (this will be used to check if the cannon is destroyed). Notice: currently diagonal cannons are not supported, ie xdir or ydir must be 0.

                {
                  "type": "FixedCannon",
                  "destructible": true,
                  "xdir": 1,
                  "ydir": 0,
                  "x": 8,
                  "y": 183
                }
              

Magnet

Magnets pulls the ship towards them, either right or left. Make sure to make the magnets indestructible. Notice: currently only xdir is supported (left=-1 or right=1).

                {
                  "type": "Magnet",
                  "xdir": -1,
                  "ydir": 0,
                  "x": 8,
                  "y": 248
                },