Custom Level Design

   

This section is for those people interested in creating their own levels for the game.    The game has been designed specifically so that people can create or download additional levels.  To use custom levels, simply put the custom level files in the RocketElite Custom directory.

Four files make up a custom level:

Level Description File a .TXT file that describes all the specifics about the level including start location, powerups, enemies, level requirements, etc.
Level Description Image File a 240x320 .PNG file that is displayed as the level is loaded.
Level Image File a 750x750 .JPG file that is the image of the entire level.
Level Mask Image File a 750x750 .PNG file that graphically describes the location of obstacles, water, etc. 

In Addition, there are two optional files:

Sprites File a 240x320 .PNG file that describes all the sprites used in the game.   This will allow designers to add custom sprites, or change the look of the ship, enemies, etc.
Backdrop File a 240x320 .PNG file that can be used to skin the top and bottom bars differently and change the look of the guages.

Also, if players would just like to create their own levels or modify one of the existing levels using the level graphics included with the game, then all that is required is the Level Description File. 

The following describes each file in detail so that interested players can begin to create their own levels.

 

Level Description Image File

   

The level description image file is the simply the image displayed while your level loads.  Typically this screen includes a description of the level as well as any primary objectives and secondary or things to watch out for.  You may also wish to include author information and anything else pertinent to the level.

The dimensions of the image itself needs to be 240 pixels in width and 320 pixels in height (ie. 240x320)  The image should be compressed as a jpeg image (ie. JPG)  Also, you need to keep in mind that the top 26 pixels and the bottom 14 pixels of your image will be overwritten by the game screen.

A good place to start would be to start with a blank image with the game screen areas already clearly marked.  Click here to download a starter image to work from.  Your final image need not include the game screen imagery, it will appear automatically during play.

Level Image File

   

The level image file is the actual level image you see during gameplay.  This image should contain everything you want people to see in levels with the exception of the powerups, they are added automatically by the game during play from the information stored in the Level Description File.

Specifically, every level in RocketElite is 750 pixels in width by 750 pixels in height, (ie. 750 by 750)  Click here to view an example Level Image File.  This is the part of the level design that you want to probably put the most effort in since it is where the game is actually played and what the player sees.  This is also where you have the ability to really show off your artistic talents.

A level file can wrap around horizontally, in which case you would want to make sure that when your level image file is tiled horizontally, they match up.  Otherwise you will see a break in the level as you scroll around from the far right side of your map to the far left side during play.  Whether a level wraps horizontally or not is set in the Level Description File.

The file itself is stored as a jpeg image (ie. JPG)

Level Mask Image File

   

This is one of the more challenging or difficult part of designing the level.  This file is how the game is able to decern where the ground or obstacles are located within the game.  In addition, it also uses this information to determine where scorable landing locations are and also where fuel and shield regeneration landing pads and water are located.  With this graphic image, you will be able to tell the game regarding any flat potential location: whether the player gets score for landing there, whether sitting on the landing area will regenerate fuel, and whether sitting on the landing area will regenerate deflector shields.

The way this is done is by using different colors.   Please reference the picture on the right while considering the information below.

First off, the majority of the mask image itself will be black and blue.  The black areas correspond to places where the player can fly without risk of exploding.  The blue areas correspond to solid areas where the player cant fly and will explode if he touches even a single pixel of the blue area.

Keep in mind that the player will never see the mask image, it's purely for the game itself to calculate things like crashes and landings.

The most difficult part of making the mask image is that it needs to match the Level Image perfectly.  If it does not match, the player will be able to fly through walls or will just explode in open areas as a result.  One suggestion for easily creating a Level Image and matching Level Mask Image would be to use a drawing program that supports multiple layers so that after you create your Level Image, you can go create the Mask Image.  Another possibility would be to create the Mask Image first and work from there.  One final suggestion for testing a level would be to make the Level Image exactly the same as the Mask Image.  This will allow you to test Mask Image while also being able to see it in the game while you test your level.

Landing Platform Information

If you want to make a landing platform unscorable, you need to highlight the top pixel of the landing pad on the mask image on that platform to bright purple (each pixel has to be exactly Purple--Red: 255, Green: 0, Blue: 255).  Remember to make the purple extend across the entire platform otherwise you may get undesired results.  The game uses the width of the line and how close the ship lands to the center of the pad to calculate the score of the given platform.

Fuel Regeneration

In order to make a platform regenerate fuel while landed on the platform, you need to highlight the second to the top pixel of the landing platform on the mask image on that platform to bright purple (each pixel has to be exactly Purple--Red: 255, Green: 0, Blue: 255).  This example is shown on the right.  Remember to make the purple extend across the entire area that you would like the platform to regenerate fuel.  Typically you would want the regeneration pixels to span the entire landing pad.

Shield Regeneration

In order to make a platform regenerate shield while landed on the platform, you need to highlight the third to the top pixel of the landing platform on the mask image on that platform to bright purple (each pixel has to be exactly Purple--Red: 255, Green: 0, Blue: 255).  This example is shown on the right.  Remember to make the purple extend across the entire area that you would like the platform to regenerate fuel.  Typically you would want the regeneration pixels to span the entire landing pad.

Since Fuel and Shield regeneration are special powerups, you probably would only want to use them in very specialized areas.  Most likely all of your platforms would just be a regular scored landing pad.  

A following is a summary of what happens when you land on a platform depending on how the mask image is drawn:

There are other items that are included on the mask image that aren't finalized yet.  These specifics will be documented here once the Retail Version is complete.

Water

The mask color for water is green (each pixel has to be exactly Green--Red: 0, Green: 255, Blue: 0).  In addition to setting up the mask image for water, you will probably want to add an environmental effect (the bubbles as seen in the RocketElite demo.)  Specifics will be added here later.

 

Level Description File  

   

This file describes all the specifics about a level.  For example, where powerups are located, how much gravity a level has, scoring information, starting location, etc.

Shown below is a sample Level Description File.  The Description File is still under development at this point, so this is really just an example of the type of file necessary to describe level specifics.

[map,the moon] // Will load the moon.jpg for level image, the moon.png for level mask info
[fuel,100] // initial fuel value (as a percentage)
[shield,0] // initial shield value (as a percentage)
[start,275,100,0,50,0] // start x (0-749), start y (0-749), x velocity (-511-+511), y velocity (-511-+511), sprite (0-35) 

[popcolor,100,100,255] // Red, Green, and Blue values of special effects for the level.
[gravity,4] // Gravity. Large=more gravity. Zero=no gravity

[nextlevel,mars] // Filename of next level

[req_powerup,6,2] // Exit Requirement
[req_powerupmes,Rescue Astronauts]
[exit,0,0,750,20,0] // Level Exit Location

[powerup,0,610,650] // fuel barrel
[powerup,1,393,363] // deflector shield
[powerup,8,84,581] // fuel system upgrade 
[powerup,6,346,511] // astronaut
[powerup,6,366,511] // astronaut

[demolish,62,591,109,617,1,40,2,0,0] // Information to make areas of the level break away, etc.
[demolish,346,221,381,239,1,40,2,0,0]
[demolish,495,200,530,225,1,40,1,0,0]
[demolish,540,240,627,284,1,40,1,0,0]
[demolish,664,280,694,326,1,40,1,0,0]
[demolish,303,473,330,490,1,40,1,0,0]
[demolish,639,507,687,534,1,40,1,0,0]
[demolish,666,651,690,678,1,40,1,0,0]
[demolish,313,503,340,521,1,40,1,0,0]
[demolish,197,477,217,515,1,40,1,0,0]
[demolish,354,671,369,702,1,40,1,0,0]
[demolish,130,691,191,712,1,40,1,0,0]
[demolish,305,558,430,590,2,40,2,0,0]
[demolish,556,366,680,459,2,40,2,0,0]
[demolish,110,613,210,647,2,40,2,0,0]
[demolish,386,279,425,354,2,40,2,0,0]
[demolish,320,390,470,432,2,40,2,0,0]

[environment,3,508,124,597,255,5,65535,0] // one of many environmental effects

[enemy,34,25,672,1] // enemy type, enemy skill level, enemy weapon & location

[end] // End of level description file

Here is a breakdown of the commands:

[sprites,filename] this will force the game to use an alternative sprites file image for the level.  This will allow you to change the look of the sprites.  The game will look for filename.PNG when loading the file.

[backdrop,filename] this will force the game to use an alternative backdrop file image for the level.  This will allow you to change the top & bottom bars as well as the fuel, shield, repulsor, and phase gauges.  Also located in this image are the look of the upgrade screen and the look of the bosses.  The game will look for filename.PNG when loading the file.

[forceload]  this forces reloading the same map if two sequential maps use the same map file.  (default will be to just keep the same map image & debris without reloading a clean map)

[inventoryadjust, item, amount]  this will adjust the amount of an item in your inventory at the beginning of the level.

[inventoryset,item,amount] this will set the amount of an item in your inventory

[gravity, amount] sets gravity (range 0-200)

[fuel,amount] sets fuel (0-100) at the beginning of the level (percentage).  do not include this line if you want the current fuel to carry over from the previous level.

[shield,amount] sets shield (0-100) at the beginning of the level (percentage).  do not include this line if you want the current shield to carry over from the previous level.

[timelimit, amount] sets a timelimit for the level in seconds (0-3600)

[popcolor,R,G,B] (r,g,b 0-255) sets effects color for level.

[bonuslevel,1] sets level as a bonuslevel...first death ends level.

[nextlevel,levelname] sets name of next level

[map, name] name of map to use for level

[map, lava]  (example) This describes the filename both the Level Image File and the Level Mask File.  In this example the Level Image File is named "lava.jpg" and the Level Mask Image File is named "lava.png".  As a side note, the Level Description File can be named differently than the Level Image & Mask Files.  This is done so that multiple levels could use the same Level Image & Mask files--in the event that you like to have several different game level situations on the same level image.  The Level Description Image File is named similar to the Level Description File.  Example:  If the Level Description File is named "Lava.txt" and located in the Custom level directory, in the Custom Level Section of the game, "Lava" will appear as an option.  When you click on Lava it will search for and display a Level Description Image File named "Lavainfo.jpg".  Once the custom level begins, if the description file included the entry [map,lava], then the game will load the lava.jpg and lava.png Level Image & Mask files and begin to play the custom level.  

[req_minlandings,amount] sets requirement for minimum number of landings

[start,x,y,dx,dy,spr] sets start location for ship x & y 1-748, dx & dy -511 to 511, spr 0-35.  (spr=direction angle/10 look at sprite file)

[starto,x,y,dx,dy,spr] sets start location for ship after a death or after Jump Gate to the level (start command cancels this one) x & y 1-748, dx & dy -511 to 511, spr 0-35.  (spr=direction angle/10 look at sprite file)

[powerup,number,x,y] x&y 1-748, r (0-30  may increase)

[powerup,number,x,y,minlevel,maxlevel] will only put on map if the difficulty is between minlevel & maxlevel.

[enemy,type,x,y,skill level]  enemy type, location, and skill level  

type list:

20's = saucer  (24, for example,  is a saucer that shoots lasers, 20 is a saucer with no weapon)

30's = glowing orb

40's = Enemy Flier

50's = Stationary Invisible Target (can be attached to anything on the map (for example gun turrets)--use demolish to destroy map under it, and enemy will die)

60=boss 1  (launches all types of 40's Enemy Flier)

70=boss 2  (launches all types of 20's Enemy Flier)

80=boss 3  (like boss 1 with different look)

[enemy,type,x,y,skill level,minlevel,maxlevel]  enemy type, location, and skill level

[environment,xmin,ymin,xmax,ymax,speed,type,variable1,variable2]

speed 0-255  (255 means once every frame, 0 means never)

[exit,xmin,xmax,ymin,ymax,landed] sets exit location (landed=1 for must be landed in area to exit level else 0 for unlanded)

[demolish,xmin,ymin,xmax,ymax,type,give,grab,shot,variable1]

[demolish,xmin,ymin,xmax,ymax,type,give,grab,shot,variable1,score,requirement] sets location, type, score, etc. for a destroyable part of the map

shot: number of time you have to hit the spot to make it explode

score: how much it's worth

give: how many additional pixels away from the area the explosion can be and still set the demolition off.

grab: where the routine grabs the pixels from to create a background for what's behind the map in the demolition area. (varies from one type to another)

requirement: set to 1 to keep track of how many things are blown up for a level requirement, otherwise 0.

variable1: reserved at this point

typelist:

1=typical exploding stuff like in demo

grab for 1:  1=above, 2=below, 3=left, 4=right

2=put this where there is land on the upperhalf and air on the lower half...it will create "dust" when a rocket hits the ceiling there.  You can see this in the demo in several places.

[req_droplocation,xmin,ymin,xmax,ymax] describes the area of where powerups must be if you want to have a requirement of this type.  For example: you want the player to move something to a different part of the map.

[req_powerup,number, amount] add a requirement for a specific powerup [req_powerup,6,2] would mean you want to require there are at least 2 astronauts

[req_powerupkill,number,amount] add a requirement that a certain powerup be killed amount times.

[req_powerupdrop,number,amount] in conjunction with req_droplocation.

[req_kills,amount] require a certain number of kills.

[req_demolish,amount] require a certain number of "demolish"es.

[req_pickupmes,string] string=30 characters or less. message to say when you haven't met pickup  requirement.

[req_killmes,string] string=30 characters or less. message to say when you haven't met kill requirement.

[req_demolishmes,string] string=30 characters or less. message to say when you haven't met demolish requirement.

[req_powerupdrop,string] string=30 characters or less. message to say when you haven't met powerupdrop requirement.

[req_minlandingsmes,string] string=30 characters or less. message to say when you haven't met landings requirement.

[pickupvalue,amount,amount,amount,amount.....30 amounts total] assign values to each powerup for post level score.

[end]  have this at the end of the file

[multi_powerup,num,x,y,respawn] powerup type, location, and respawn time in seconds for a multiplayer game. (50 max)

[multi_spawn,x,y,dx,dy,spr] start location for multiplayer game (20 max)

In addition to the main 4 files needed to create a custom level, the user will also be able to include a custom sprites file and backdrop file.  This will give the level designer the ability to change virtually all the graphics used in a level, including the powerups, the ships, the enemies, etc.

The following are the final commands that have been included in RocketElite:

[multi_demolish,xmin,ymin,xmax,ymax,type,give,grab,shot,variable1] multiplayer only demolish locations.

[multi_demolish,xmin,ymin,xmax,ymax,type,give,grab,shot,variable1,score,requirement] sets location, type, score, etc. for a destroyable part of the map for multiplayer games.

[req_clean] requires that all enemies are killed before level can be completed.  (adjust text requirement message with [req_killmes]

[levelencrypted] the first time you play this map, every character after the [levelencrypted] command of the info file will be encrypted.  This will protect it from modification.  Lines above the [levelencrypted] line can be added in plain text.

[turbo,turboup,turbodown] This adjusts the thrust generated by the ships thrusters by a fraction: turboup/turbodown.   For example, to make the ship have 20% more thrust use [turbo,6,5]

[version,version] sets the minimum version of the game the level will run on.  [version,110] means that the level will only work on version 1.10 of the game and above.

[upgrades,fuel,shield,beam,weapon,defense] resets the ship upgrades to a minimum value of whats specified, if the ship is already upgraded beyond the specified values the ship upgrade value will remain unchanged.

[sprites,filename] will force a new set of sprites for the current level.

[backdrop, filename] will force a new backdrop for the level as well as adjust gauge looks.

Stationary Targets

You make anything on the map an exploding scorable target. Simply attach a demolition tag to the area and give a score or requirement if you want.

Stationary Enemies

Keep in mind that you can draw any kind of stationary enemy, such as a gun turret.  Attach any of the stationary invisible enemies and assign a demolition tag to the area.  When the level is demolished where the stationary enemy is, the enemy will die.

Custom Campaigns

Also, if you want to make a custom campaign and want to hide levels of the campaign so that the player can't jump directly to that level simply start the name of the info & description image file with a dash (-).  For example if you had a level mars.txt.  You would name the level -mars.txt to hide the level and the description image would be -marsinfo.jpg

Developer Mode

You can toggle into developer mode while playing the game by pressing down on the gamepad during play of a custom level.  When you're in developer mode, enemies are frozen, fuel & shield are maximized, gravity is non-existent, and the level mask image is shown rather than the level image.  In addition, your absolute ship coordinates are shown in the upper left part of the screen.  You can freeze your position by holding up on the gampad.  While frozen, the game will report the absolute location of the stylus.  This will help you locate coordinates for the level description file.

There are also numbers by the demolition areas.  This will help you locate where in the file there is an error.  If the number is "2" on a problematic demolition area, just go into the level description file and count starting at 0 the lines of [demolition], #2 will match up with the label area on the screen.

Remember you need to enable Developer Mode from the options screen before you can enter developer mode during the game.

Custom Campaign Completion Image

If you would like to add an "end campaign image" to your custom campaign, in the text description of the final level include a [nextlevel,filename], then include a file named: filenameeg.jpg.  The game will load that image when you complete the final level of the custom campaign before jumping to the high score entry screen or the main menu.  This was just one final thing added simply to make your custom campaigns even better ;o)  If I can do it at the end of the single player game, you should be able to have an end game screen also!

Level Info Editor

Below is a link to the executable and Visual Basic 6 source code of a simple level editor to help people design their levels.  It is not complete, but it does do a good job simplifying the creation of the info files.  I would encourage people to build on the source and improve it.  Other developers, Curt Tooley is one such developer, are working on more complete level and campain design environments.

         leveledit.zip (17kb)  (Visual Basic 6 runtime not included)
         Level Editor v2.4 (22kb)  (Nice work, Brazillian!)

Good luck designing your levels.  I would like to encourage people to help develop this design information as well as great new levels and campaigns for everyone to play!

-Douglas Beck

This site is graciously hosted by Kattare Internet Services.  Excellent service providers.