Startpack Mappers' Guide: Difference between revisions
No edit summary |
mNo edit summary |
||
Line 2: | Line 2: | ||
BEING RE-WRITTEN FOR STARTPACK VERSION 2 SO USE YOUR JUDGEMENT IF READING THIS WITH VERSION 1. | |||
== Introduction == | == Introduction == |
Revision as of 06:18, 30 April 2009
written by Fidcal
BEING RE-WRITTEN FOR STARTPACK VERSION 2 SO USE YOUR JUDGEMENT IF READING THIS WITH VERSION 1.
Introduction
- The Mappers' Startpack is a set of components that can be used as the start of any Dark Mod map.
- It might also be called a Finishpack because it has all you need to both start and finish off your FM.
- It is a complete, installable, finishable pseudo-mission already packed in the correct TDM FM format.
- It does not include any useable terrain but sets up other elements that are common or essential.
- Instead of developing from new the mapper can simply modify these which is far easier.
- The mapper can thus begin with this seed FM and focus on building.
- The entire startpack can be customised by the mapper to form a nucleus for all their future FMs.
Here are the components included:
- pk4 template with necessary files to install your FM
- Pre-briefing summary template with background image template
- Full text briefing template
- Objectives template with working most-common objectives
- Difficulty level names template
- Purchase shop template
- Development player tools & ammo template
- Customisable object (for anything but especially one of the objectives.)
- Texture Favourites Palette
- Title Loader with progress bar gui template
- Default loader screens or substitute your own game screenshot
- A selection of common working readables templates
- A variety of pre-coloured, pre-murked water bodies with matching surfaces
- giant ambient_world light, player start, etc.
- Master key that opens any lock.
I already have a map. Can I import the Startpack?
If you already have a map being developed then you can import the startpack as follows:
- You must install the Startpack as described below.
- Continue with these instructions up to #Using the Startpack
- At that point:
- Back up your own map.
- import doom3\mymap\maps\mymap.map into your own map
- Check the startpack terrain doesn't overlay any of your own terrain. Move it if so.
- Save it.
- Some components may be duplicated. Check the following list and decide which to keep:
- Player start
- ambient_world map-wide ambient light
- key_master master key
- Objectives entity
- Test it.
- You now need to decide whether to move your map into the project folder or not (see #Project versus Non-Project?
- You can repeat this process for any number of maps.
- Alternatively, you can just open up doom3\mymap\maps\mymap.map in your map editor and export any parts as prefabs and import them into your own maps. For example, maybe you are only interested in the way the ammo is handled? Or the objectives?
Installing and First Look
It is essential to do this first install:
- (Darkmod betamappers only): Update darkmod\fms folder.
- In your darkmod\fms folder you should see a folder 'startmap'
- Run Darkmod, install 'startmap' at the New Missions menu and just check it out. (If you have any glitches such as wrong resolution, black textures, etc. then exit and copy your doom3\darkmod\DoomConfig.cfg to doom3\startmap.
- You'll see where your own pre-briefing, briefing, objectives title screen etc. will appear.
- The shop is empty because the shop template is not yet inserted.
- In-game weapons/ammo/tools are present via another method.
- You can see the readables work. Later you can enter your own text. More fonts available via prefabs.
- Through the door is a wide choice of water colours and murks.
- Finally, just to prove it works, back in the book room, grab the loot and special object and escape to the far corner for Mission Complete.
Setting up your Working Copy
Think up your FM map file name. If you've not got a title yet invent a working name. In these instructions I will use 'mymap'; substitute your own map name. This will be used in several places so you will need to change them all later to the final name you want to distribute it as. I will use 'doom3' to mean your Doom 3 path and folder.
Note that I use the exact map name throughout this tutorial to keep it simple but actually the folder and the .xd file can be any legal filename so long as they don't conflict with anything else.
- Create a new folder in doom3 named mymap.
- Extract all the files from doom3\darkmod\fms\startmap\startmap.pk4 into doom3\mymap. If your zipper program cannot handle pk4 files then just temporarily rename startmap.pk4 to startmap.zip.
- Copy your doom3\darkmod\DoomConfig.cfg to doom3\mymap.
- So you now have doom3\mymap folder and contents.This is the copy you work with for this one map. The original fms\startmap\startmap.pk4 is the master for any future maps you make this way.
Project versus Non-Project?
You can work with your map either as an isolated project or as a common map in the darkmod\maps folder.
Non-Project, Common Map Setup
Advantages:
- Easy to set up and familiar to work this way.
- You can access other unrelated maps via the console without relaunching Dark Mod.
Disadvantages:
- You will not be able to run it via the TDM New Mission menus at this time.
- When you run the map via the console you will not see your custom title loader (that can be copied over but not worth it as it doesn't break anything.)
- When you are finished you have to find all files related to your FM and collect them together and retest as an isolated project ready to zip up.
To setup as a common map, copy the startmap.map file from doom3\mymap\maps to your darkmod/maps folder and rename it mymap.map. You can then work with it like any other map in that folder.
You also need to copy the file doom3\mymap\xdata\startmap.xd to doom3\darkmod\xdata (else the books won't work and if you try to read any then it breaks weapons/ammo and blocks the inventory until you map the map again.) Optionally rename it mymap.xd in case you start work on another FM the same way.
When you have finished your map you should then copy it and the xdata file (if you've changed it) and any other essential files you have created back to the doom3\mymap appropriate folders. Then continue to set it up ready to ship as for an isolated project (see next section.) Of course, you can do this at any stage to test it then go back to working in the common darkmod folder.
You can now skip the next section and go to #Using the Startpack. At any time in the future you can set up your FM as an isolated project by reading the next section. In any event, when you have finished your map you will have to set it up this way to test it and eventually zip it up. Ever after, if I refer to your mymap.map or doom3\mymap\maps\mymap.map, I just mean the map you are working on with the startpack included, even if you are working on it darkmod\maps.
Project Map Setup
Advantages:
- It is an isolated project. All your files are together in one place.
- You see your custom title loader even via the console.
- You can test it any time via the TDM New Mission menus.
- When it is finished you just zip the lot up excluding the folders: mymap_misc, savegames, screenshots
Disadvantages:
- It needs custom desktop shortcuts for both Dark Mod and Dark Radiant (see later.)
- You cannot access other unrelated maps without relaunching (this protects your project folder from wrong files being saved there.)
Defining the Map Filename for Dark Mod
Dark Mod needs to know the exact filename of your map if it is to be installed and run via the New Mission menus:
Open doom3\mymap\startingmap.txt in a plain text editor.
- Change the text to: mymap
- Resave.
Pre-Briefing Intro
The pre-briefing intro is the text that shows in the Dark Mod New Mission menu when an FM is selected in the list:
- Open doom3\mymap\darkmod.txt in a plain text editor.
- Change the title to: mymap (or My Map! or any name you like)
- You can enter a very short pre-briefing description or leave it till later eg, Find the magic key and escape! I think this section can hold about 50 words.
- You can enter your name or user name where shown.
- Resave.
The image file mymap\install_splash.tga is a small background image for the pre-briefing intro. Advanced users can change it for their own if they wish. (not described here.)
Files needed in the fms Folder
- Create a new folder in doom3\darkmod\fms named mymap
- Copy these files from doom3\mymap to doom3\darkmod\fms :
- startingmap.txt
- darkmod.txt
- install_splash.tga
Files That Need Renaming
Rename all files prefixed startmap in doom3\mymap and subfolders to mymap, eg, startmap.map to mymap.map, startmap.proc to mymap.proc. Don't miss startmap.gui in the guis\map folder or the title screen will not work. There is also startmap.xd in the xdata folder. It is not essential to change it but it makes sense to help identify it as associated with your 'mymap'.
Congratulations! You are now good to go. You have your own installable FM ready to customise. Run Dark Mod and you should see it listed in the New Mission menu. Select it and you see your pre-briefing text. You can install and run it if you wish.
Project Desktop Shortcuts
To access your map as a project from Dark Radiant you need to set the game parameters in File > Select Game thus:
- Mod Base = darkmod
- Mod = mymap
You must then relaunch Dark Radiant.
When you want to access the maps in darkmod\maps you should delete mymap from Mod (leave it blank) then relaunch Dark Radiant.
In the near future a version of Dark Radiant will enable you to create desktop shortcuts to make the above easier.
If you launch Dark Mod with its normal shortcut with +set fs_game_base darkmod as an argument then when you install your project map as the current FM then it is only current for that session. Next time you run Dark Mod you would have to repeat.
If you use tdmlauncher.exe to launch Dark Mod then you can install your map project as the current FM and it will remain current each time you launch tdmlauncher - at least until you install another FM or delete darkmod\currentfm.txt
You can also create a special desktop shortcut for any FM including your map project (after it has been installed once.) To do this copy your normal Darkmod desktop shortcut and edit the properties to include in the properties:
+set fs_game_base darkmod +set fs_game mymap
When you run that shortcut you will find it always installed in the Dark Mod menu so you can run it that way or map or dmap it from the console. No special path is needed with the commands if you have your map directly in the doom3\mymap\maps folder, just enter dmap mymap. Note that if you suddenly want to check out another map in the common darkmod\maps folders you will have to exit and relaunch Dark Mod with your other shortcut. This protects your project from wrong files like dmap files going into your mymap folders.
The mymap\mymap_misc Folder
The mymap_misc folder is for any files related to your project but that does not want including with it when shipped. Things like map files backups, test textures, notes, images, whatever you want, so they are all kept together where you can find them. It is of course, optional.
When you come to zip up your project for distribution to the world, do NOT include the mymap_misc folder.
Using the Startpack
The Startpack has common components to start your map such as tools, player start, as well as the means to give your map a professional finish such as briefing template, shop template, loading screen with progress bar. When finished any unwanted elements can be deleted.
Map Starting
If you have followed the above you already have a folder doom3\mymap with various files and a map file called mymap either within it or in the darkmod\maps folder.
I'll go through the various components and what you need to do with them...
First Build
When you first start building in the Startpack you will find there is no useable terrain - what is present is merely to support other components and can mostly be deleted when finished. So, typically you first start with building your own brush and patchwork just as you normally would - but obviously build well away from the rooms included in the startpack (or move them somewhere else in the map.)
You do not necessarily have to deal with everything that follows at once. Your FM should already run. I suggest you browse through the headings quickly to see what is available and then deal with each as you need it. You will find you have plenty of ammo and tools to test with. Probably the only thing you need be aware of is that of course there is already a player start so move it where you want and there is a map-wide ambient light (see #Ambient Light
Blue Room
The 'Blue Room' is a tiny room that is inaccessible in gameplay. It is close to 0,0,0 in this Startpack. It is a convenient place to put non-visible items where they are all together so you can easily find them. Things like items that are in the inventory at game start, the objectives entity, items that might be teleported in during the gameplay, Texture Favourites Palette, and so on. These items could go anywhere in your map but since they do not relate to any special place in your game world it is convenient to keep them together.
I don't know the origin of the term 'blue room' but it is widely used in Thief Dromed editing.
Ambient Light
Almost all Dark Mod maps should have a large map-wide ambient light named 'ambient_world'. This is used by the Dark Mod special ambient light texture method which pre-calculates the brightness of textures based on this light so the light itself can be turned on and off by the player to improve performance. The Startpack includes this ambient_world light in the #Blue Room. The light itself is huge in radius: 7777 7777 7777. Build your terrain well within this radius. You can reduce the radius later but I doubt it makes any difference to performance where its volume is in the void and there is nothing to illuminate.
Its brightness value is 6 (_color 0.6 0.6 0.6) which is the same as the gamma_ref.map. If you haven't already, you should run darkmod\maps\gamma_ref.map and follow the instructions in there to calibrate your Dark Mod brightness and gamma settings as prescribed. All players should do the same. Nobody is obliged to stay with the standard but if you are aware of it then you know at least that if you vary from it then players will not see what you see and vice versa. Once you have calibrated your settings you can then, if you wish, adjust the _color value of the ambient_world light. Perhaps you want your mission to be a little darker or lighter. Your choice. It depends on taste plus whether you have plenty of other lights and also common texture lightness; lots of dark textures are very hard to see in very dark ambient light. Also, if too dark then many players may turn up their Dark Mod sliders to compensate. This will result in readables being maxed-out and page texture lost. I recommend you keep within a brightness value of 4 to 8 generally.
Player Start Point
Every map must have a player start point, an info_player_start entity. This is in the book room in the Startpack. I named it 'Player'; rename it what you want and move it where you want of course.
Master Key for Testing
The startpack includes a master key in the #Blue Room that shows in the player inventory. This will open any lock for use while testing.
IMPORTANT! Remember to delete it or set its spawnarg inv_map_start to 0 when finished.
Ammo, Weapons, Player Tools, Start Inventory
There are several ways to provide the player with ammo & tools:
- The player can start eg, in his own room with items in the game on a table or in a chest etc.
- Items can appear later in the game placed at strategic points (this should especially be used for mission-critical items.)
- Tools, can be placed directly into the player's inventory at start by adding to the item the key/value: inv_map_start 1. That is the method used in the Startpack for including player tools. In the #Blue Room are the following.
- Compass
- Lantern
- Spyglass
- Health potion (10)
- Breath potion (10)
- Flash bomb (10)
- The last few all have the spawnarg inv_count 10 so you get 10 in the inventory and easy to change.
- All the tools have spawnargs diff_N_nospawn set so they show on all difficulty levels but easy to change.
- Edit, add to, or delete, any of the above as you wish.
- Weapons and arrows can't be included by the above method. Instead they are listed in the entity Ammo_difficulty_settings also in the #Blue Room. But best not edit that directly. Instead, use the Dark Radiant menus > Map > Difficulty which provides a Difficulty Editor. Now it seems likely that you can set the player tools in this too so everything is together but I don't yet understand how to do this and my various tests all failed. Instead, just use it for weapons and ammo for now, as follows:
- On the Easy tab click the + sign against atdm:player_base to open it up.
- You can see all weapons and ammo listed with their quanties for easy level.
- You can see the same on the Medium and Difficult tabs.
- Note that I gave 33 arrows on Easy, 22 on Medium, and 11 on Difficult.
- This is just so you have plenty while developing and gives a cue which difficulty you are playing (default=Easy)
- To change the values:
- Select any item on any tab.
- On the right in the argument box change the value to what you want.
- Click Save. Don't mess with the options headed assign: unless you know what you are doing.
- When done click the OK button then save the map.
- The above methods are ideal for use while developing your FM and testing via the console or for including items that cannot go or you do not want, in the purchase shop.
- The purchase shop is the final method of giving the player items at game start but only effective when you launch your FM via the Dark Mod New Mission menus. Once run, it overrides anything set in the Difficulty editor(except zero quantity items) but it ADDS to anything included in the map like the potions. See the next section for this.
Purchase Shop & Difficulty Names
The purchase shop is only available if you launch via the Dark Mod New Mission menus. You can directly edit worldspawn but it can be confusing. I think my template is easier to read and edit. Basically you edit that then copy and paste it into your map file in a plain text editor as follows:
In the doom3\mymap\maps folder you will see shoplist.txt and shoplistMASTER.txt. In both I have listed all common items set to ZERO. Do not edit the master copy but keep that so if something goes wrong you can copy it again. Only edit the shoplist.txt as follows:
Comment lines begin with a double slash. They are remarks only and have no effect in the map.
Throughout shoplist.txt the various difficulties are numbered 0, 1, 2 for normal, hard, expert.
Difficulty Level Names
Near the top of shoplist.txt you should see:
"difficulty0Name" "Normal" "difficulty1Name" "Hard" "difficulty2Name" "Expert"
You can edit the above names depending on your FM. For example, if your map has no difficulty differences you might change them to "Normal", "Normal", "Normal". If it is a very hard map you might want "Difficult", "Expert", "Near Impossible!". You might also edit it for style changes. For example, suppose on Hard and Expert you have a no KOs and no Kills objectives plus on Expert you do not provide any water arrows then you might have "Normal", "Stealthy", "Ghost".
The above will display in the Difficulty/Objectives screen when your FM is launched via the Dark Mod New Mission menus. (not sure how much space but I think not much so check - I doubt you can fit in "Crazed Zombie Deathmatch" but you can try.
Save shoplist.txt and save frequently throughout the following...
Spending Money
Next down in shoplist.txt are the number of gold pieces provided to spend in the shop. It is not carried forward as player loot into the game. I have set these to zero. If you provide items for sale in the shop you need to evaluate how much you want the player to have for each difficulty level. Typically you don't want them to be able to buy everything and typically provide less on the harder levels. Just edit the zero in "0" to whatever values you want:
"diff_0_shop_gold_start" "0" "diff_1_shop_gold_start" "0" "diff_2_shop_gold_start" "0"
Free Starting Items
You can give the player items which they will then have at game start even if they do not buy anything. But note that they can drop these in the shop so do not include anything mission-critical. So further down in shoplist.txt you will see most common items listed in this format. The format is as follows. Only change the 0 in the "0". The first line in each section just gives the item a number to identify it in the list. So the first one it numbers the sword as number 1. The lines after it in that section set the quantity for each difficulty level for number 1.
Do not delete any items even if they are zero quantity! If you do then you will have to renumber everything after it.
You cannot include items already in the map. All shop items must be pre-defined in a def file because they are spawned at game start. By that means, advanced users can add special items like a game map but this is not described here. You can only add items defined in darkmod\def\tdm_shopitems.def. They are all currently listed in shoplist.txt. Advanced users can add to that and include it with their FM. Not described here.
Naturally, some items like sword, blackjack, compass, etc you can only give a quantity of 0 or 1 but others can be any amount.
"startingitem_1_item" "weapon_shortsword" // NUMBERS THIS ITEM AS #1 "startingitem_1_0_qty" "0" // ITEM NUMBER - DIFFICULTY 0 - QUANTITY "startingitem_1_1_qty" "0" // ITEM NUMBER - DIFFICULTY 1 - QUANTITY "startingitem_1_2_qty" "0" // ITEM NUMBER - DIFFICULTY 2 - QUANTITY "startingitem_2_item" "weapon_blackjack" "startingitem_2_0_qty" "0" "startingitem_2_1_qty" "0" "startingitem_2_2_qty" "0" "startingitem_3_item" "weapon_waterarrow" "startingitem_3_0_qty" "0" "startingitem_3_1_qty" "0" "startingitem_3_2_qty" "0" ...and so on.
Shop Items for Sale
Further down in shoplist.txt you will see actual shop items which are items for sale in the shop. They are in the same format as for startingitems so deal with them the same way...
"shopItem_3_item" "weapon_waterarrow" "shopItem_3_0_qty" "0" "shopItem_3_1_qty" "0" "shopItem_3_2_qty" "0"
Importing the shoplist.txt into your map
When you have edited shoplist.txt as described above, you can then select ALL and copy to the clipboard then paste into your mymap.map file. Ideally, keep the shoplist.txt so if you want to re-edit later always edit that and paste it in again. Alternatively edit worldspawn so long as you remember which. Here is what to do...
- First back up your mymap.map file just in case.
- In a plain text editor open doom3\mymap\maps\shoplist.txt
- Select ALL to copy to the clipboard
- In a plain text editor open your mymap.map
- About the 4th line down you should see "classname" "worldspawn"
- Create a few blank lines below it so there is no doubt where to start.
- Scroll down through all the shop and difficulty lines until you see the last one which will probably be...
- "startingitem_9_item" "weapon_gasarrow"
- Make sure you don't include any other item such as "editor_...etc" lines
- Create a few blank lines below it so there is no doubt where to ends.
- (Below that it is probably followed by eg, "editor_something etc.)
- Now select and delete everything between those blank lines.
- Scroll down to make sure there are no more shop lines below those "editor_" lines. If so, delete them.
- Paste your clipboard (with the shoplist info) into the space you created below the "worldspawn" line.
- Don't worry about blank lines or comments they do no harm and they will not survive a save from Dark Radiant later.
- Save your map and make sure it still has the .map suffix (some text editors might add .txt.)
Readables
A variety of readables are provided in the startpack. There are books, scrolls, and sheets. Each has a static and a moveable version. The books and scrolls also have open and closed versions. Plus there is a choice of 3 common fonts for each. Each has some default text so you can view and read them by playing the startpack and decide which is appropriate for your FM.
To use one of these readables in your map:
- Select any of the readables.
- Copy it (or move it if you only want one of these) to where you want it in your FM
- In entity inspector, look at the spawnarg xdata_contents
- Copy the value of that property to the clipboard, eg, book_gothic
- Open doom3\mymap\xdata\mymap.xd in a plain text editor.
- Do a search (typically Edit menu) and paste that name into it to find the section headed eg, book_gothic
- If you copied the book then:
- Copy this whole section headed eg, book_gothic right down to and including the final right curly bracket } and before the header of the next section.
- UNselect that section and paste its copy in the gap between that section and the next.
- Rename the header of this new section (eg, change book_gothic to say BrotherAlphusPrayerBook)
- If you moved the book then you can optionally rename the header of the original section (eg, change book_gothic to say BrotherAlphusPrayerBook) or leave it.
- If you renamed the section you MUST copy that name into the spawnarg xdata_contents of the book in entity inspector.
- Now you are ready to type your own text.
- Scan down the section to the default text. Typically this will be:
{ " Delete this text and enter your own. One paragraph between each set of quotation marks." "" "This is another paragraph on the same page. Change this too." }
- Every section is headed which page etc it is and encloses its text within curly brackets { }
- Delete the default text and type in your own.
- Put each paragraph within its own double quotation marks "paragraph".
- Do NOT put linefeeds within the quotes but just let your text wordwrap in your text editor.
- If you need a linefeed within a paragraph then insert \n to force a new line but keep on typing on the same line. In-game it will show a linefeed.
- You can use multiple \n\n etc to create blank lines.
- Alternatively, insert empty quotation marks "" on lines to force a blank line (this is more WYSIWYG.)
- Text does not flow from section to section and page to page so you must judge what will fit a page by testing.
- Each section is headed where it fits in the readable eg, "page1_left_body" goes on the left side of page 1 of a book.
- All pages also can optionally have a title headed eg, "page1_left_title" : using a larger size of the font.
- Leave the title blank if you don't want one.
- If you do have a title then you must space down your main text so they do not overlap. Just put \n\n\n at the start of your first paragraph or else two or three empty double quote marks: "".
- Do not put too much text in to begin with until you get experienced. One page does not hold a lot. Test frequently to see how it is progressing. Take small steps. It is very easy to make a typo and delete a quotation mark for instance. (xdata does not reload easily - see later for testing.)
- Put more text on to other pages.
- When finished, if you entered more than one page then at the top of this readable section look for the line "num_pages" : "1" and change that "1" to the number of pages. (Tip: set it to 5 until you are sure you have it all finished then reduce it.)
- If it fails to display in the game see Readables#Troubleshooting Those are all mistakes I've made myself so don't be concerned if you don't get it perfect first time.
- Because xdata does not reload easily with just reloadDecls in the console, to test readables this is what I recommend: Readables#Test_your_Readable.21 Pay particular attention to the link to Console_batch_macro_commands It is possible to rapidly reload with just cursor up and enter by that means.
Finally, note that the readables samples in the startpack are just a fraction of what is available and you can insert others as prefabs (see Readables_Prefabs)
Texture Favourites Palette
There are some brushes in the #Blue Room with various common textures so they are available in the Textures list for immediate use each time you start a new map. Add your own most-used textures. This palette needs more thought. Maybe tiny brushes are sufficient. And the best defaults need more thought.
Water
The startpack includes a wide range of water entities with different colours and murkiness to suit most situations from dirty thick sewer water to a clear blue bathing pool. Each body of water has an extra surface patch of texture so the surface matches the murkiness below. This skin should be included when you copy the water entity to where you want it in your FM and resized with it. In addition, there is a large underwater ambient light named ambient_extra_underwater2 (as well as other lights.) Lighting, especially ambient, should be considered if the water is deep enough to swim in, especially if you choose very murky water.
Objectives
Several common objectives are already set up and working so you need only modify/copy/or delete what you do not want. The objectives provided are:
- Get a special object
- Get loot (in 3 levels of difficulty)
- Don't kill (expert only)
- Go to a location (eg, reach somewhere or escape at the end.)
Details of setting this up are as follows:
Get or Steal a Special Item Objective
Many FMs have some special item that the player has to obtain as the 'main quest'. Bafford's sceptor, the relic in Saint Lucia, etc.
- If you wish the item to also have loot value and it is already defined as a loot entity then use that. But note that it when the player gets it the object will not show in the inventory with its special name (eg, Agamemnon's Helmet) but just go in with the other loot. The player might not even be certain what it is. More dramatic is to make it a custom special object so the player can proudly see he has it in the inventory. You can always make plenty of other loot.
- If the object you wish to use is already defined as a moveable entity then use that.
- Otherwise use the provided customisable object.
The customisable object is a special entity. The one in the startpack is a static one that cannot be dropped once the player has got it. There is also a moveable version under Items\Custom if you need an object you can drop, eg, to take somewhere. This works fine but one difficulty is that the model used must have a collision mesh or else you can make one (see Moveables.) But I am trying to keep things simple so the moveable is not included in this guide. Let me describe the static custom object and how to set it up in the objective.
The custom object is in the startpack's 'bookroom' on the bench opposite the books. The example model I used is a gauge (imagine the player has to steal a special prototype design from an engineer's workbench as an objective.) If you select it and look in entity inspector you will see you need to...
- Select a model (or use the gauge.)
- Enter a unique inventory name here to appear in the player's inventory when it is obtained.
- You have various options for its inventory icon:
- You can look to see if there is any suitable inventory icon in darkmod\guis\assets\hud\inventory_icons
- You can create a new one if you know how (not covered here.)
- You might try an image from the model but unlikely to be very good (not covered here.)
- You can leave the default which is blank (recommended)
- Give the entity a suitable name.
To modify the objective you need only give it the above name and your own description:
- In Dark Radiant, select menus > Map > Objectives
- Select Objective 1: Get or Steal a Special Object
- Click the Edit button on the right.
- Edit the text to what you want, eg, "Steal the special prototype gauge from the workshop."
- The line below that has Difficulty : All levels. If you only want this on one or two levels then select.
- Further down, in the box headed Components > Type, select Acquire entity ItemName
- Further down, in the box next to 'Name of single entity, change the name from ItemName to the name you gave the entity.
- Click OK. Click OK again on the main objectives window then save your map.
Steal Loot Objective
While developing you can estimate how much loot the player has to steal. Or even just put in a low value of 1 so you can test Mission Complete works correctly.
As your FM nears completion you need to more precisely evaluate how much the player has to steal on each difficulty level.
You need to find the total amount of loot in your FM. To do this, play the mission to the end. When Mission Complete comes up select Statistics and it shows how much you stole and also the total in the FM.
Make a note of how much loot you generally find while dumb test playing. Evaluate the difficulty as best you can for Easy, Hard, Expert.
As a general guideline, values might be (% of total loot):
Easy: 40%. Hard: 55%. Expert: 70%
Note that those values might seem low but high percentages are not popular and players can mostly still continue to find more if they wish.
Write down the values you want to apply. Later, get them tested by beta testers and listen to their advice on the matter and change the values if necessary.
Now, this is how to edit the loot objectives:
- In Dark Radiant, select menus > Map > Objectives
- Select Objective 2: Get loot (easy)
- Click the Edit button on the right.
- Edit the text to what you want, eg, "You must steal at least 1000 in loot"
- Further down, in the box headed Components > Type, select Acquire 1 entity.
- Further down, in the box headed Amount, change the 1 to the amount of loot you want the player to get on Easy level, eg 1000.
- Click OK.
- Repeat for Hard and Expert levels.
- Click OK again on the main objectives window then save your map.
No Kills on Expert
This already works so you first need to consider if you want it at all. If not, just select it in the list and click the delete button on the right.
If you are keeping it then change the text to what you want. Click the edit button and type into the top box. A common example is something like: "You are a thief, not an assassin. Do not kill anyone."
If you want to change the difficulties, eg, you want it on Hard as well as Expert then edit it and click the radio buttons about the second line down.
If you only want the player to NOT kill a specific character then at the bottom of the Edit Objective box, click the Kill Target box, select Name of single entity, and you can then enter the entity name of that AI in the box opposite it.
If you DO want the player to kill that character:
- click the Boolean NOT check box just above to UNcheck it.
- Click the radio button 'ongoing' (on the flags line higher up) to UNcheck it.
There are other variations such as don't kill innocents but I want to keep this simple (which means I don't know myself without searching and testing!) Future startpacks might include a lot more examples so you can pick what you want and delete the others.
Go to Location (Escape) and 'When All Objectives Done'
This final example objective demonstrates how to make an objective for the player to go to a special location (typically escape to start point but it can be go to any location, eg, "Find Lord Hasketh's Tomb to begin your search!") It also demonstrates an objective that relies on other objectives being finished first. In this example this is ALL other objectives but it can be any specific ones, eg, if you have "After you have the magic amulet, go to the the Hall of Kings" so if the player has not yet completed the magic amulet objective but goes to the Hall of Kings then that goto objective won't complete. OK, back to this goto objective:
- In Dark Radiant, select menus > Map > Objectives
- Select Objective: Get or Steal a Special Object
- Click the Edit button on the right.
- Rewrite the description to what you want.
- If you have created more objectives that must be done first you need to change the 'Enabling Objectives' further down as follows:
- Each particular objective should be numbered with AND between, eg, 3 AND 4 AND 5 AND 6.
- If any of those objectives is divided over different difficulties (eg, there are three loot objectives because the amounts are different on each difficulty but only one of them shows when played.) then you need to clump those together as one within brackets with OR between, eg, (5 OR 6 OR 7) so together with the other objectives linked by AND that might be eg, 3 AND 4 AND 5 AND (6 OR 7 OR 8) AND 9. (in that example objectives 3 and 4 and 5 and 9 MUST be done but EITHER 6 or 7 or 8 will do.
- You do not need to include 'do NOT' objectives such as no kills because they are flagged 'ongoing' and regarded as completed for this test.
- Further down, in the components type you will see it says "be at location EscZone". The actual location is defined by a large clip-textured brush info_tdm_objective_location entity which I named EscZone. If you change the entity name to eg, "HallOfKings" then obviously it must also match in the objectives so change both.
- Finally you should:
- move that info_tdm_objective_location entity to where you want the player to go to
- Resize it.
- Do not make it too small or the player might pass through it before it triggers.
- Do not make it too large because it is tested frequently so might affect performance. By default it is tested once per second. If there is a possibility of the player passing through in less than one second then you can change that time in the interval spawnarg on the entity.
- Test this carefully for timing, atmosphere, and most of all, reliability. Test it by running through also.
- You can have any number of these locations (not described here.)
Title Screen Loader
The startpack includes a title screen loader gui where you can optionally enter your title and some smaller atmospheric text, plus a choice of three background default title screens. It is also very easy to make your own even with no art skills at all which I will describe later.
First you need to choose a background screen for the loading sequence so you know where to position the text.
The Default Title Screens
If you want to use one of the defaults, look in guis\assets using an image viewer and select the picture you like best. Note its filename.
Making your own Title Screen
To make your own title screen:
- Run your mission.
- Temporarily hide the lightgem in Settings > Gameplay.
- Change the screen resolution temporarily in Settings > Video Menu to 1024 x 768.
- Exit and relaunch Dark Mod or the screen res won't change.
- Check that it is still 1024 x 768 in the settings.
- Don't show any weapons or inventory.
- Save a nice screenshot from your mission.
- Optionally rename it eg, myTitle.tga
- Move it from the screenshots folder to guis\assets
- Optionally, if you have art skills and a paint program you can enhance it all you like. (not described here.)
- You can easily change this later if you save a nicer screenshot.
Getting your Title Screen into the gui Loader
- In a plain text editor open guis\map\mymap.gui (If it is still named startmap.gui then rename it now to mymap.gui. (see in the section above headed #Project Map Setup)
- Scroll down a few lines to the line that says:
background "guis/assets/generic_loading2.tga"
- Change the filename of the screen to the one you want, whether it be another default or your new screenshot, eg, change 'generic_loading2.tga' to 'myTitle.tga'.
- Save.
- Scroll down to the line that says:
text "\n\n\n\n\nYOUR MISSION TITLE"
- Change the words YOUR MISSION TITLE to the full name of your FM.
- Save.
- Scroll down to the line that says:
text "\n\n\n\n\n\n\n\n\n\n\nYour brief atmospheric text\n(if any) to go here..."
- If you want to put in any atmospheric text of your own then change the above to what you want. (Stay within the double quotation marks and do NOT insert any linefeeds (Enter key) within the double quotes; use \n instead .) For example "the dead need not need their treasures..." or somesuch. Or even "A Dark Mod Mission by Jack the Lad".
- If you don't want any smaller text then delete the above text within the double quotation marks but don't delete the quotation marks or the rest of that line.
- Test for spacing and position by running your map. There is also a console command testgui for longer study but I could find no way for it to show edits in real time without relaunching Dark Mod, whereas if you just map the map it does show your changes instantly. Save testgui for a longer scrutiny.
- OK, now you are very likely to find your text is not exactly where you want it so this is how to adjust it:
- Both title and descriptive text automatically centre left and right.
- To move either texts up or down insert or remove \n (within the double quotes.)
- For example, if you want the title near top centre you might not need any \n at all.
- If your title or text is too big to fit on one line just insert a \n midway. Each line should centre.
- In the console, just keep using cursor up and Enter to re-run map mymap so you can see your adjustments.
- You can change the font in the line(s) starting 'font' (see Fonts Screenshots)
- You can change the font size in the line(s) starting 'textscale'
- You can easily offset your text from centre by putting spaces at start or end of lines or you can change centring to left or right justification in the line(s) starting textalign.
- You can change the colour of your text in the line starting forecolor.
- Save.
- Advanced users can do lots more with the gui but this is enough for this guide.
Briefing
The briefing is the full introduction to your FM that shows when the player selects Start Mission from the New Mission menu. There is a gui provided where it is easy to add a simple text briefing. Advanced users may be able to include graphics, possibly sound and video but this guide will only describe how to add a text briefing:
- Open doom3\mymap\guis\mainmenu_briefing.gui in a plain text editor.
- Scroll down to the line that starts: #define BRIEFING_TEXT "
- Replace the text there with your own story introduction.
- Keep within the double quotes.
- Do NOT insert linefeeds (Enter key) within the double quotes.
- To force a new line use \n
- You can also show a double quote using \" eg, "He said \"Goodbye!\" and left."
- You are briefing the player as the main purpose of his mission in a story-like way
- You might give it as a third party narrative but commonly it is written as the musings of the player character: the thief. For example: "I got some information about some valuables stored in the old house on Clinker Street..."
- There is room for about 100 words.
- You can change the font in the line commencing #define BRIEFING_TEXT_FONT (see Fonts Screenshots)
- You can change the font size in the line commencing #define BRIEFING_TEXT_SCALE
Readme Document
The readme.txt file is in your mymap folder. It can be used for any other information you wish to include with your FM.
The first few hundred words will be displayed in the Dark Mod New Mission menu page by pressing the FM Notes button. If you need more info than will fit I suggest you add "(more info in the readme.txt file in the pk4.)"
There is no guarantee that the player will read it though. Certainly put the most important info near the start.
You should not change the filename or it will not display in Dark Mod.
Open the file in a plain text editor to see examples of what you might include. Make sure you delete the examples at least!
Packaging For Distribution
Finally, you have finished and tested your FM. Possibly beta-testers have already tested it (or you may be getting it beta-tested after it is properly packaged. It should be again anyway.) You now need to package it correctly ready for distribution so it will install and run via the Dark Mod menus.
If you have created your FM as a project you are almost ready to zip up.
If you have developed your map in the common darkmod\maps folder you need now to turn it into a project and test as described above in #Project Map Setup before you proceed to package it.
This is what you must now do to package this up:
Basically you are zipping up the project folder but without the unnecessary files. So you could copy the folder then delete what is not wanted but I suggest you do this instead to keep everything together in one folder...
- Check that any unessential files are moved into the mymap\mymap_misc folder if they are not there already. For example:
- Move your Doomconfig.cfg to mymap_misc.
- Move your .darkradiant file to mymap_misc.
- Move your maps\mymap.bak file to mymap_misc.
- Move any gamesaves folder to mymap_misc.
- Move any screenshots folder to mymap_misc.
- DELETE:
- config.spec
- gamex86.dll
- (Doom will recreate the above next run.)
- MOVE your mymap_misc into the doom3 folder.
- Then zip up the entire CONTENTS of the mymap folder but not the folder itself. MUST be in zip format nothing else. You can use WinRar but you must set ZIP format. Name the zip any legal filename, normally the map name. Note:
- This pk4 name will eventually be the folder name when this is installed by players.
- It should be distinctive. If two FM pk4s happened to be called 'heist' then they will clash. It does not matter if the actual FMs map files are both called 'heist'; only the zip file (except it might be confusing of course.)
- You might wish to add a version ID, eg, 'lord_blakeleys_manor_v1.0.zip'
- Rename the suffix of the zip file to a .pk4
- This is now the pk4 archive that is ready for distribution and that players will download. To simulate what players will do and test it all works correctly:
- Rename your doom3\mymap folder to eg mymapORG.
- Delete or rename your old darkmod\fms\mymap folder.
- If your mission was the currently installed then deleted darkmod\currentfm.txt (if it is there.) otherwise Dark Mod will think your mission is already installed.
- You must disable or remove ALL custom files in the common darkmod folder. For example, if you made a special texture or script or whatever and it is in the darkmod subfolders and then you copied it into the project folder for distribution, you should still disable it in the common files to be certain. Otherwise if you overlook anything it will work fine on your system but fail when 2000 players download it. (this is why I recommend developing as an isolated project folder from the start - it is very easy to overlook something.)
- If your FM was the 'currently installed' mission in the Dark Mod New Mission menu list then either install something else or just delete darkmod\currentfm.txt. This is because otherwise Dark Mod will think your mission is already installed and may give an error.
Your system is now in the normal state of any player who has downloaded your FM zip file into a spare folder. So now this is what to do to test what they will have to do...
- Copy the pk4 into the darkmod/fms folder. It can go directly into the fms folder. If you make a new folder fms\mapname and put it in there it will still work but no need - Dark Mod will create that automatically.
- It is now ready to play. BUT do NOT play it via your special shortcut if you made one. Run Dark Mod via tdmlauncher. Do everything as if you are an FM player and have never seen this FM before and have just downloaded the pk4.
- When you install it via the Dark Mod menus it will recreate the mymap folder and run the FM.
- Give it a thorough test and have it beta-tested one more time if possible.
Congratulations! You now have a properly finished and professional FM!
Startpack Future versions
Future versions of the startpack might include:
- Better texture palette cubes so your most-used textures are available
- Selection of AI with various heads and other attachments.
- Many more objectives examples
- Game map template (eg, mansion layout)
- Possibly defs to include common extra objects in the purchase shop such as a game map or informant's message.