Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changes between Version 11 and Version 12 of content/LevelHowTo


Ignore:
Timestamp:
Feb 10, 2011, 4:46:06 PM (13 years ago)
Author:
jo
Comment:

I'm going to rewrite the whole howto; this might take a little time;

Legend:

Unmodified
Added
Removed
Modified
  • content/LevelHowTo

    v11 v12  
    22[[OutdatedPage]]
    33[[TracNav(TracNav/TOC_CC_Tut)]]
     4
     5== Create the basic file ==
     6 1. Go to the folder ../data/levels. The level files ending with .oxw are simple XML files and can be opened with any editor. Each level file stored in this folder can be selected later in Orxonox.
     7 2. Copy „empty_level.oxw“ and paste it again in the folder.
     8 3. Rename the copy. Try to use a name that sounds good. Avoid whitespace – use „_“ or CamelCase instead.
     9 4. Open your level with your favourite editor.
     10
     11
     12
     13== About XML ==
     14
     15XML is a description language that looks similar to HTML. Like in HTML there are tags (in fact we are only using tags):
     16<templates>                                                     <!-- Opening tag -->
     17    <Template link=lodtemplate_default />                       <!-- Opening and closing at once -->
     18 </templates>                                                   <!-- Closing tag -->
     19A template can contain several tags. A tag is the place where a value is set.
     20 <Light type=directional position="0,0,0" direction="0.253, 0.593, -0.765" diffuse="1.0, 0.9, 0.9, 1.0" specular="1.0, 0.9, 0.9, 1.0" />
     21The syntax is tag=“vaule(s)“ if only one value is set the quotation marks are not necessary.
     22
     23Tip: Since your XML files do not have to be compiled you have to simply reload a level to view the changes. In Linux you can switch between the game and the editor by pressing [alt] + [tab]. If you insert only a little error and try to load a level the game will „stuck“. By pressing [alt] + [tab] you can leave the game and view the error message on the terminal.
     24
     25
    426
    527To create a level in Orxonox is really easy. One does not have to program anything or compile the code again, because our levels are created with XML-Files. There the objects in the level can be defined. On this page we explain what one can do with the XML-Files and how to create a new level for Orxonox with them.