Jump to content
The Dark Mod Forums

Newbie DarkRadiant Questions


demagogue

Recommended Posts

I'm having a helluva time with readables. What do you guys use for reading/writing .xd files? I have Notepad++ currently, which seems to read them fine, but won't save as that file type. I could manually change the file type, but worry about compatibility issues at that point. Every tutorial I've read (and there are several) just starts with "create your .xd file" which doesn't really address my question.

 

The whole readable creation process is somewhat confusing, but I hope that the tutorials start making sense soon.

 

I use notepad++ for all my tdm text files without any problems, including readables, just typing in the .xd extension manually the first time. I think there are tools or prefabs in DR to help, at least with some readables. Someone else will no doubt know...

Link to comment
Share on other sites

I use notepad++ for all my tdm text files without any problems, including readables, just typing in the .xd extension manually the first time. I think there are tools or prefabs in DR to help, at least with some readables. Someone else will no doubt know...

 

Ah, a simple fix for the file type problem. Thanks.

 

Why aren't you using the readable editor in Dark Radiant?

 

There's a readable editor in DR?

 

....

 

I'm still worried I don't have all my folders in the right place. Some of the tuts assume, for example, that I have a darkmod/xdata folder, which I don't. I'm not sure whether to create it, use the one inside the prefabs folder, or make my own in my map's folder, and how any of those will affect the "pointing to" functions that are required to read the .xd file itself. I'm sure this will be easy eventually, but it's like wading through molasses currently, much more so than basic architecture has been.

Edited by Digi

"Fancy burricks are afraid of dogs, if they encounter each other the dog barks and the burricks poop." - Thief: Deadly Shadows Game Designer

Link to comment
Share on other sites

I'm still worried I don't have all my folders in the right place. Some of the tuts assume, for example, that I have a darkmod/xdata folder, which I don't. I'm not sure whether to create it, use the one inside the prefabs folder, or make my own in my map's folder, and how any of those will affect the "pointing to" functions that are required to read the .xd file itself. I'm sure this will be easy eventually, but it's like wading through molasses currently, much more so than basic architecture has been.

 

I remember having the same confusion. It's not well documented, maybe because it's intuitive once you get your head round it.

 

Go ahead and create any folders you need, like script, xdata, textures etc. They won't be there by default. Create them alongside your /maps folder. So if your map file is in the main darkmod maps folder, e.g. /darkmod/maps/mymap.map, then create /darkmod/xdata/. If you are working in an FM-specific folder eg. /darkmod/fms/mymap/maps/mymap.map, then you'd create /darkmod/fms/mymap/xdata.

 

When you start out, you'll typically be working in the main darkmod folder. If you start to add assets to your map like xdata files or new textures, then you can think about switching to the second option, a folder for your FM in the darkmod/fms folder. That lets you keep all of the files for your FM together, and it's how you eventually have to package it for release.

 

Either way, the two structures mirror one another, with the same list of top-level folders (once you've added them): def, fms, maps, materials, models, particles, script, xdata, and many others. You only add the ones you need when you want to add content to your map that isn't part of the core game.

  • Like 1
Link to comment
Share on other sites

Yes there is.

 

post-529-0-14773700-1401571355_thumb.jpg

 

post-529-0-73186100-1401571354_thumb.jpg

 

Lol, good to know. Maybe it'll be more intuitive than what I'm doing now. I did manage to get my first working line in a readable in-game, so that was exciting. But the tutorials for readables haven't been a straightforward as many of the others, so it's good to have options.

 

In any case, thanks.

 

 

I remember having the same confusion. It's not well documented, maybe because it's intuitive once you get your head round it.

 

Go ahead and create any folders you need, like script, xdata, textures etc. They won't be there by default. Create them alongside your /maps folder. So if your map file is in the main darkmod maps folder, e.g. /darkmod/maps/mymap.map, then create /darkmod/xdata/. If you are working in an FM-specific folder eg. /darkmod/fms/mymap/maps/mymap.map, then you'd create /darkmod/fms/mymap/xdata.

 

When you start out, you'll typically be working in the main darkmod folder. If you start to add assets to your map like xdata files or new textures, then you can think about switching to the second option, a folder for your FM in the darkmod/fms folder. That lets you keep all of the files for your FM together, and it's how you eventually have to package it for release.

 

Either way, the two structures mirror one another, with the same list of top-level folders (once you've added them): def, fms, maps, materials, models, particles, script, xdata, and many others. You only add the ones you need when you want to add content to your map that isn't part of the core game.

 

Makes sense, thanks. Like you said, it's more about the documentation than the understanding. I can grasp the concept, but when it isn't spelled out or immediately obvious, I've had a couple instances like this where there's a lot of trial & error with folder and file placement before I get it right.

"Fancy burricks are afraid of dogs, if they encounter each other the dog barks and the burricks poop." - Thief: Deadly Shadows Game Designer

Link to comment
Share on other sites

Whoops edit, missed the answers/needed a reload or something before replying, but perhaps there's some useful knowledge that's not redundant below anyway:

 

Yes, readables are excessively confusing.

 

The .xd file is just a plain old text file, I use the editor in Dark Radiant on a prefab, then copy/paste via notepad or wordpad into my created mission whatever.xd file.

 

In other words, if you insert a prefab, it will save to the prefabs.xd in your darkmod xdata folder (something you don't want to include/package with your mission). If you open that, search for the name of your readable, you can cut that section out and paste it into a separate something.xd which will be packaged with your mission. Although you may have multiple, generally most missions tend to put all their readables into one .xd file in the xdata folder.

 

The counter-intuitive part is unlike any other software, the .xd name doesn't matter and is handled mostly transparently. In other words, all the .xd files in the folder are read, and the text associated with the proper entities, regardless of filenames. Both DR and TDM have menus/a command, respectively, to reload xdata if it's been changed since they were loaded (although if in doubt, rerun them).

 

A word of warning with the editor in Dark Radiant, some systems don't show the last line properly, so format your text accordingly to leave plenty of blank space at the bottom of every page.

Edited by RJFerret

"The measure of a man's character is what he would do if he knew he never would be found out."

- Baron Thomas Babington Macauley

Link to comment
Share on other sites

I usually write my readables first into plain txt file.

 

Then when it is ready and checked and in final form, I copy paste it into the readable editor.

 

Then i copy paste the text so that the pages are filled. I always change the pages so that the two lowmost lines are empty.

Clipper

-The mapper's best friend.

Link to comment
Share on other sites

I had already created a stiff cylinder with the rope texture but when I try bending it to be a bit more like a rope it starts turning to garbage. The only free falling rope (which if I position correctly doesn't look too bad) is the default rope in TDM and it's far too thin.

 

I don't need to be able to climb this either as its purely a visual thing

 

Is there a way to select a start point and a finish point and let gravity pull the rope into the right place?

 

Take a look at Obsttorte's Lets map videos, Goldwell. See if those help with patch manipulation.

 

- @~39:00 Stair railing

 

- @~1:09:20 rope cross binders
  • Like 1
Link to comment
Share on other sites

So I want to make my diving helmet work as inexhaustible breathing potion. I could just make a potion with different model, but want to add some hud overlays etc. Breathing potion looks like health potion for secondary health bar, just with "def_heal" "breath_potion" arg ( I don't see any specific breath potion in tdm_player_tools.script). In "Script Events User-Friendly List" there is

"float X = $<AIname/player1>.getHealth();" (returns AI/player health)

"$<AI/player1>.setHealth(<health>);" (set AI/player health)

but it generates an error at TDM start. So what command will restore breath bar?

S2wtMNl.gif

Link to comment
Share on other sites

Try the "heal" script event, which can be used on any entity.

scriptEvent float heal(string healDefName, float healScale);

giving it "breath_potion" as its first parameter.

 

I've not tried it but this script event looks set up to do the same thing as the potions that can heal by using a healDef (def_heal). They are in tdm_healing.def. breath_potion is in there too and looks like the "normal" heals but gives 600 "air"

  • Like 1
Link to comment
Share on other sites

I love the range of questions that appear here in the "Newbie" thread...

 

Me: "I have a leak, HALP!"

 

Others: "I want to make my diving helmet an inexhaustible breathing potion."

 

We need an Intermediate/Advanced Questions Thread...it would do wonders for my self esteem. :-p

Edited by Digi
  • Like 2

"Fancy burricks are afraid of dogs, if they encounter each other the dog barks and the burricks poop." - Thief: Deadly Shadows Game Designer

Link to comment
Share on other sites

Try the "heal" script event, which can be used on any entity.

scriptEvent float heal(string healDefName, float healScale);

giving it "breath_potion" as its first parameter.

 

I've not tried it but this script event looks set up to do the same thing as the potions that can heal by using a healDef (def_heal). They are in tdm_healing.def. breath_potion is in there too and looks like the "normal" heals but gives 600 "air"

I get errors with that line, how exactly should it look?

S2wtMNl.gif

Link to comment
Share on other sites

I figured out readables; thanks everyone. And yes, it's intuitive and fairly easy once I wrapped my head around them. So I've got a letter to a distant lover, two notes, and two poems written for my first FM (yes, poems!). The whole thing is still only maybe 40% complete, but I can see an end in sight.

 

Haha, I wouldn't worry Digi, this is really more of a "I have a question" thread at this point anyways :-).

 

Yeah, it just makes me laugh.

Edited by Digi
  • Like 1

"Fancy burricks are afraid of dogs, if they encounter each other the dog barks and the burricks poop." - Thief: Deadly Shadows Game Designer

Link to comment
Share on other sites

It also keeps us humble here, as it seems no matter how much editing we do, we always feel like newbies when we bump our heads into something we haven't dealt with (or don't remember how we implemented in the past).

  • Like 1

"The measure of a man's character is what he would do if he knew he never would be found out."

- Baron Thomas Babington Macauley

Link to comment
Share on other sites

I get errors with that line, how exactly should it look?

Without testing, I think should look like:

$player1.heal("breath_potion", 1);

 

If that doesn't work, I'll find out why after work. I've just been working on the script event documentation so I've been testing lots of them this weekend.

  • Like 1
Link to comment
Share on other sites

This might be a typical dumb mistake, but bear with me. My briefing GUI (including loading_screen.tga) does not display correctly. All I get is the general loading background, which gets used when no mission is installed, and you run maps from the console. What could be causing this?

Come the time of peril, did the ground gape, and did the dead rest unquiet 'gainst us. Our bands of iron and hammers of stone prevailed not, and some did doubt the Builder's plan. But the seals held strong, and the few did triumph, and the doubters were lain into the foundations of the new sanctum. -- Collected letters of the Smith-in-Exile, Civitas Approved

Link to comment
Share on other sites

Maybe a syntax error in the gui. Check for warnings/errors in the console.

FM's: Builder Roads, Old Habits, Old Habits Rebuild

Mapping and Scripting: Apples and Peaches

Sculptris Models and Tutorials: Obsttortes Models

My wiki articles: Obstipedia

Texture Blending in DR: DR ASE Blend Exporter

Link to comment
Share on other sites

I've got a standard GUI I have been using since Return to the City... but for some reason, no luck. Anyway, maybe one of the beta testers will tell me how to fix it. ;)

Come the time of peril, did the ground gape, and did the dead rest unquiet 'gainst us. Our bands of iron and hammers of stone prevailed not, and some did doubt the Builder's plan. But the seals held strong, and the few did triumph, and the doubters were lain into the foundations of the new sanctum. -- Collected letters of the Smith-in-Exile, Civitas Approved

Link to comment
Share on other sites

PM me once you've opened the beta and I will take a look at it.

FM's: Builder Roads, Old Habits, Old Habits Rebuild

Mapping and Scripting: Apples and Peaches

Sculptris Models and Tutorials: Obsttortes Models

My wiki articles: Obstipedia

Texture Blending in DR: DR ASE Blend Exporter

Link to comment
Share on other sites

I have this piece of code for helmet overlay,

 

1=$player1.createOverlay( "guis/helmet.gui", 100 );

sys.wait(5);

$player1.destroyOverlay(1);

 

but it just cause "IdActor::SetAnimState: unknown anim group". What is wrong?

 

Also I want a overlay transition to be made by zooming out from translucent centre of visor (so I can see a visor edge and helmet interior), then it should zoom in again. What GUI parameter will do this trick?

S2wtMNl.gif

Link to comment
Share on other sites

Is there a way to make it so you can't see the bottom of a water pit thats about 140 doom units deep?

 

So far I have tried pretty much every water source but most are very transparent. I have tried placing all different types of fog lights under the water but to no avail and finally I have tried taking some already existing material files for water and removing/lowering the alpha level but it doesn't work and only causes the water to look very strange in game.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


  • Recent Status Updates

    • nbohr1more

      Was checking out old translation packs and decided to fire up TDM 1.07. Rightful Property with sub-20 FPS areas yay! ( same areas run at 180FPS with cranked eye candy on 2.12 )
      · 2 replies
    • taffernicus

      i am so euphoric to see new FMs keep coming out and I am keen to try it out in my leisure time, then suddenly my PC is spouting a couple of S.M.A.R.T errors...
      tbf i cannot afford myself to miss my network emulator image file&progress, important ebooks, hyper-v checkpoint & hyper-v export and the precious thief & TDM gamesaves. Don't fall yourself into & lay your hands on crappy SSD
       
      · 5 replies
    • OrbWeaver

      Does anyone actually use the Normalise button in the Surface inspector? Even after looking at the code I'm not quite sure what it's for.
      · 7 replies
    • Ansome

      Turns out my 15th anniversary mission idea has already been done once or twice before! I've been beaten to the punch once again, but I suppose that's to be expected when there's over 170 FMs out there, eh? I'm not complaining though, I love learning new tricks and taking inspiration from past FMs. Best of luck on your own fan missions!
      · 4 replies
    • The Black Arrow

      I wanna play Doom 3, but fhDoom has much better features than dhewm3, yet fhDoom is old, outdated and probably not supported. Damn!
      Makes me think that TDM engine for Doom 3 itself would actually be perfect.
      · 6 replies
×
×
  • Create New...