|
QUAKE Wars Mods and Editing This is the hub for Enemy Territory: QUAKE Wars map and mod discussion, editing tips and tutorials, web application development, and the like. |
|
Thread Tools |
03-20-2008, 11:07 PM | #1 |
Lieutenant Commander
Join Date: May 2007
|
Step by step tutorial to making command map, heightmaps , deploymasks ect.
Before I get started I want you all to know the simplest way of figuring out something by your self. For me that was deploymasks and command maps. The etqw map that comes with the sdk. Located in the sdk folder it is a fully functional map that has all the resources you need to figure out something all on your own, without anyones help. But that may take hours or even days and that’s the reason I wrote this tutorial. It took me several days to figure out how to make masks and deployables work and hopefully this tutorial will turn that into an hour or two for other newbies.
General notes: By <savepath> I mean the save path you selected when you installed the sdk. Mine is C:\……\My Documents\idsoftware You will need to change your caulk hull from textures\common\caulk to textures\editor\noimpactcaulk Every time we make a change to your map you will need to compile to see the results . When you make a change to your materials you will need type reloaddecls into the console to see the result Level shot. This is probably the simplest part of the tutorial to follow, there is not much involved at all. 1. make adjustments Load your map from the sdk. Type g_showhud 0 to get rid of the hud, net_clientlagometer 0 to get rid of the lagometer and com_showfps 0. this is just to get a clear screen for your level shot. You may also want to make further adjustment to your config to get a clear shot. Info may be found here http://wiki.splashdamage.com/index.p...g_A_Screenshot 2. take the screenshot. Like it says in the wiki you can make a screenshot come out in different resolutions with a bind. “Bind f11 “screenshot 512 512 8” would be a good start. You wil have to resize it after but if you don’t want the trouble “Bind f11 “screenshot 256 256 8” so no editing is required. If you took the screenshot with the resolution of 512*512 well then you will need to resize in your preferred image editing program. Imo it might make it look slightly better but not worth the effort. Now place the screenshot in the directory <savepath>\base\levelshots\ <yourmap>.tga. 3.Make the material. You may now notice that when you load your map the level shot is red. That is because you haven’t made a material. Create or edit a file called <yourmap>.mtr . you can use any text editor but be carefull the file name isn’t “<yourmap>.mtr” but that its called <yourmap> and it’s a mtr file. Now place the file in the directory <savepath>\base\materials\<yourmap>.mtr . now add this to it Code:
material levelshots/<yourmap> { sort gui { blend blend vertexColor map nopicmip clamp "levelshots/<yourmap>" } } continued.......... edit: my levelshot displayed below
__________________
sunday night custom map nirvana, get involved!! Last edited by gamma : 03-21-2008 at 12:42 AM. |
03-20-2008, 11:08 PM | #2 | |
Lieutenant Commander
Join Date: May 2007
|
Command map
****Doesn’t include OBB***** info about command maps:http://wiki.splashdamage.com/index.p...ne_commandmap# be wary some info may be outdated. Open the etqw map in sdk\etqw.world as it will prove helpfull 1. In your map place a Playzone_commandmap entity by right clicking on a 2d window playzone>playzone_commandmap or by copy and pasting one from the etqw map(note: it is one of the brushes with trigger texture above the map). When the Playzone_commanmap is pasted press shift + O to update its origins so you wont get errors about an entity leaking. Place it across the area that you want it to cover(note: when you take the mapshot, next step, it will only take a photo of you terrain so if you have buildings outside of your terrain you will have to go through a procedure to make a full command map, I will explain that at the step 4. Now enter/change the following key/values Code:
Mtr_commandmap commandmaps\<yourmap>.tga Priority 1 Load your map up from the sdk. Open the console and type “mapshot mapshot1.tga 1024 0” this will produce a mapshot of your terrain. Take this mapshot and rename it to <yourmap>.tga and save it in the directory <savepath>\base\commandmaps\<yourmap>.tga.. The retail mapshots are 512*512 but they don’t necessarily have to be that size it is just a guideline edit: as posted by mop at the end of the page you may get misaligned mapshots if you run at high resolutions and/or widescreen. Quote:
3. make a material. Open the material file, <savepath>\base\materials\<yourmap>.mtr . and add this to it. Code:
#include <materials/commandmaps.include> material commandmaps/<yourmap> { templates/game/maps/cmMap( "commandmaps/<yourmap>.tga" ) } 4.Only follow this step if you have buildings outside you terrain. This is what I done to make my command map work even though I have building outside my terrain, there may be other ways of doing it. Note: willl only work if your terrain is less than 32k*32k Make a new terrain, it can be completely flat just don’t let it go over your buildings. Make sure that it goes beyond the bounds of your buildings .Place a brush underneath your buildings and texture it sothere is a contrast between the colours of your roof tops and the background. Now make a new mapshot. Open your preferred image editing program and crop it so that you can only see your buildings and the brush beneath. Resize all your images to an appropriate size and then copy then all onto one canvas and save.(you may need to use a texture if there is a blank part on your image. Ie. they don’t fit together properly, one could be 512*512 and another could be 256*256. if so place a sand ,rock ,grass or whatever is suitable to your terrain as a background and then place the ordinal images on top. (sorry about this part it was hard to explain) continued ......... edit: my old and new commandmap displayed below.
__________________
sunday night custom map nirvana, get involved!! Last edited by gamma : 03-22-2008 at 10:10 PM. |
|
03-20-2008, 11:09 PM | #3 |
Lieutenant Commander
Join Date: May 2007
|
Height maps. And deploy mask
(note deploymaks have to be 128*128) 1. place a playzone_path_and_heightmap entity by right clicking or copying from the etqw map(remember to update its origins by pressing shift + O. Resize the brush so that it completely covers your terrain and buildings, and enter the following key/value Code:
name <yourmap>_playzone_path_and_heightmap heightmap heightmaps/<yourmap>.tga hm_heightmap heightmaps/<yourmap> path_vehicle_magog_npc <yourmap>_vehicle_magog_npc 2 .create a .def Create a file called <yourmap>.def and place it in the directory <savepath>\base\def\maps\<yourmap>.def open the file and add the following Code:
#include "def/pathfinder.include" heightMap heightmaps/<yourmap> { heightMap "heightmaps/<yourmap>.tga" } deployMask masks/<yourmap>/mcp { mask "masks/<yourmap>/mcp.tga" } deployMask masks/<yourmap>/default { mask "masks/<yourmap>/default.tga" } deployMask masks/<yourmap>/mcp_route { mask "masks/<yourmap>/mcp_route.tga" } deployMask masks/<yourmap>/playzone { mask "masks/<yourmap>/playzone.tga" } stringMap pathfinder_<yourmap> { _pathfinder_default( "<yourmap>", 20 ) "playzone_0" "<yourmap>_playzone_path_and_heightmap" "resolution_x_playzone_0" "1280" "resolution_y_playzone_0" "1280" "mg_resolution_x_playzone_0" "1280" "mg_resolution_y_playzone_0" "1280" } 3.start the sdk and type “maskgen pathfiner_<yourmap>” don’t load your map because it can cause crashes to occur. The maskgen will output two files, the heightmap that you can leave alone and a tga in imagedump\maskgen\ , place this in your masks folder and rename it to default.tga. this will be your mask to control where deployables can deployed. For some people this may come out completely white or black and I happened to be one of those people. What I did was make my own in paint. Just by looking at a mapshot and judging where to black out. When I loaded it up I could begin to make refinements. Its time consuming and can be annoying but you got to do it. Now close the sdk as it could freeze. 4.get the path for the magog Open the sdk and type pathfinder pathfinder_<yourmap> and when it finishes it should output a file called paths. Rename this to <yourmap>_paths.def and place it in <savepath>\base\def\<yourmap>\<yourmap>_paths.de f 5.create the mcp masks and playzone mask. For the playzone mask I got a white tga and renamed it to playzone.tga and placed it in my <savepath>\base\masks folder. the playzone is the area the player can go without taking damage. completly white being no limits. **Skip this part if you don’t have an mcp escort mission in your map.** You need to make two mcp masks. One for the route and one for the deployzone. You have to make these your self by painting on a black tga. There is no easy way to do it, it is all trial and error keep refining until you get a what you want. When you have them made them rename the mcp deploy marker to mcp.tga and the route to mcp_route.tga and place them in the folder <savepath>\base\masks\<yourmap>\ 6. add the playzones Add a playzone_play entity to your map and give it the following key/value Code:
name <yourmap>_playzone_play dm_playzone masks/<yourmap>/playzone be wary some info might be outdated. Add a playzone_deploy to your map. Add the following key/values Code:
name <yourmap>_playzone_deploy dm_default masks/<yourmap>/default dm_mcp masks/<yourmap>/mcp dm_mcp_route masks/<yourmap>/mcp_route zone_vehicle_route 1 Add a deployzone. And give ot the following key.vaules Code:
Name “<the name you want>(for an outpost call it outpost_deployzone)” Mtr_territory “the location of the territory outline” eg commandmaps/etqwmap_territory_01 Start_team “the team it belongs to at the beginning of the map” Target_playzone “territory_size_thing” Now add a trigger multiple and name it “territory_size_thing”. place it above your playzones. connect your territorys to this entity. Now add as many territories as you like. A basic map should have a gdf base territory, strogg base territory and a few inbetween that can be captured by completing objectives. And there ya have it. Compile and fire off some artillery. Any mistakes, things I left out, things that need better description or your just need some more help just leave post and ill be glad to fix/help. edit: my deploymask attached below
__________________
sunday night custom map nirvana, get involved!! Last edited by gamma : 04-08-2008 at 09:07 PM. |
03-20-2008, 11:14 PM | #4 |
Commander General
|
Wow, good stuff in there. Don't have the time to go through all of it, but it looks very neat. This is certainly gonna help others out.
|
03-20-2008, 11:23 PM | #5 |
Group Commander
Join Date: Sep 2007
Location: Germany
|
Very nice, will read in detail now ... and maybe finally cope these deployables (not that i tried it)!
edit: commandmaps: * i needed this at the start of my material, it would not work otherwise Code:
#include <materials/commandmaps.include> * you can resize the playzone_commandmap entity as you want! (if you changed it, only a full compile will make the change, entity only does not work). Also i had to caulk it otherwise it would be visible. Very interesting map, more about it pleeeease Last edited by hozz : 03-20-2008 at 11:41 PM. |
03-21-2008, 12:24 AM | #6 | |
Lieutenant Commander
Join Date: May 2007
|
Quote:
about the caulk, you can just texture it with trigger. but guess theres no differnce
__________________
sunday night custom map nirvana, get involved!! |
|
03-21-2008, 12:35 AM | #7 |
Group Commander
Join Date: Sep 2007
Location: Germany
|
Ok it had the default orange texture for me which would not become invisible
You could also provide links to the modwiki for the parts of your tutorial to give additional information (mainly the respective articles of the "advanced map tutorial" e.g. this for the commandmap part: http://wiki.splashdamage.com/index.p..._a_command_map and http://wiki.splashdamage.com/index.p...one_commandmap [some things are wrong in modwiki point them out!]) Last edited by hozz : 03-21-2008 at 12:43 AM. |
03-21-2008, 12:39 AM | #8 |
Commander
|
Nice tutorials Gamma. The deployzone stuff makes my head spin btw you can reload materials without restarting the sdk with the command
reloaddecls |
03-21-2008, 12:41 AM | #9 |
Lieutenant Commander
Join Date: May 2007
|
thank you, edited in. who ever thought the person who wrote the tutorial could learn from it
__________________
sunday night custom map nirvana, get involved!! |
03-21-2008, 02:31 AM | #10 |
First Sergeant
Join Date: Nov 2007
|
First of all, I appreciate the tutorials. Second of all, this is ridiculously complicated. I'm constantly amazed by how obfuscated this whole mapping process is.
I'm trying to get a commandmap working. To begin with, the mapshot came out at a size and alignment entirely differing from my playzone_commandmap entity, and when viewed in game it's miscolored. The actual image is colored correctly, but the ingame version is screenshotted below. The icon waypoints obviously don't match up, either. I've read through the other mapshot related threads, and those who had this problem haven't followed up with solutions, so I'm wondering if it's ever been solved. Any thoughts? Edit: Looking more closely at the image, it seems like the icons are aligned correctly with the playzone_commandmap entity, so that's good, at least -- it's just the image that's inexplicably off and miscolored. Last edited by World : 03-21-2008 at 02:37 AM. |
03-21-2008, 02:42 AM | #11 |
Lieutenant Major
Join Date: Oct 2007
Location: Norway
|
Yes - open the commandmap in photoshop and remove the alphachannel. Bugged me for a long time, don't understand why I get them but always have to remove them after a mapshot.
But not sure about the icons, maybe the size of the commandmap trigger? btw great tutorial Gamma |
03-21-2008, 02:48 AM | #12 |
Group Commander
Join Date: Sep 2007
Location: Germany
|
World, your commandmap is invisible/transparent where it seems black (so you see the background whatever it is - press "n" during play to see it.
This is due to some layers of the .tga not showing, i had this too (anything besides terrain would be translucent) - to fix it, open the commandmap in a image editing program and re-save it (worked for me with GIMP) - then the colors are right (all information in one layer). About the wrong alignment, could be it is as you have no terrain model. Worst case you have to make a simple terrain only for the mapshot If that morally helps you: i made a mapshot of your map the day it came out (just for curiosity) and it had the same mis-alignment (also you need to FULL compile before a change of the playzone_commandmap will be noticed) |
03-21-2008, 02:52 AM | #13 |
First Sergeant
Join Date: Nov 2007
|
Alright, thanks hozz and Scrupus. I should have figured it was something like that, but I couldn't reason why the game would save the tga with unnecessary channels. :P
Very interesting possibility about the terrain model, hozz, I'll work down that path and see if it resolves things. Thanks! |
03-22-2008, 06:34 PM | #14 | ||
First Sergeant
Join Date: Nov 2007
|
Some new troubles. The map I'm working on has no terrain, perhaps that's why these tools aren't working? All I'm trying to do is enable airstrikes, and I assume it's mask related.
Quote:
Quote:
So to sum up: Is my lack of terrain causing these maskgen problems? Are masks the way to go about enabling airstrikes? That's actually the only thing I need to accomplish at this point. Edit: To update, the "No collision model" error stemmed from my map directory location. Once I copied the files to the path used in this tutorial, the collision model could be loaded. Of course, that just led to about 50 other problems. What I really want to know: are masks the key to getting working airstrikes? I just don't want to burn out troubleshooting this ridiculousness for days only to find that it doesn't do the only thing I need it to do. Last edited by World : 03-22-2008 at 07:18 PM. |
||
03-22-2008, 09:15 PM | #15 | |||
Lieutenant Commander
Join Date: May 2007
|
Quote:
Quote:
quote from the wiki Quote:
edit:spotted a mistake in the tutorial. for the .def location it should be <savepath>\base\def\maps\<yourmap>.def instead of what i had <savepath>\base\def\<yourmap>\<yourmap>.def sorry for the mistake
__________________
sunday night custom map nirvana, get involved!! Last edited by gamma : 03-22-2008 at 09:44 PM. |
|||
03-22-2008, 09:38 PM | #16 |
Artist
Join Date: May 2007
Location: London, UK
|
By the way, when doing Mapshot, make sure you are NOT running in a widescreen aspect ratio and high resolution; in fact running at 640x480 in 4:3 aspect produces the most reliable results.
World, I suspect this may be what caused your commandmap misalignment - do you run in widescreen mode, at a fairly high resolution? Basically, before running mapshot, set your video mode to 640x480 (r_mode 3 in the console) and set the aspect ratio to 4:3 (r_aspectratio 0 in the console)... then do a vid_restart command to accept those, or use the graphics settings menu to set them up. Then do your mapshot and it should come out ok. |
03-22-2008, 10:01 PM | #17 | |
First Sergeant
Join Date: Nov 2007
|
Quote:
And now that you mention it, MoP, I can't believe I didn't try that until now. You'd think that after changing to 640x480 at 4:3 for every envmap and levelshot it would have occured to me to do the same for a mapshot! The result is the same, though, oddly. There are no brushes that the mapshot image edges are touching; they seem perfectly arbitrary. I was able to crop the image down well enough to fit closely enough ingame, but the culprit of the malfunction remains at large. |
|
03-22-2008, 10:04 PM | #18 | |
Lieutenant Commander
Join Date: May 2007
|
Quote:
__________________
sunday night custom map nirvana, get involved!! |
|
03-22-2008, 11:00 PM | #19 |
Group Commander
Join Date: Sep 2007
Location: Germany
|
Everything MoP said is in the modwiki mapshot article
|
04-06-2008, 10:41 PM | #20 |
Group Commander
Join Date: Sep 2007
Location: Germany
|
Trying to finally have deployables...
I just did the 3rd Tutorial (heightmap and deploymasks), and in step 3 it outputs a purely white heightmap. Then the pathfinder gives me errors, probably due to this. Meh ... My playzone_xxx entities have trigger texture.... maybe that is the problem? My caulk hull is noimpactcaulk, and i moved any entities hovering over the terrain (playzone_path_and_hm, playzone_commandmap) under the terrain, which changed that the formerly pure black heightmap is now pure white. Any ideas? |
04-06-2008, 11:10 PM | #21 |
Lieutenant Commander
Join Date: May 2007
|
what i did was put the playzone_path_and_heightmap around the whole terrain, then put all the others above it like in the etqwmap. all my playzones are all textured with trigger so that couldnt be the cause.
my guess is that it is in the wrong place or not covering everything. my first go at it didnt turn out a heightmap and resizing and changing the location a few times did the trick. im still not sure why it dosnt work sometimes.
__________________
sunday night custom map nirvana, get involved!! |
04-06-2008, 11:14 PM | #22 |
Group Commander
Join Date: Sep 2007
Location: Germany
|
Hmm that makes sense! Only the area covered by pz_path_and_hm is considered in the heightmap.....
Thanks, will try it now. |
04-06-2008, 11:22 PM | #23 |
Lieutenant Major
Join Date: Oct 2007
Location: Norway
|
Just as a sidenote, I stuggled a lot with the deployables stuff until I centered the terrainmodel and everything around origin 0,0 - after that it worked smoothly. Still get a white default.tga (that's another story...) but at least the deployables started to work properly.
|
04-06-2008, 11:52 PM | #24 |
Group Commander
Join Date: Sep 2007
Location: Germany
|
Thank god .. ahem thank blender my terrain is centered
White default tga is fine, you have to hard-work-and-hairloss-paint it anyway... |
04-07-2008, 02:06 AM | #25 | |
Group Commander
Join Date: Sep 2007
Location: Germany
|
I made my pz_path_and_heightmap around my terrain, and that solved the problem with the white heightmap.
Now i have a heightmap which looks very white, but is a heightmap Questions: *Does the z-dimension of the deployzone entities (territory brushes) matter? If yes, how are you supposed to build them? (right now they're hovering in the sky, i've seen they stand on the surface in etqwmap) * the trigger_multiple has no special K/V (only the name) is that really correct? Problem: Quote:
I did use a white .tga (the white.tga from the SD megatexture source images) and used it in 512x512 (original) and 128x128(resized). Then i just deleted it. Then i tried the playzone.tga from the etqwmap folder. All 4 times this error. Update: i deleted the playzone_play and the playzone in the .def ..... now the map loads. Medkits/Stroyent cells do not work (these need the playzone i guess ???). Supply crate drop (not use), Violator/Airstrike work. Deployables do not work, but i'm just recompiling with my territory brushes not hovering over the terrain, but intersecting it like the deployzone thing... Update2: Ok, deployables did work all the time, i just don't see the wireframe before i deployed, and the wireframe after i deployed is not exactly on the terrain (a little higher). Once they arrived, they fall to ground and work. So: how to fix wireframes, and how to make a working playzone_play (it seems to be independent of the rest)? Update 3: I noticed the pathfinder (part 4 of gamma's tut) created a reservoir_playzone_56467465.tga in my imagedump/pathfinder folder... what is this good for? Also the little deploy squares do not show (my deploymask[default.tga] is pure white). Last edited by hozz : 04-07-2008 at 05:31 AM. |
|
«
Previous Thread
|
Next Thread
»
Thread Tools | |
|
|
All times are GMT. The time now is 11:54 AM.