Startpack Mappers' Guide: Difference between revisions

From The DarkMod Wiki
Jump to navigationJump to search
Fidcal (talk | contribs)
 
(51 intermediate revisions by 10 users not shown)
Line 1: Line 1:
'''Startpack Version 3'''
''written by Fidcal''
''written by Fidcal''
== Download ==
You can get Startpack from:
https://www.moddb.com/mods/the-dark-mod/addons/start-map-example
== New 2.0 Path Details ==
To provide background context on the transition from The Dark Mod's "Doom 3 mod" phase
vs the Standalone 2.0 practices please review the following:
http://forums.thedarkmod.com/topic/15152-new-dr-folder-settings-for-tdm-20/
== Summary ==
* Keep the original startmap.pk4 as a master somewhere.
* When you begin a completely new FM then first install Startmap like any other FM.
* You can play Startmap right up to Mission Complete in about 60 seconds.
* So all you do is change it to be your own FM.
* You change the title, the texts, etc.
* You modify the objectives, eg, change loot amounts, etc.
* You already will have lots of test ammo and all player tools.
* Easier to delete what you don't want than figure out how to put them in anew.
* Default ambient light is set up for the entire map.
* You leave the startmap terrain where it is for now.
* You build afresh elsewhere in the map and move the player start point to where you want it.
* You copy or move any of the stuff provided and/or add your own.
** Eg, there is an example of every AI variation - copy and drag where you want.
** There are ready-made readables - copy and drag where you want and add your own text.
* When you have finished your FM you can delete the startmap terrain (but it's harmless if you don't.)
* At all stages you have an installed, working, completeable, FM.
* As an alternative you can insert it into an existing map or just grab what you want!


== Introduction ==
== Introduction ==
Line 14: Line 52:
* pk4 template with necessary files to install your FM
* pk4 template with necessary files to install your FM
* Pre-briefing summary template with background image template
* Pre-briefing summary template with background image template
* Full text briefing template
* Full text briefing template in plain text xdata format.
* Objectives template with working most-common objectives
* Objectives template with most-common objectives working
* Difficulty level names template
* Difficulty level names on worldspawn
* Purchase shop template
* Purchase shop list entity & easy-read prefab with comments
* Development player tools & ammo template
* Custom shop item template
* In-game terrain map template.
* Player tools, weapons, and ammo; easy to set difficulty amounts
* Customisable object (for anything but especially one of the objectives.)
* Customisable object (for anything but especially one of the objectives.)
* Texture Favourites Palette
* Texture Favourites Palette
Line 25: Line 65:
* A selection of common working readables templates
* A selection of common working readables templates
* A variety of pre-coloured, pre-murked water bodies with matching surfaces
* A variety of pre-coloured, pre-murked water bodies with matching surfaces
* giant ambient_world light, player start, etc.
* Giant ambient_world light, player start, etc.
* Master key that opens any lock.
* Master key that opens any lock.
* Internal Leak Test entity.
* Player start drop to overcome rendering delay at map start.
* All common AI heads, bodies, and skins combinations to easily pick from wide selection.


==I already have a map. Can I import the Startpack?==
==I already have a map. Can I import the Startpack?==
Line 36: Line 79:
* At that point:
* At that point:
** Back up your own map.
** Back up your own map.
** import doom3\mymap\maps\mymap.map into your own map
** import darkmod\fms\mymap\maps\mymap.map into your own map
** Check the startpack terrain doesn't overlay any of your own terrain. Move it if so.
** Check the startpack terrain doesn't overlay any of your own terrain. Move it if so.
** Save it.
** Save it.
Line 44: Line 87:
*** key_master master key
*** key_master master key
*** Objectives entity
*** Objectives entity
*** Shop entity
** Test it.
** Test it.
** You now need to decide whether to move your map into the project folder or not (see [[#Project versus Non-Project?]]
** 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.
** 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?
** Alternatively, you can just open up darkmod\fms\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==
==Installing and First Look==
Line 54: Line 97:
It is essential to do this first install:
It is essential to do this first install:


* UNinstall any previous startmap version if installed at the Dark Mod menus. To do this either install another FM at the Dark Mod menus or else delete darkmod\currentfm.txt.
* Delete any previous darkmod\fms\startmap folder or rename it if you want to keep it for reference, etc.
* (Darkmod betamappers only): Update darkmod\fms folder.
* (Darkmod betamappers only): Update darkmod\fms folder.
* In your darkmod\fms folder you should see a folder 'startmap'
* 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.
* 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 darkmod\Darkmod.cfg to darkmod\fms\startmap\.
* You'll see where your own pre-briefing, briefing, objectives title screen etc. will appear.
* 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.
* The shop will not show because it is not enabled in the map
* In-game weapons/ammo/tools are present via another method.
* At game start you will see the player drop properly as if from a high wall
* Developer text will show by default to indicate where things are. To disable this, set difficulty to 0 (easy) on worldspawn. The text only shows on Hard difficulty and I set the map by default to Hard because it is the least used. Remember to delete these text entities at least when you finish developing your FM. IMPORTANT: Also delete the difficulty setting property completely from worldspawn else I think it overrides the player option.
* In-game weapons/ammo/tools are present.
* You will find a blank demo in-game map in the inventory.
* You can see the readables work. Later you can enter your own text. More fonts available via prefabs.
* 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.
* In the player inventory is a blank demo game map.
* Through one doorway is a wide choice of water colours and murks.
* Through another doorway is a set of of rooms each with all common combinations of AI, heads, bodies, and skins. WARNING! Set noTarget 1 in the console before visiting those rooms.
* 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.
* 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==
==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 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.
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.
* 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.
* 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.
* Copy your darkmod\Darkmod.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.
* 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?==
==Project versus Non-Project?==
Line 88: Line 139:
* 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.
* 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.  
To setup as a common map, copy the startmap.map file from darkmod\fms\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.
You also need to copy the file darkmod\fms\mymap\xdata\startmap.xd to \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.
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 darkmod\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.
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 darkmod\fms\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===
===Project Map Setup===
Line 113: Line 164:
Dark Mod needs to know the exact filename of your map if it is to be installed and run via the New Mission menus:
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.
Open darkmod\fms\mymap\startingmap.txt in a plain text editor.
* Change the text to: mymap
* Change the text to: mymap
* Resave.
* Resave.
Line 121: Line 172:
The pre-briefing intro is the text that shows in the Dark Mod New Mission menu when an FM is selected in the list:
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.
* Open darkmod\fms\mymap\darkmod.txt in a plain text editor.
* Change the title to: mymap (or My Map! or any name you like)
* 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 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.
Line 142: Line 193:


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.
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===
===Project Desktop Shortcuts===


To access your map as a project from Dark Radiant you need to set the game parameters in Preferences > Game thus:
To access your map as a project from Dark Radiant you can either make a desktop shortcut OR set the game parameters in Dark Radiant:
 


* Mod Base = darkmod
====Setting Game Parameters within Dark Radiant====
* Mod = mymap
 
To configure Dark Radiant to access your map in a project folder:
 
* Dark Radiant > Edit Menu > Preferences > Game:
* Mod (fs_game) = mymap
* Mod Base (fs_game_base, optional) = darkmod


You must then relaunch Dark Radiant.
You must then relaunch Dark Radiant.
Line 154: Line 212:
When you want to access the maps in darkmod\maps you should delete mymap from Mod (leave it blank) 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.  
====Dark Radiant Project Shortcut====
 
To regularly use Dark Radiant to switch to different project folders it is easier to create desktop shortcuts for each rather than set the game parameters within Dark Radiant:
 
* Create a Dark Radiant desktop shortcut
* RMB menu > properties
* Add to darkradiant.exe in  'Target' field the parameter:
** fs_game_base=darkmod fs_game=mymap
* So the target field should be eg,
** C:\DarkRadiant\DarkRadiant.exe fs_game_base=darkmod fs_game=mymap
* Rename the shortcut eg, Dark Radiant mymap
 
Whenever you run that shortcut then the game parameters will automatically be set in Preferences.
 
 
===Playing Project FMs in Dark Mod===


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 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 install your map project as the current FM and it will remain current each time you launch TheDarkMod.exe - 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:
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:
Line 164: Line 237:
+set fs_game_base darkmod +set fs_game mymap
+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.
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 darkmod\fms\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\mymap_misc Folder==
Line 175: Line 248:
==Using the Startpack==
==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.
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 items list entity, loading screen with progress bar. When finished any unwanted elements can be deleted.


===Map Starting===
===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.
If you have followed the above you already have a folder darkmod\fms\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...
I'll go through the various components and what you need to do with them...
Line 193: Line 266:
===Blue Room===
===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 Pallette, 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.
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.
I don't know the origin of the term 'blue room' but it is widely used in Thief Dromed editing.
Line 202: Line 275:


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.
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===
===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.
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.
This is now incorporated into a start drop delay. See [[#Player Start Drop Delay]] for details


===Master Key for Testing===
===Master Key for Testing===
Line 211: Line 288:
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.
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.
NOTE! This will probably get renamed to key_master2 if importing startpack into an existing map. In which case, rename it key_master or it will not work.
 
IMPORTANT! Remember to delete the master key or set its spawnarg inv_map_start to 0 when finished.


===Ammo, Weapons, Player Tools, Start Inventory===
===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.
There are several ways to provide the player with weapons, ammo, and tools:
* 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.
* They can be provided in the pre-game purchase shop either given or to buy (see [[#Purchase Shop]]
** Compass
* The player can start eg, in his own room with items in the game on a table or in a chest etc. (see below)
** Lantern
* Items can appear later in the game placed at strategic points (this should especially be used for mission-critical items.) (see below)
** Spyglass
* 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 all the common tools and arrows etc with inv_map_start already set to 1. They each have large amounts for use while developing and testing. Once your FM is near completion you an easily delete any you don't want and set the amounts you want for every item for each difficulty level.
** Health potion (10)
 
** Breath potion (10)
In ortho Top view, all item types are set out in columns:
** Flash bomb (10)
 
** The last few all have the spawnarg inv_count 10 so you get 10 in the inventory and easy to change.
Easy
** All the tools have spawnargs diff_N_nospawn set so they show on all difficulty levels but easy to change.
Hard
** Edit, add to, or delete, any of the above as you wish.
Expert
* 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===
All items are named according to difficulty, eg, BroadheadsExpert, RopeArrowsHard, HealthPotionsEasy. Just select the ones you want and set the amount you want in the inv_count property.


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:
To place tools and ammo in the game for the player to find just clone them from the blue room, set inv_map_start to 0 and adjust the difficulty/amounts settings already included.


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.
===Purchase Shop===


Throughout shoplist.txt the various difficulties are numbered 0, 1, 2 for normal, hard, expert.
The purchase shop is only available if you launch via the Dark Mod New Mission menus. To enable the shop to show:


====Difficulty Level Names====
*** Select any worldspawn brush
*** Set the property shop_skip to 0


Near the top of shoplist.txt you should see:
Shop items can now be listed in a dedicated atdm:shop entity (named ShopItems in the startmap.)  They can also still be added to worldspawn to retain backwards compatibility. Although you can directly edit shop items on the entity or worldspawn it can be confusing. Instead I have included a special prefab of the entity - mymap_misc\ShopItems.pfb which is easier to read and edit in a text editor then import into your map as follows:


"difficulty0Name" "Normal"
In the darkmod\mymap_misc\ folder you will see ShopItems.pfb in which I have listed all common items in easy to read format and all set to ZERO and included comments as a guide. Open it in a plain text editor and edit the ShopItems.pfb as follows:
"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".
Comment lines begin with a double slash //. They are remarks only and do not import into the map.


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.
Throughout ShopItems.pfb the various difficulties are numbered 0, 1, 2 for normal, hard, expert.


Save shoplist.txt and save frequently throughout the following...


====Spending Money====
====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:
At the top of ShopItems.pfb are the number of gold pieces provided for the player to spend in the shop. It is only of use in the shop and 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 the maximum 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. I suggest put large quantities of items in the shop and large amounts of gold then test to determine how much you can buy by starting the FM. You can go back and restart quickly to try different combinations. Some goods are costly; some are cheap. When you eventually have evaluated what would be a reasonable amount of gold for each difficulty level then set that in the ShopItems entity or prefab:


  "diff_0_shop_gold_start" "0"
  "diff_0_shop_gold_start" "0"
  "diff_1_shop_gold_start" "0"
  "diff_1_shop_gold_start" "0"
  "diff_2_shop_gold_start" "0"
  "diff_2_shop_gold_start" "0"


====Free Starting Items====
====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.
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 (such things should be in the map.) So further down in ShopItems.pfb you will see most common items listed in this format 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 can delete any items if you are certain they are not needed!'''''


'''''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 include items defined in darkmod\def\tdm_shopitems.def. They are all currently listed in ShopItems.pfb. Advanced users can add to that and include it with their FM. (see [[#Adding a New Item to the Shop])'''''
'''''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.
Naturally, some items like sword, blackjack, compass, etc you can only give a quantity of 0 or 1 but others can be any amount.
Line 301: Line 363:
   
   
  ...and so on.
  ...and so on.
NOTE: at the time of writing you have to identify each item for every difficulty if the quantities are different, eg, use "startingitem_2_0_item" "weapon_blackjack" instead of "startingitem_2_item" "weapon_blackjack". This should be changed soon.


====Shop Items for Sale====
====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...
Further down in ShopItems.pfb 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_item" "weapon_waterarrow"
Line 311: Line 376:
  "shopItem_3_2_qty" "0"
  "shopItem_3_2_qty" "0"


====Importing the shoplist.txt into your map====
====Importing the ShopItems.pfb into your map====
 
When you have edited ShopItems.pfb as described above, you can import it into your map as follows:
 
* In your editor, search for the existing ShopItems entity and delete it.
* Menu > File > Import Prefab > browse to mymap_misc folder (or insert in Orthoview RMB menu.)
* Select and open ShopItems.pfb
* Check where it is located. By default it imports to 0,0,0 in the blue room where the previous one was.
* Save your map.
 
 
====Adding a New Item to the Shop====
 
If the entity you want to have in the shop is not in the prefab described above in [[#Purchase Shop]] you can add another Dark Mod entity this way:
 
* Read darkmod\def\tdm_shopitems.def in a plain text editor to see if there is already a shop item defined for it.
* If not, create a new one in mymap\def\custom.def by copying and modifying the one in there for the game map. This is well-commented in the def itself.
* Add it to the shop items entity or prefab as described above in [[#Purchase Shop]]
 
Because all shop items must be spawned at game start, you cannot include individual entities that are already in the map. Advanced users can create new entity defs and put them in mymap\def\custom.def. You will also need a shop item defined for it and you can copy and modify the one in mymap\def\custom.def for the game map.
 
Note that custom.def can of course be renamed if you wish to any legal filename, eg, mymap.def or you can have several def files if desired but they must all be in the def folder.
 


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.
===Adding an In-game Map to your FM===
* In a plain text editor open doom3\mymap\maps\shoplist.txt
 
* Select ALL to copy to the clipboard
Summary: at its simplest, just replace the 1024 x 768 blank mymap\guis\assets\game_maps\map_of.tga with your own in-game map image file and it will work in the game.
* In a plain text editor open your mymap.map
 
* About the 4th line down you should see "classname" "worldspawn"
An in-game map is a map the player can view much like a readable to get information about the layout of the terrain. It can be a formal design the player just 'has' or it can be worked into the story, eg, "Jasket's map". It can be set up either in the shop or provided in the player inventory or the player can find it in the game.
* 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...
All in-game maps are by their very nature custom made. You can make a single map or make several maps, eg, one for the street area, one for the mansion 1st floor, one for the 2nd etc.
* "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.
====Creating an In-game Map Image File====
* (Below that it is probably followed by eg, "editor_something etc.)
 
* Now select and delete everything between those blank lines.
Create your map image size 1024 x 768. There is a blank parchment background demo image: mymap\guis\assets\game_maps\map_of.tga you can use as a start background or just to get an idea of size, etc. The central map (sheet, parchment) image itself should be stored as the alpha channel in the image so the edge can be ragged and softened and the surrounding is transparent in-game. If you don't know how to do that you can just create an image background (sheet, parchment) that completely fills the 1024 x 768. It will not have a soft ragged edge in game but it will work OK.
* 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.
Advanced users will be able to create the in-game map image without help. I'll describe some ideas here for those us with fewer artistic and technical skills. You can:
* 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.)
# Draw the map on paper and scan it in. Perhaps process it later in a paint program.
# Draw the map directly in a paint package.
# In Dark Radiant:
** Open the map.
** Full screen ortho plan view
** filter out entities and non-essentials to just show the terrain.
** Press the Prt Scr key to copy it to the Windows clipboard
** Paste it into a paint program.
** Enhance it according to your skills. If your paint program has layers then try tracing over the lines by mouse with a thick soft brush to give an impression of hand-drawn.
 
Save the map image in tga format as mymap\guis\assets\game_maps\map_of.tga. This can be any path\name but should match the path and name defined in guis\map_of.gui, see later. You might like to rename the image file, eg, map_of_manor_dread.tga for instance. If you want multiple maps then just save several image files eg, map_of_01.tga, map_of_02.tga etc. You will need separate map_of.gui files for each.
 
The image file also needs a material definition described in the next section...
 
 
====The In-game Map Material Def====
 
Look in mymap\materials\custom.mtr to see the definition for the default blank in-game map image. This enables the transparent edge. If you change the path or name of the image file then you need to change it in this mtr file too. The def name in the def file must match that in the gui (see next section) so if you change one you must change the other.
 
Note that custom.mtr can of course be renamed if you wish to any legal filename, eg, mymap.mtr or you can have several mtr files if desired but they must all be in the materials folder.
 
Also note that this will make the onscreen map image semi-transparent. If you want an opaque map, then skip this step.
 
====The In-game Map Gui====
 
Each map image must have its own gui file. Look in mymap\guis\map_of.gui to see how it is set out. Note that the 'background' refers to the image file so if you change its name or path you must also change it in this gui. Copy the gui if want multiple maps.
 
Note that map_of.gui can of course be renamed if you wish to any legal filename, eg, map_of_catacombs.gui or you can have several gui files if desired but they must all be in the guis folder. BUT the gui is referred to in the map entity def in custom.def in the spawnarg "gui" so change that too OR if you are not using the shop then you can set the gui spawnarg on the entity in the map (that way you only need one def for multiple maps) see the next section.
 
 
====The In-game Map Entity====
 
* The In-game Map Entity is defined in custom.def.
* If you ''do'' want the in-game map in the shop:
** You must have one entity definition plus one shop item definition for every in-game map.
** In the def in custom.def, set inv_name to whatever name you want to appear in the inventory (eg, map of second floor.)
** If necessary, adjust the ShopItem def too. This is well-commented in the def itself.
** Delete the entity 'MapOfTerritory' in the startmap or set inv_map_start to 0 on it.
* If you do ''not'' want the in-game map in the shop then you must include the atdm:map_of entity in the map itself:
** There is already one atdm:map_of entity in the startmap by way of example and demo. It is in the blue room and named 'MapOfTerritory'.  
** Set inv_map_start to 1 so it is in the player inventory at start OR set that to 0 (or delete the entity) if you are not using it or putting it in the shop.
** Set inv_name to whatever name you want to appear in the inventory (eg, map of second floor.) Note that you must do this in the original def in custom.def if you are putting the map in the shop.
 
To create a map that a player finds in the mission, see [[In-game Map Entities]]


===Readables===
===Readables===
Line 342: Line 471:
* In entity inspector, look at the spawnarg xdata_contents
* In entity inspector, look at the spawnarg xdata_contents
* Copy the value of that property to the clipboard, eg, book_gothic
* Copy the value of that property to the clipboard, eg, book_gothic
* Open doom3\mymap\xdata\mymap.xd in a plain text editor.
* Open darkmod\fms\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
* 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:
* If you copied the book then:
Line 376: Line 505:


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]])
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]])
Additional Note: Sometimes a readable (like any entity) might become unfrobbable. It does not highlight. The most common cause for this is if it is not close to a large brush such as a wall or table top. Add the property and value: frobbox_size 8 or 10 or 12 should cure it.
===AI Character Combinations===
In Dark Mod, AI bodies can have different skins to make them look quite different and different heads can be assigned. Quite a large variety are now available for many of the AI types so it might not be easy to visualize all the possibilities. I have set up various rooms each with their own AI type with just about every human combination currently available and that will work with Dark Mod Release 1. Until after that time I recommend you do not use any other AI unless you know for certain they will work with Release 1 or you might find they might not animate properly etc. Progress is continuously being made so the situation keeps changing. The AI I have included in Startpack 3 are based on the best information available.
Static models of some extra attachments like headgear and weapons are added so you can see them in Dark Radiant. In-game the AI have their own clearly visible.
The AI rooms are off a central double corridor and from left round to right the types are:
* Commoners, street people, servants.
* Armed commoners, some with daggers, some with bows and arrows.
* Nobles, some armed with shortswords.
* Builders and priests.
* Rats.
* City Watch, the local authority, some with longswords, some are archers.
* Generic armed guards, mercenaries, etc., some with longswords, some are archers. These typically guard mansions and other private buildings, etc.
* Thieves. These are essentially armed commoners but have their own team. They can use all the commoner heads and skins; I just put in a selection that seemed appropriate. (note the custom thief model was not ready for Release 1 so is not included.)
These can be viewed in the editor. Heads visible in the editor are for example only - they do not show in the actual game. The actual heads that AI have in-game are defined in their properties. The same is true for headgear and weapons.
These AI can also be viewed in the game itself but not every combination might show. In game you definitely need to set noTarget 1 in the console unless you wish to be attacked by 100 plus AI at once! Even when not alert there may be a significant impact on performance especially on slow systems. For this reason the doors are auto-closing and all AI have neverdormant set to 0 so they are inactive when you go out and the doors are shut.
Many AI are similar or even the same as some in other groups. But they are different teams and some are unarmed, and some are armed in different ways. For example, the thieves are armed with daggers or bows; the guards with swords or bows; and commoners and nobles can be armed or unarmed. Advanced users can change individuals weapons and other attachments but this is not covered here.
To use an AI in your own FM:
* This is very easy but the description might seem long at first:
* View in the room type and select the body you want. As well as examining them visually, they all have descriptive names such as GuardNoUniformTan_BrownNeck_Sleeves.
* Copy it and drag the copy away.
* On the copy, set neverdormant to 1 because although it should help performance to use 0, there may be problems with eg, a distant guard not responding to a request for help or even freezing in alert mode and thawing later in a bad mood!
* Now view and select a head '''''from the same room'''''. Do not move it though. Some of the heads are positioned on a neck; others float alongside; there is no difference as they are just for show. Generally it is recommended that you select a matching neck. For example a chain coif head for a chain mail body. This is not essential but it helps to hide clipping as they overlap.
* In Dark Radiant, on the head select the property ''def_head''. (Note that this is just for your convenience. It is never normally used actually on a head and has no effect on it.)
* Select your body copy.
* The ''def_head'' property should still be showing in the input box at the bottom of Entity Inspector. Click the green button to assign it to this body (note it does not show in the editor.)
That's it. You can move that AI into your own FM territory.
So, to summarise you just copy the body you want, select a head and select def_head on it, then back to the body and click. Voila! you have set up the head you want. Then neverdormant of course (hopefully we can find a better solution for that one day.)


===Texture Favourites Palette===
===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.
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.
This pallette has been moved into a room of its own as it is mainly so you can select the common textures from the texture browser immediately when you start a new map.


===Water===
===Water===
Line 385: Line 560:
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.
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.


Note that one problem with the above water overlays is that they do not respond to local lighting so may look dark in very bright areas and possibly glow slightly in extremely dark one. They should approximate typical game lighting though for most conditions but if you want to adjust the darkness you can copy the material shader def to your own mtr file and then change the rgb value.
===Difficulty Level Names===
Dark Mod FMs have three levels of difficulty and the player can select which in the Difficulty/Objectives menu. You can change the difficulty level names that appear in that menu if you wish to suit your FM style:
* Select any worldspawn brush or patch
* In Entity Inspector near the top of you should see the default difficulty level names:
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.


===Objectives===
===Objectives===
Line 396: Line 589:


Details of setting this up are as follows:
Details of setting this up are as follows:


====Get or Steal a Special Item Objective====
====Get or Steal a Special Item Objective====
Line 401: Line 595:
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.
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.
* 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.
* If the object you wish to use is already defined as a moveable entity then use that.
* Otherwise use the provided customisable object.
* Otherwise use the provided customisable object.
Line 428: Line 622:
* Further down, in the box next to 'Name of single entity, change the name from ItemName to the name you gave the entity.
* 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.
* Click OK. Click OK again on the main objectives window then save your map.


====Steal Loot Objective====
====Steal Loot Objective====


First, decide how much loot you want the player to steal on each difficulty level. You need to evaluate the value of all the loot in your FM and how difficult it is to retrieve. I do not know of any way to find this value easily. I can only suggest two ways:
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.


# * While developing your FM, whenever you create loot items, select 'show inherited properties' in entity inspector and find the spawnarg ''inv_loot_value''. Click the button to set that and it will then be written into the map when saved.
As your FM nears completion you need to more precisely evaluate how much the player has to steal on each difficulty level.
* When finished, open your map in a plain text editor.
 
* Search down for every line with inv_loot_value on it.
You need to find the total amount of loot in your FM. To do this, start your map then enter tdm_show_loot in the Dark Mod console. But do this before you get any loot as it shows remaining loot.
* If you are reasonable at mental arithmetic you can add up the loot in your head, else use a calculator.
 
# * The other way is that while playing make a note of how much loot you generally find while test playing. Evaluate the difficulty as best you can for Easy, Hard, Expert.
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):
As a general guideline, values might be (% of total loot):
Line 452: Line 647:
* Select Objective 2: Get loot (easy)
* Select Objective 2: Get loot (easy)
* Click the Edit button on the right.
* Click the Edit button on the right.
* Edit the text to what you want, eg, "You must steal at least 1000 in loot"
* Edit the text to what you want, e.g., "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 under "Components", select component #1, whose "Type" column shows "Acquire 1 entity."  This will reveal the values in other fields:
* 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.
** Type = "Player possesses item"
** Item = "Overall (component-specific)"
** Amount = 1
* Change the 1 to the amount of loot you want the player to get on Easy level, e.g., 1000.
* Click OK.
* Click OK.
* Repeat for Hard and Expert levels.
* Repeat for Hard and Expert levels.
Line 473: Line 671:
* Click the radio button 'ongoing' (on the flags line higher up) 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.
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'====
====Go to Location (Escape) and 'When All Objectives Done'====
Line 494: Line 693:
* Test this carefully for timing, atmosphere, and most of all, reliability. Test it by running through also.
* 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.)
* You can have any number of these locations (not described here.)


===Title Screen Loader===
===Title Screen Loader===
Line 500: Line 701:


First you need to choose a background screen for the loading sequence so you know where to position the text.
First you need to choose a background screen for the loading sequence so you know where to position the text.


====The Default Title Screens====
====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.
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====
==== Making your own Title Screen====
Line 520: Line 723:
* Optionally, if you have art skills and a paint program you can enhance it all you like. (not described here.)
* 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.
* You can easily change this later if you save a nicer screenshot.


====Getting your Title Screen into the gui Loader====
====Getting your Title Screen into the gui Loader====
Line 549: Line 753:
* Save.
* Save.
* Advanced users can do lots more with the gui but this is enough for this guide.
* Advanced users can do lots more with the gui but this is enough for this guide.


===Briefing===
===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:
The briefing is the story introduction to your FM that shows when the player selects Start Mission from the New Mission menu. To create it:


* Open doom3\mymap\guis\mainmenu_briefing.gui in a plain text editor.
* Open mymap/xdata/briefing.xd in any plain text editor.
* Scroll down to the line that starts: #define BRIEFING_TEXT "
* Change startmap in the top line maps/startmap/mission_briefing to the name of your map, eg, maps/mymap/mission_briefing.
* Replace the text there with your own story introduction.
* Replace the default text with your own.
* Keep within the double quotes.
* Enter the number of pages used in the num_pages line.
* You can add more pages. There is no limit but most players will not want to read through a lot; they want to start playing!
* Do NOT insert linefeeds (Enter key) within the double quotes.
* Do NOT insert linefeeds (Enter key) within the double quotes.
* To force a new line use \n
* To force a new line use \n
Line 563: Line 769:
* You are briefing the player as the main purpose of his mission in a story-like way
* 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..."
* 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.
* There is room for about 100 words per page.
* 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
This briefing xdata can just as well be put in your readables xd file if you prefer. The filename is not critical only the headers so you can have mymap.xd or readables.xd if you want.


===Readme Document===
===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. There is no guarantee that the player will read it though. It is recommended you do not change the filename in case it is ever displayed within Dark Mod or by some third party FM manager such as Garrettloader.
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!
Open the file in a plain text editor to see examples of what you might include. Make sure you delete the examples at least!
===Final Important Checks===
Before packaging up:
* Make sure you have removed the master key.
* Make sure you remove the difficulty spawnarg from worldspawn. This is set on Hard to show the guide text but must be deleted or it overrides the player's difficulty setting and the FM will play only on Hard level.
* Delete the entire startmap playable area but NOT the blue room with the weapons, player tools etc. Deleting the startmap play area reduces the size of the map and assets loaded (so reducing loading time.)
* Have you disabled or deleted unwanted weapons, player tools etc in the blue room and adjusted the amounts of ammo for each difficulty level?
* Maybe check realistic loot levels for objectives in case you've added more loot since setting the objectives. You can determine the total amount of loot in your FM by entering ''tdm_show_loot'' in the console. But do this before you get any loot as it shows remaining loot.


===Packaging For Distribution===
===Packaging For Distribution===
Line 582: Line 808:


This is what you must now do to package this up:
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:
* 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 Darkmod.cfg to mymap_misc.
** Move your .darkradiant file to mymap_misc.
** Move your .darkradiant file to mymap_misc.
** Move your maps\mymap.bak file to mymap_misc.
** Move your maps\mymap.bak file to mymap_misc.
Line 592: Line 820:
** config.spec
** config.spec
** gamex86.dll
** gamex86.dll
** (Doom will recreate the above next run.)
** (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.
(Standalone 2.0 does not generate these per-mission. You shouldn't need them in the darkmod\fms\mymap folder. You can delete them from your base darkmod directory and they will get generated again but that step is not necessary.)
 
* MOVE your mymap_misc into the doom3 folder (or avoid zipping it up.)
* 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 name will eventually be the folder name when this is installed by players.''
** ''It should be distinctive. If two FM zips 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
* Rename the suffix of the zip file to a .pk4
* Create a temporary new folder somewhere else named mymap.
* 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:
* Move the .pk4 file you just made into it.
* Rename your darkmod\fms\mymap folder to eg mymapORG.
* Zip up this entire new mymap folder.
* Delete or rename your old darkmod\fms\mymap folder.
This is now the archive that is ready for distribution and that players will download. To simulate what players will do and test it all works correctly:
* 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.
* Rename your doom3\mymap folder to eg mymapORG
* 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.)
* Delete or rename your old darkmod\fms\mymap folder
* 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.
* Extract the new zip file you made into the darkmod\fms folder.
 
* You should now have a new folder darkmod\fms\mymap and within it ONLY the .pk4 file you made.
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...
* It is now ready to play.
 
* When you test via the Dark Mod menus it will recreate the mymap folder and run the FM.
* 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 TheDarkMod.exe.
 
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.
* Give it a thorough test and have it beta-tested one more time if possible.
* If you cannot see your mymap in the New Mission list then it is possible it is still in the currentfm.txt as current. You can exit and safely delete currentfm.txt if so.


Congratulations! You now have a properly finished and professional FM!
Congratulations! You now have a properly finished and professional FM!
==Additional Features==
===Internal Leak Test Entity===
Entity #1 in the map file is a cross-shaped unrendered func_static called LeakTest in the blue room. If your map has a leak during development then Doom3 creates a pointfile containing the coordinates of a line leading from the void to the earliest entity it can find. This can be used to test that internal portal areas do not leak. For details, read [[Performance: Essential Must-Knows#Internal Leaks]]
===Player Start Drop Delay===
Many Dark Mod FMs will begin with the thief dropping down from a wall, etc. At game start there seems to be a tiny delay (0.25 seconds?) before the view is rendered so the player only sees the end of the drop, maybe none of it.
The startmap includes a player start with a platform that is removed after 0.25 of a second. Reduce delay for lower heights. If you look at the player start you will find it inside a closed box (to prevent players mantling out at game start!) This step is triggered automatically if the player is inside.
If you want to use this feature then you need to move the following three nested components as well as player start to where you want your player to start:
StartDropTriggerDelay
StartStepRemover
StartStep
Adjust the delay property on StartDropTriggerDelay if necessary to what you want.
An additional tip: If you want a fairly precise start position and rotation of the player start then try the following: Once you have placed and rotated your player start, on the info_player_start select 'origin', rename it say 'originORG' and press Enter to store it. Repeat with 'Angle' to 'AngleORG'. Now whenever you want to move the player start anywhere for testing you can just drag it or use the Dark Radiant keys. Any time you want to restore the player start you just reverse the above process.


==Startpack Future versions==
==Startpack Future versions==


Future versions of the startpack might include:
Future versions of the startpack might include:
* Better texture palette cubes so your most-used textures are available
Common speaker configurations; just clone and drop an ambient crowd noise or tense music where needed - or a local sound such as a machine or stream.
* 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.
 
 


[[Category:Editing]]
[[Category:Editing]]
[[Category:Tutorial]]
[[Category:Mapping Tutorials]]

Latest revision as of 03:40, 25 March 2024

Startpack Version 3

written by Fidcal


Download

You can get Startpack from:

https://www.moddb.com/mods/the-dark-mod/addons/start-map-example

New 2.0 Path Details

To provide background context on the transition from The Dark Mod's "Doom 3 mod" phase

vs the Standalone 2.0 practices please review the following:

http://forums.thedarkmod.com/topic/15152-new-dr-folder-settings-for-tdm-20/


Summary

  • Keep the original startmap.pk4 as a master somewhere.
  • When you begin a completely new FM then first install Startmap like any other FM.
  • You can play Startmap right up to Mission Complete in about 60 seconds.
  • So all you do is change it to be your own FM.
  • You change the title, the texts, etc.
  • You modify the objectives, eg, change loot amounts, etc.
  • You already will have lots of test ammo and all player tools.
  • Easier to delete what you don't want than figure out how to put them in anew.
  • Default ambient light is set up for the entire map.
  • You leave the startmap terrain where it is for now.
  • You build afresh elsewhere in the map and move the player start point to where you want it.
  • You copy or move any of the stuff provided and/or add your own.
    • Eg, there is an example of every AI variation - copy and drag where you want.
    • There are ready-made readables - copy and drag where you want and add your own text.
  • When you have finished your FM you can delete the startmap terrain (but it's harmless if you don't.)
  • At all stages you have an installed, working, completeable, FM.
  • As an alternative you can insert it into an existing map or just grab what you want!

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 in plain text xdata format.
  • Objectives template with most-common objectives working
  • Difficulty level names on worldspawn
  • Purchase shop list entity & easy-read prefab with comments
  • Custom shop item template
  • In-game terrain map template.
  • Player tools, weapons, and ammo; easy to set difficulty amounts
  • 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.
  • Internal Leak Test entity.
  • Player start drop to overcome rendering delay at map start.
  • All common AI heads, bodies, and skins combinations to easily pick from wide selection.

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 darkmod\fms\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
      • Shop 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 darkmod\fms\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:

  • UNinstall any previous startmap version if installed at the Dark Mod menus. To do this either install another FM at the Dark Mod menus or else delete darkmod\currentfm.txt.
  • Delete any previous darkmod\fms\startmap folder or rename it if you want to keep it for reference, etc.
  • (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 darkmod\Darkmod.cfg to darkmod\fms\startmap\.
  • You'll see where your own pre-briefing, briefing, objectives title screen etc. will appear.
  • The shop will not show because it is not enabled in the map
  • At game start you will see the player drop properly as if from a high wall
  • Developer text will show by default to indicate where things are. To disable this, set difficulty to 0 (easy) on worldspawn. The text only shows on Hard difficulty and I set the map by default to Hard because it is the least used. Remember to delete these text entities at least when you finish developing your FM. IMPORTANT: Also delete the difficulty setting property completely from worldspawn else I think it overrides the player option.
  • In-game weapons/ammo/tools are present.
  • You will find a blank demo in-game map in the inventory.
  • You can see the readables work. Later you can enter your own text. More fonts available via prefabs.
  • In the player inventory is a blank demo game map.
  • Through one doorway is a wide choice of water colours and murks.
  • Through another doorway is a set of of rooms each with all common combinations of AI, heads, bodies, and skins. WARNING! Set noTarget 1 in the console before visiting those rooms.
  • 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 darkmod\Darkmod.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 darkmod\fms\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 darkmod\fms\mymap\xdata\startmap.xd to \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 darkmod\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 darkmod\fms\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 darkmod\fms\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 darkmod\fms\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 can either make a desktop shortcut OR set the game parameters in Dark Radiant:


Setting Game Parameters within Dark Radiant

To configure Dark Radiant to access your map in a project folder:

  • Dark Radiant > Edit Menu > Preferences > Game:
  • Mod (fs_game) = mymap
  • Mod Base (fs_game_base, optional) = darkmod

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.

Dark Radiant Project Shortcut

To regularly use Dark Radiant to switch to different project folders it is easier to create desktop shortcuts for each rather than set the game parameters within Dark Radiant:

  • Create a Dark Radiant desktop shortcut
  • RMB menu > properties
  • Add to darkradiant.exe in 'Target' field the parameter:
    • fs_game_base=darkmod fs_game=mymap
  • So the target field should be eg,
    • C:\DarkRadiant\DarkRadiant.exe fs_game_base=darkmod fs_game=mymap
  • Rename the shortcut eg, Dark Radiant mymap

Whenever you run that shortcut then the game parameters will automatically be set in Preferences.


Playing Project FMs in Dark Mod

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.

You can install your map project as the current FM and it will remain current each time you launch TheDarkMod.exe - 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 darkmod\fms\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 items list entity, 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 darkmod\fms\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.

This is now incorporated into a start drop delay. See #Player Start Drop Delay for details


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.

NOTE! This will probably get renamed to key_master2 if importing startpack into an existing map. In which case, rename it key_master or it will not work.
IMPORTANT! Remember to delete the master key 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 weapons, ammo, and tools:

  • They can be provided in the pre-game purchase shop either given or to buy (see #Purchase Shop
  • The player can start eg, in his own room with items in the game on a table or in a chest etc. (see below)
  • Items can appear later in the game placed at strategic points (this should especially be used for mission-critical items.) (see below)
  • 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 all the common tools and arrows etc with inv_map_start already set to 1. They each have large amounts for use while developing and testing. Once your FM is near completion you an easily delete any you don't want and set the amounts you want for every item for each difficulty level.

In ortho Top view, all item types are set out in columns:

Easy Hard Expert

All items are named according to difficulty, eg, BroadheadsExpert, RopeArrowsHard, HealthPotionsEasy. Just select the ones you want and set the amount you want in the inv_count property.

To place tools and ammo in the game for the player to find just clone them from the blue room, set inv_map_start to 0 and adjust the difficulty/amounts settings already included.


Purchase Shop

The purchase shop is only available if you launch via the Dark Mod New Mission menus. To enable the shop to show:

      • Select any worldspawn brush
      • Set the property shop_skip to 0

Shop items can now be listed in a dedicated atdm:shop entity (named ShopItems in the startmap.) They can also still be added to worldspawn to retain backwards compatibility. Although you can directly edit shop items on the entity or worldspawn it can be confusing. Instead I have included a special prefab of the entity - mymap_misc\ShopItems.pfb which is easier to read and edit in a text editor then import into your map as follows:

In the darkmod\mymap_misc\ folder you will see ShopItems.pfb in which I have listed all common items in easy to read format and all set to ZERO and included comments as a guide. Open it in a plain text editor and edit the ShopItems.pfb as follows:

Comment lines begin with a double slash //. They are remarks only and do not import into the map.

Throughout ShopItems.pfb the various difficulties are numbered 0, 1, 2 for normal, hard, expert.


Spending Money

At the top of ShopItems.pfb are the number of gold pieces provided for the player to spend in the shop. It is only of use in the shop and 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 the maximum 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. I suggest put large quantities of items in the shop and large amounts of gold then test to determine how much you can buy by starting the FM. You can go back and restart quickly to try different combinations. Some goods are costly; some are cheap. When you eventually have evaluated what would be a reasonable amount of gold for each difficulty level then set that in the ShopItems entity or prefab:

"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 (such things should be in the map.) So further down in ShopItems.pfb you will see most common items listed in this format 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.

You can delete any items if you are certain they are not needed!

You can only include items defined in darkmod\def\tdm_shopitems.def. They are all currently listed in ShopItems.pfb. Advanced users can add to that and include it with their FM. (see [[#Adding a New Item to the Shop])

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.
NOTE: at the time of writing you have to identify each item for every difficulty if the quantities are different, eg, use "startingitem_2_0_item" "weapon_blackjack" instead of "startingitem_2_item" "weapon_blackjack". This should be changed soon.


Shop Items for Sale

Further down in ShopItems.pfb 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 ShopItems.pfb into your map

When you have edited ShopItems.pfb as described above, you can import it into your map as follows:

  • In your editor, search for the existing ShopItems entity and delete it.
  • Menu > File > Import Prefab > browse to mymap_misc folder (or insert in Orthoview RMB menu.)
  • Select and open ShopItems.pfb
  • Check where it is located. By default it imports to 0,0,0 in the blue room where the previous one was.
  • Save your map.


Adding a New Item to the Shop

If the entity you want to have in the shop is not in the prefab described above in #Purchase Shop you can add another Dark Mod entity this way:

  • Read darkmod\def\tdm_shopitems.def in a plain text editor to see if there is already a shop item defined for it.
  • If not, create a new one in mymap\def\custom.def by copying and modifying the one in there for the game map. This is well-commented in the def itself.
  • Add it to the shop items entity or prefab as described above in #Purchase Shop

Because all shop items must be spawned at game start, you cannot include individual entities that are already in the map. Advanced users can create new entity defs and put them in mymap\def\custom.def. You will also need a shop item defined for it and you can copy and modify the one in mymap\def\custom.def for the game map.

Note that custom.def can of course be renamed if you wish to any legal filename, eg, mymap.def or you can have several def files if desired but they must all be in the def folder.


Adding an In-game Map to your FM

Summary: at its simplest, just replace the 1024 x 768 blank mymap\guis\assets\game_maps\map_of.tga with your own in-game map image file and it will work in the game.

An in-game map is a map the player can view much like a readable to get information about the layout of the terrain. It can be a formal design the player just 'has' or it can be worked into the story, eg, "Jasket's map". It can be set up either in the shop or provided in the player inventory or the player can find it in the game.

All in-game maps are by their very nature custom made. You can make a single map or make several maps, eg, one for the street area, one for the mansion 1st floor, one for the 2nd etc.


Creating an In-game Map Image File

Create your map image size 1024 x 768. There is a blank parchment background demo image: mymap\guis\assets\game_maps\map_of.tga you can use as a start background or just to get an idea of size, etc. The central map (sheet, parchment) image itself should be stored as the alpha channel in the image so the edge can be ragged and softened and the surrounding is transparent in-game. If you don't know how to do that you can just create an image background (sheet, parchment) that completely fills the 1024 x 768. It will not have a soft ragged edge in game but it will work OK.

Advanced users will be able to create the in-game map image without help. I'll describe some ideas here for those us with fewer artistic and technical skills. You can:

  1. Draw the map on paper and scan it in. Perhaps process it later in a paint program.
  2. Draw the map directly in a paint package.
  3. In Dark Radiant:
    • Open the map.
    • Full screen ortho plan view
    • filter out entities and non-essentials to just show the terrain.
    • Press the Prt Scr key to copy it to the Windows clipboard
    • Paste it into a paint program.
    • Enhance it according to your skills. If your paint program has layers then try tracing over the lines by mouse with a thick soft brush to give an impression of hand-drawn.

Save the map image in tga format as mymap\guis\assets\game_maps\map_of.tga. This can be any path\name but should match the path and name defined in guis\map_of.gui, see later. You might like to rename the image file, eg, map_of_manor_dread.tga for instance. If you want multiple maps then just save several image files eg, map_of_01.tga, map_of_02.tga etc. You will need separate map_of.gui files for each.

The image file also needs a material definition described in the next section...


The In-game Map Material Def

Look in mymap\materials\custom.mtr to see the definition for the default blank in-game map image. This enables the transparent edge. If you change the path or name of the image file then you need to change it in this mtr file too. The def name in the def file must match that in the gui (see next section) so if you change one you must change the other.

Note that custom.mtr can of course be renamed if you wish to any legal filename, eg, mymap.mtr or you can have several mtr files if desired but they must all be in the materials folder.

Also note that this will make the onscreen map image semi-transparent. If you want an opaque map, then skip this step.

The In-game Map Gui

Each map image must have its own gui file. Look in mymap\guis\map_of.gui to see how it is set out. Note that the 'background' refers to the image file so if you change its name or path you must also change it in this gui. Copy the gui if want multiple maps.

Note that map_of.gui can of course be renamed if you wish to any legal filename, eg, map_of_catacombs.gui or you can have several gui files if desired but they must all be in the guis folder. BUT the gui is referred to in the map entity def in custom.def in the spawnarg "gui" so change that too OR if you are not using the shop then you can set the gui spawnarg on the entity in the map (that way you only need one def for multiple maps) see the next section.


The In-game Map Entity

  • The In-game Map Entity is defined in custom.def.
  • If you do want the in-game map in the shop:
    • You must have one entity definition plus one shop item definition for every in-game map.
    • In the def in custom.def, set inv_name to whatever name you want to appear in the inventory (eg, map of second floor.)
    • If necessary, adjust the ShopItem def too. This is well-commented in the def itself.
    • Delete the entity 'MapOfTerritory' in the startmap or set inv_map_start to 0 on it.
  • If you do not want the in-game map in the shop then you must include the atdm:map_of entity in the map itself:
    • There is already one atdm:map_of entity in the startmap by way of example and demo. It is in the blue room and named 'MapOfTerritory'.
    • Set inv_map_start to 1 so it is in the player inventory at start OR set that to 0 (or delete the entity) if you are not using it or putting it in the shop.
    • Set inv_name to whatever name you want to appear in the inventory (eg, map of second floor.) Note that you must do this in the original def in custom.def if you are putting the map in the shop.
To create a map that a player finds in the mission, see In-game Map Entities

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 darkmod\fms\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)

Additional Note: Sometimes a readable (like any entity) might become unfrobbable. It does not highlight. The most common cause for this is if it is not close to a large brush such as a wall or table top. Add the property and value: frobbox_size 8 or 10 or 12 should cure it.


AI Character Combinations

In Dark Mod, AI bodies can have different skins to make them look quite different and different heads can be assigned. Quite a large variety are now available for many of the AI types so it might not be easy to visualize all the possibilities. I have set up various rooms each with their own AI type with just about every human combination currently available and that will work with Dark Mod Release 1. Until after that time I recommend you do not use any other AI unless you know for certain they will work with Release 1 or you might find they might not animate properly etc. Progress is continuously being made so the situation keeps changing. The AI I have included in Startpack 3 are based on the best information available.

Static models of some extra attachments like headgear and weapons are added so you can see them in Dark Radiant. In-game the AI have their own clearly visible.

The AI rooms are off a central double corridor and from left round to right the types are:

  • Commoners, street people, servants.
  • Armed commoners, some with daggers, some with bows and arrows.
  • Nobles, some armed with shortswords.
  • Builders and priests.
  • Rats.
  • City Watch, the local authority, some with longswords, some are archers.
  • Generic armed guards, mercenaries, etc., some with longswords, some are archers. These typically guard mansions and other private buildings, etc.
  • Thieves. These are essentially armed commoners but have their own team. They can use all the commoner heads and skins; I just put in a selection that seemed appropriate. (note the custom thief model was not ready for Release 1 so is not included.)

These can be viewed in the editor. Heads visible in the editor are for example only - they do not show in the actual game. The actual heads that AI have in-game are defined in their properties. The same is true for headgear and weapons.

These AI can also be viewed in the game itself but not every combination might show. In game you definitely need to set noTarget 1 in the console unless you wish to be attacked by 100 plus AI at once! Even when not alert there may be a significant impact on performance especially on slow systems. For this reason the doors are auto-closing and all AI have neverdormant set to 0 so they are inactive when you go out and the doors are shut.

Many AI are similar or even the same as some in other groups. But they are different teams and some are unarmed, and some are armed in different ways. For example, the thieves are armed with daggers or bows; the guards with swords or bows; and commoners and nobles can be armed or unarmed. Advanced users can change individuals weapons and other attachments but this is not covered here.

To use an AI in your own FM:

  • This is very easy but the description might seem long at first:
  • View in the room type and select the body you want. As well as examining them visually, they all have descriptive names such as GuardNoUniformTan_BrownNeck_Sleeves.
  • Copy it and drag the copy away.
  • On the copy, set neverdormant to 1 because although it should help performance to use 0, there may be problems with eg, a distant guard not responding to a request for help or even freezing in alert mode and thawing later in a bad mood!
  • Now view and select a head from the same room. Do not move it though. Some of the heads are positioned on a neck; others float alongside; there is no difference as they are just for show. Generally it is recommended that you select a matching neck. For example a chain coif head for a chain mail body. This is not essential but it helps to hide clipping as they overlap.
  • In Dark Radiant, on the head select the property def_head. (Note that this is just for your convenience. It is never normally used actually on a head and has no effect on it.)
  • Select your body copy.
  • The def_head property should still be showing in the input box at the bottom of Entity Inspector. Click the green button to assign it to this body (note it does not show in the editor.)

That's it. You can move that AI into your own FM territory.

So, to summarise you just copy the body you want, select a head and select def_head on it, then back to the body and click. Voila! you have set up the head you want. Then neverdormant of course (hopefully we can find a better solution for that one day.)

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.

This pallette has been moved into a room of its own as it is mainly so you can select the common textures from the texture browser immediately when you start a new map.


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.

Note that one problem with the above water overlays is that they do not respond to local lighting so may look dark in very bright areas and possibly glow slightly in extremely dark one. They should approximate typical game lighting though for most conditions but if you want to adjust the darkness you can copy the material shader def to your own mtr file and then change the rgb value.

Difficulty Level Names

Dark Mod FMs have three levels of difficulty and the player can select which in the Difficulty/Objectives menu. You can change the difficulty level names that appear in that menu if you wish to suit your FM style:

  • Select any worldspawn brush or patch
  • In Entity Inspector near the top of you should see the default difficulty level names:

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.

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, start your map then enter tdm_show_loot in the Dark Mod console. But do this before you get any loot as it shows remaining loot.

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, e.g., "You must steal at least 1000 in loot"
  • Further down, in the box under "Components", select component #1, whose "Type" column shows "Acquire 1 entity." This will reveal the values in other fields:
    • Type = "Player possesses item"
    • Item = "Overall (component-specific)"
    • Amount = 1
  • Change the 1 to the amount of loot you want the player to get on Easy level, e.g., 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 story introduction to your FM that shows when the player selects Start Mission from the New Mission menu. To create it:

  • Open mymap/xdata/briefing.xd in any plain text editor.
  • Change startmap in the top line maps/startmap/mission_briefing to the name of your map, eg, maps/mymap/mission_briefing.
  • Replace the default text with your own.
  • Enter the number of pages used in the num_pages line.
  • You can add more pages. There is no limit but most players will not want to read through a lot; they want to start playing!
  • 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 per page.

This briefing xdata can just as well be put in your readables xd file if you prefer. The filename is not critical only the headers so you can have mymap.xd or readables.xd if you want.

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!



Final Important Checks

Before packaging up:

  • Make sure you have removed the master key.
  • Make sure you remove the difficulty spawnarg from worldspawn. This is set on Hard to show the guide text but must be deleted or it overrides the player's difficulty setting and the FM will play only on Hard level.
  • Delete the entire startmap playable area but NOT the blue room with the weapons, player tools etc. Deleting the startmap play area reduces the size of the map and assets loaded (so reducing loading time.)
  • Have you disabled or deleted unwanted weapons, player tools etc in the blue room and adjusted the amounts of ammo for each difficulty level?
  • Maybe check realistic loot levels for objectives in case you've added more loot since setting the objectives. You can determine the total amount of loot in your FM by entering tdm_show_loot in the console. But do this before you get any loot as it shows remaining loot.

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 Darkmod.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.)

(Standalone 2.0 does not generate these per-mission. You shouldn't need them in the darkmod\fms\mymap folder. You can delete them from your base darkmod directory and they will get generated again but that step is not necessary.)

  • MOVE your mymap_misc into the doom3 folder (or avoid zipping it up.)
  • 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 name will eventually be the folder name when this is installed by players.
    • It should be distinctive. If two FM zips 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 darkmod\fms\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 TheDarkMod.exe.

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!

Additional Features

Internal Leak Test Entity

Entity #1 in the map file is a cross-shaped unrendered func_static called LeakTest in the blue room. If your map has a leak during development then Doom3 creates a pointfile containing the coordinates of a line leading from the void to the earliest entity it can find. This can be used to test that internal portal areas do not leak. For details, read Performance: Essential Must-Knows#Internal Leaks


Player Start Drop Delay

Many Dark Mod FMs will begin with the thief dropping down from a wall, etc. At game start there seems to be a tiny delay (0.25 seconds?) before the view is rendered so the player only sees the end of the drop, maybe none of it.

The startmap includes a player start with a platform that is removed after 0.25 of a second. Reduce delay for lower heights. If you look at the player start you will find it inside a closed box (to prevent players mantling out at game start!) This step is triggered automatically if the player is inside.

If you want to use this feature then you need to move the following three nested components as well as player start to where you want your player to start:

StartDropTriggerDelay StartStepRemover StartStep

Adjust the delay property on StartDropTriggerDelay if necessary to what you want.

An additional tip: If you want a fairly precise start position and rotation of the player start then try the following: Once you have placed and rotated your player start, on the info_player_start select 'origin', rename it say 'originORG' and press Enter to store it. Repeat with 'Angle' to 'AngleORG'. Now whenever you want to move the player start anywhere for testing you can just drag it or use the Dark Radiant keys. Any time you want to restore the player start you just reverse the above process.


Startpack Future versions

Future versions of the startpack might include: Common speaker configurations; just clone and drop an ambient crowd noise or tense music where needed - or a local sound such as a machine or stream.