Jump to content
The Dark Mod Forums

Newbie DarkRadiant Questions


demagogue

Recommended Posts

Actually, you might not need S/R (or to set the frob_action_script); loot triggers its targets when collected.

 

Also, I'd like to have an animal that continuously "talks", but not anymore after it dies. s_looping doesn't seem to work, as it keeps going when it dies. Is there a way to change the sound shader of "talks"?

Is this referring to the "talks" spawnarg? How are you getting the sound to play?

Edited by VanishedOne

Some things I'm repeatedly thinking about...

 

- louder scream when you're dying

Link to comment
Share on other sites

I thought about the stim-response system... but I don't understand the wiki page at all. :( (It seems to me it's not complete and at least lacks a section about how to set up responses.) For example,

 

For a complete list you should take a look at tdm_stim_response.script in the script folder.

Where do I find the script folder? Found it nowhere inside the darkmod folder.

 

The Stim/Response Editor will pop up and allow you to define stims and responses for your entity.

Which entity? The one carrying the stim (like in the above example, the loot) or the response (the animal)?

 

So my plan is: make the AI (here it's a human, but should be the same thing I guess) take a path as soon as I grab the loot.

As in the pictures, I go forth selecting the loot (for the stim), open the stim-response menu... and then I'm lost. Probably "Type" is "frob", but who would know? And what with all the stuff on the right side?

I'm sorry to be a pain in the ass, but could someone give me a walkthrough how to make this example work? I'm quite desperate-

post-21200-0-09239900-1445536053.jpg

post-21200-0-78441600-1445536061.jpg

Link to comment
Share on other sites

Is this referring to the "talks" spawnarg? How are you getting the sound to play?

Yes, I mean the "talks" spawnarg. Actually in my mission I'm talking about a rat. It should make squeaky sounds all the time, but it stays silent. So I set "talks" to 1. Yet it doesn't do it right. I also tried "s_shader". It would be great to know how to

 

* choose the sound shader for "talks"

* let the rat be quiet in case the player chooses to kill it. (So I guess a speaker wouldn't be a good option here.)

 

I couldn't manage to do that.

Edited by Nico A.
Link to comment
Share on other sites

@Nico A. The script folder is archived inside tdm_base01.pk4, but the comments in this script file won't tell you much and I have a copy in the middle column here anyway.

DR's Stim/Response editor applies to the entity you currently have selected.

The loot gets a STIM_FROB response: in the S/R editor switch to the Responses tab. In the bottom-left dropdown, select Frob to create a response to STIM_FROB in the box above. In the bottom-right box marked Response Effects, right-click and select 'Add new Effect'. A line of text appears: double click on that to change it to what you need, probably something to Trigger a target entity. But as I said above, you don't actually need S/R for this.

I think "talks" might be a Doom 3 leftover, and since the description in the editor is 'Whether character can be engaged in conversation' I wouldn't bet on it doing what you want. However, I'm not sure what the best way would be. Rats have the spawnarg "snd_relaxed" "animal_rat_chatter", which might be worth investigating. (Edit: the shader is in tdm_ai_animals01.pk4.)

Edited by VanishedOne
  • Like 1

Some things I'm repeatedly thinking about...

 

- louder scream when you're dying

Link to comment
Share on other sites

Hmm. It's not really a door, but a display case, which is a atdm:mover_door_sliding.

 

Yep, double tested. The guy gets alerted, searches a bit, but does not close the case. Perhaps a bug in the atdm:mover_door_sliding entity?

Clipper

-The mapper's best friend.

Link to comment
Share on other sites

@Nico A. The script folder is archived inside tdm_base01.pk4, but the comments in this script file won't tell you much and I have a copy in the middle column here anyway.

 

DR's Stim/Response editor applies to the entity you currently have selected.

 

The loot gets a STIM_FROB response: in the S/R editor switch to the Responses tab. In the bottom-left dropdown, select Frob to create a response to STIM_FROB in the box above. In the bottom-right box marked Response Effects, right-click and select 'Add new Effect'. A line of text appears: double click on that to change it to what you need, probably something to Trigger a target entity. But as I said above, you don't actually need S/R for this.

I find this text far more informative than the wiki one about S/R. :)

And it works!! Thanks a lot!

 

Now (a small) problem is that I want the rat to stay put as soon as it reaches its target. I guess I need to "set spawnarg" of the rat, namely "patrol" to "0", when the target is reached.

I tried selecting the path corner, create a "Target Reached" response, which sets the spawnarg of the rat "patrol" to "0". But the rat still moves when it reaches the target... is there another way?

 

Also I can't get the squeaking right. I think it would be easiest to set up a speaker near the rat, which gets deactivated once the rat dies or starts to patrol. Can I control this somehow? The "set spawnarg" response for the speaker, "volume" to "-60", doesn't seem to work.

 

edit: Even the Response Effect "Remove" doesn't work. But then it says in the box "Remove entity ... from the game" and a speaker is not an entity I guess... but how can I deactivate it then?

edit2: Now I put the sound shader directly on the rat (spawnarg s_shader) with looping (spawnarg s_looping) and tried to use the Response Effect "Set Spawnarg" for the s_shader to "silence" and s_looping to "0", but then upon killing, the rat loops its dying sound...

Edited by Nico A.
Link to comment
Share on other sites

I have tried this, but my sign still appears completely blank in-game. Any suggestions?

Does this help?

 

Now (a small) problem is that I want the rat to stay put as soon as it reaches its target. I guess I need to "set spawnarg" of the rat, namely "patrol" to "0", when the target is reached.

I tried selecting the path corner, create a "Target Reached" response, which sets the spawnarg of the rat "patrol" to "0". But the rat still moves when it reaches the target... is there another way?

If you haven't already, try turning off Animal Patrol Mode under the rat's AI tab in DR (it makes AI wander around randomly). If that doesn't help, maybe the rat could finish on a path_wait node with the wait time set to a huge number of seconds...?

 

I think there's a way to set up looping inside a sound shader itself, e.g. in this ambient:

 

deep_dark_twinkles
{
	editor_displayFolder	ambient/ambience

    looping
    leadin sound/ambient/ambience/texture3_start.ogg

    sound/ambient/ambience/texture3_loop.ogg
}

Some things I'm repeatedly thinking about...

 

- louder scream when you're dying

Link to comment
Share on other sites

In the bottom-left dropdown, select Frob to create a response to STIM_FROB in the box above.

Hm... of all the response types only "Frob" seems to work. When I kill an AI and select "Death" as response type and then a response effect something should happen right? Or am I doing it wrong?

Link to comment
Share on other sites

Hm... of all the response types only "Frob" seems to work. When I kill an AI and select "Death" as response type and then a response effect something should happen right? Or am I doing it wrong?

Don't assume killing an AI by non-S/R means is equivalent to sending a STIM_KILL to an entity that responds to it. TDM's S/R was bolted on top of Doom 3's way of doing things to provide DromEd-like functionality to Thief mappers; it isn't necessarily integrated deeply into systems that existed in the engine already. (And yes, it has incomplete documentation and some questionable design decisions. Having once spent ages wondering why my Holy stim wasn't affecting undead - answer: they use a special script which expects the stimming entity to carry a "def_damage" spawnarg - I can sympathise.)

Edited by VanishedOne

Some things I'm repeatedly thinking about...

 

- louder scream when you're dying

Link to comment
Share on other sites

If I create an AI (or a ragdoll entity), can I freely change its model to different AI types? For example, can I create the ragdoll of a Builder guard, and turn it into a lesser Builder?

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

Generally that should work, given the fix to http://bugs.thedarkmod.com/view.php?id=3912

 

In certain cases it can produce errors: my first attempt at this involved a mage with a priest's model, and the game did not like it, so I ended up changing the priest's modelDef instead.

  • Like 1

Some things I'm repeatedly thinking about...

 

- louder scream when you're dying

Link to comment
Share on other sites

Don't assume killing an AI by non-S/R means is equivalent to sending a STIM_KILL to an entity that responds to it.

If I understand it correctly, I should first create a Stim when my AI is killed? How does that work? :unsure:

Link to comment
Share on other sites

He means killing an AI may either have nothing or unknown things to do with something propagating a STIM_KILL that the AI is set to receive. So if testing doesn't get it to work, it may be because it wants something you can't even predict, or it just doesn't work, because the system itself is patchy and inconsistent, and not documented even if something does work.

 

A bit in Sparhawk's defense, the designer, he was up front about the problems in designing it to work and his not knowing dromed, and people wanted it anyway. So we got what we got. And documentation has been a challenge for most things because of being understaffed and overworked.

 

I'd be happy to see the system retooled and documented, but a lot of things you can do by script anyway.

  • Like 1

What do you see when you turn out the light? I can't tell you but I know that it's mine.

Link to comment
Share on other sites

And documentation has been a challenge for most things because of being understaffed and overworked.

I'd be totally interested in making some quality and easy to understand tutorials of DarkRadiant (and yes, I'm quite aware of the amount of work of this), but first I myself need a glimpse at how it works. :D

 

But is there a general method/algorithm for mapmakers to achieve something like "when event A happens, the world changes in way B"?

* when I frob this, that door closes?

* when I hurt myself, that guard starts to laugh?

* when water touches that wall, a crystal appears there?

* when I finished reading that scroll, the player changes position?

* when I reach this place, a horse will appear next to me?

* when I kill this rat, that speaker will be silent?

* ... ?

Is there a general framework that achieves things like this? And how does it work?

Edited by Nico A.
Link to comment
Share on other sites

Is there a general framework that achieves things like this? And how does it work?

 

These are achievable with combination of stim & response system and scripting. If you learn scripting, you can do pretty much anything.

http://wiki.thedarkmod.com/index.php?title=A_Beginner%27s_Guide_to_Scripting

 

It is incomplete, but will get you started. Examining scripts made by other mappers might help, too.

Clipper

-The mapper's best friend.

Link to comment
Share on other sites

How do I keep my blood decals from disappearing? (Or maybe they don't even render?) Something is not okay...

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

Since I wasn't around when TDM's S/R system was implemented, most of what I know about its origins and purposes I got from reading old threads like http://www.ttlg.com/forums/showthread.php?t=112713I'm not a DromEder either, so I'm twice removed from the original S/R.

 

The chart I linked to previously has my nascent notes on trying to understand the built-in stim types, with an eventual view to properly documenting them. S/R is mainly useful where you want to make something happen when x collides with y, or when x is less than a certain distance from y, or when x is a body of water and y is immersed in it, etc.

 

@Melan textures/darkmod/decals/blood/* or textures/decals/splat* ?

Some things I'm repeatedly thinking about...

 

- louder scream when you're dying

Link to comment
Share on other sites

@VanishedOne: The former. They come in two varieties, regular and _fading. I used the former, but it still doesn't work right.

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

The offending line is probably

decalInfo 0.5 0 ( 5 5 5 1 ) ( 0 0 0 0 )

From iddevnet:

 

 

decalInfo <staySeconds> <fadeSeconds> [start rgb] [end rgb]

 

Used in decal materials to set how long the decal stays, and how it fades out.

 

I should think you need splat* instead (if needed they can be coloured via shaderparms), as the description lines in the /blood/* decals suggest. (Edit: I should add that you might end up needing to set unexpected colours because of the unusual blend mode; I made a purplish wine stain with a splat decal, and I had to colour it green in the editor.)

Edited by VanishedOne

Some things I'm repeatedly thinking about...

 

- louder scream when you're dying

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

    • JackFarmer

      @joebarnin
      Jeff, I sent you PM a few weeks back but you did not respond. Maybe your inbox is full?
      · 3 replies
    • The Black Arrow

      I was playing Skyrim, got bored fast. Got back to The Dark Mod just for one mission, played "Somewhere above the City" which is not really a great mission but still good, as in above-average.
      My biggest regret is living in this country, where there's a heat wave, I am sweating at 20c and I really wish for temperatures below 5c.
      · 10 replies
    • Skaruts

      Is there something wrong with the forums lately, or is it my browser? I've been having trouble formatting posts, and just now I couldn't format anything at all.
      I'm using Vivaldi.
      Usually I have to: select text, click bold, nothing happens, select again, click bold, then it works. 
      Same for other stuff, like creating spoilers, bullet points, links. Nothing works the first time. 
      · 1 reply
    • STiFU

      Back from a spontaneous 1-week trip to Lanzarote with wife and son. I hope beta testing has been going well...
      · 1 reply
    • datiswous

      Whenever I eat fried chicken these days I think of this scene in The Black Mage..

      · 1 reply
×
×
  • Create New...