Jump to content
The Dark Mod Forums

Newbie DarkRadiant Questions


demagogue

Recommended Posts

4 hours ago, VanishedOne said:

This is a long shot if there are no other signs of light-bleed or internal leaks, but are there any non-opaque brush surfaces (like caulk or nodraw) in the problematic wall, including surfaces you can't see because they're flush with an adjacent brush?

(Caulk is opaque in a certain sense, but internal caulking has given me light-related headaches before. I sometimes use shadowcaulk for that reason.)

Good idea, but I just checked for this situation, and no luck. It was worth a shot.

Link to comment
Share on other sites

Thanks everyone for your ideas. I decided to avoid the problem, so I adjusted the lights at the front of the building so that they no longer cast onto the front wall. Works like a charm, shadowcast counts inside are down to reasonable numbers. “Problem avoided” rather than “problem solved”, but it was time to move on. I’ve save a copy of the map from before these changes, so I can always go back and try “one more” fix, if something comes to mind. Thanks again. 

Link to comment
Share on other sites

One more thing that might be useful: due to lowered precision of BSP processing, I sometimes get leaks from brush walls or floors that are only touching by the edges (as when you use Make Room function with a cube). The leaks will go away when walls or floors actually touch each other, e.g. floors and ceilings extend by wall thickness, etc.

  • Thanks 1
Link to comment
Share on other sites

Has anyone used the path_hide entity? I'm trying to get an AI to be invisible and non-solid but still continue its patrol. The path_hide node doesn't seem to do what it says in the editor though. Am I missing something? If it doesn't work, what alternatives do I have? I guess I don't mind writing a custom skin that is transparent, I just need to figure out how.

My Fan Missions:

   Series:                                                                           Standalone:

Chronicles of Skulduggery 0: To Catch a Thief                     The Night of Reluctant Benefaction

Chronicles of Skulduggery 1: Pearls and Swine                    Langhorne Lodge

Chronicles of Skulduggery 2: A Precarious Position              

Chronicles of Skulduggery 3: Sacricide

 

 

 

Link to comment
Share on other sites

If you make it invisible and non-solid, you'll also probably need to make it mute or you can still hear it. I found it easier to just teleport the AI to a distant place, and teleport it back in if I needed to, if that could work for you. If you do that, just be sure that the place you teleport the AI to is someplace either part of the main mission space or maybe that the AI could technically walk to from where it started so the pathfinding still works post-teleport. (It's something like that. I can't recall the particulars. The point is pathfinding will break if it teleports in from or out to a place entirely detached from other mission space.)

  • 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

It's listed as supported in http://wiki.thedarkmod.com/index.php?title=Currently_supported_Path_Entities but as 'untested' in http://wiki.thedarkmod.com/index.php?title=Path_Nodes#Untested_Nodes

If I remember rightly, D3's hide() for AI includes lines to turn off monster chatter, but TDM's version lacks those--I assume 'monster chatter' was removed because of TDM's more complex vocal requirements, but nobody ever added code to mute hidden AI.

Some things I'm repeatedly thinking about...

 

- louder scream when you're dying

Link to comment
Share on other sites

The vocal set can be defined in the AI's .def file. If it's a spawnarg, then it's permanently set at spawntime. If it's a dynamic argument then you can change it with a script or whatever in-game. I have an intuition that it's a spawnarg though, which complicates silencing the AI by just changing the vocal set to null or whatever parameters silence the AI in-game since that wouldn't work. You'd have to choose between the AI being noisy or silent from spawn. IIRC that's another reason I leaned towards the teleport trick.  

I mean in the end, I just hid my AI behind an unopenable door because I still had problems getting the pathfinding to register post-teleport. But if I wanted to do it properly now, I'd go with teleporting in and out route and just make sure the place I teleport from and to has pathfinding created in the dmap (i.e., it's in connected space to the start marker so the A* algorithm reaches it. I think that's what I missed when I tried it the first time). 

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

On 8/28/2019 at 10:01 AM, demagogue said:

If you make it invisible and non-solid, you'll also probably need to make it mute or you can still hear it. I found it easier to just teleport the AI to a distant place, and teleport it back in if I needed to, if that could work for you. If you do that, just be sure that the place you teleport the AI to is someplace either part of the main mission space or maybe that the AI could technically walk to from where it started so the pathfinding still works post-teleport. (It's something like that. I can't recall the particulars. The point is pathfinding will break if it teleports in from or out to a place entirely detached from other mission space.)

Thanks for the reply. I am well aware of the teleport trick, and am currently using it on other AI in the map. It is interesting that pathfinding could still work if the area is still connected. That never occurred to me and I now see why I could never get my fire elementals to move after teleporting them from the "blue room".

In this case however, I just thought I would use the AI as a handy carrier of a speaker in my map. I was hoping that the AI would be invisible and non solid (and mute, blind and deaf). I've bound a speaker that plays a sighing sound every x seconds, to suggest to the player that there is a ghostly presence around. I guess that it's pretty obvious I'm working on a Halloween mission ^^

Anyway, is this a good way of doing it? Is there a better way to have a speaker move around in a set pattern like a patrol?

My Fan Missions:

   Series:                                                                           Standalone:

Chronicles of Skulduggery 0: To Catch a Thief                     The Night of Reluctant Benefaction

Chronicles of Skulduggery 1: Pearls and Swine                    Langhorne Lodge

Chronicles of Skulduggery 2: A Precarious Position              

Chronicles of Skulduggery 3: Sacricide

 

 

 

Link to comment
Share on other sites

You can create a curve path (spline) and copy paste a simple script to make an object move along it. It can go through walls, and you can bind a speaker, light, particle or anything else to it. If you want it to pause movement now and then (like a path_wait) you can use several successive splines with a delay inbetween.

 

Regarding AI pathing, you can use an aas flood entity to instruct dmap to create pathfinding for an area if there are no AIs of that type present there at map start. Humanoids need aas32, rats need aas_rat etc

  • Thanks 1
Link to comment
Share on other sites

18 hours ago, Dragofer said:

You can create a curve path (spline) and copy paste a simple script to make an object move along it. It can go through walls, and you can bind a speaker, light, particle or anything else to it. If you want it to pause movement now and then (like a path_wait) you can use several successive splines with a delay inbetween.

 

Regarding AI pathing, you can use an aas flood entity to instruct dmap to create pathfinding for an area if there are no AIs of that type present there at map start. Humanoids need aas32, rats need aas_rat etc

 

Good tip about the AAS flood entity, I've never known what it was, but now the name makes sense!

I can't seem to find a decent entry on the wiki about splines, and I've never worked with them before. Any tips on what I need to do, and what script I would need?

My Fan Missions:

   Series:                                                                           Standalone:

Chronicles of Skulduggery 0: To Catch a Thief                     The Night of Reluctant Benefaction

Chronicles of Skulduggery 1: Pearls and Swine                    Langhorne Lodge

Chronicles of Skulduggery 2: A Precarious Position              

Chronicles of Skulduggery 3: Sacricide

 

 

 

Link to comment
Share on other sites

50 minutes ago, Bienie said:

 

Good tip about the AAS flood entity, I've never known what it was, but now the name makes sense!

I can't seem to find a decent entry on the wiki about splines, and I've never worked with them before. Any tips on what I need to do, and what script I would need?

http://wiki.thedarkmod.com/index.php?title=Cutscenes_Part_2:_Splines_and_Camera_Movement

Please visit TDM's IndieDB site and help promote the mod:

 

http://www.indiedb.com/mods/the-dark-mod

 

(Yeah, shameless promotion... but traffic is traffic folks...)

Link to comment
Share on other sites

I've used grayman's cutscenes tutorial, which includes a section on binding a camera to a spline to make it move. http://wiki.thedarkmod.com/index.php?title=Cutscenes_Part_2:_Splines_and_Camera_Movement

If you're not that familiar with setting up scripts you can go one page back in his tutorial for instructions on that. This tutorial is actually what I used to get my first foothold in scripting.

The script there, called roll5, has a few extra lines pertaining to the camera that you won't need, and acceleration/deceleration may also be inappropriate in your case.

Edited by Dragofer
Link to comment
Share on other sites

I found it to be cool but slowed down my big area too much. The player reflection was annoying when submerged past the waist, it just got on the way and looked wrong, like bad misaligned body awareness. If there’s a way to do what you hope for, I’d like to know too, and how much it affects frames, etc. Reflecting everything else in the area looks beautiful but I settled with the fake reflection of just the sky and stars for now.

  • Like 1

As my father used to say, "A grenade a day, keeps the enemy at bay!"

My one FM so far: Paying the Bills: 0 - Moving Day

Link to comment
Share on other sites

If you don't want the player to be visible in any reflections (or other third person camera views) in the mission, then you could try reskinning the player's world models with something invisible. Or $player1.hide() might work.

If you want the effect just for this water surface, and you want real-time reflections, I don't know of a way.

Edit: it turns out this is an open bug: https://bugs.thedarkmod.com/view.php?id=800

2014 discussion, with suggestion of skin-swapping per location: http://forums.thedarkmod.com/index.php?/topic/9082-newbie-darkradiant-questions/page/217/

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

On 8/30/2019 at 10:36 AM, Dragofer said:

I've used grayman's cutscenes tutorial, which includes a section on binding a camera to a spline to make it move. http://wiki.thedarkmod.com/index.php?title=Cutscenes_Part_2:_Splines_and_Camera_Movement

If you're not that familiar with setting up scripts you can go one page back in his tutorial for instructions on that. This tutorial is actually what I used to get my first foothold in scripting.

The script there, called roll5, has a few extra lines pertaining to the camera that you won't need, and acceleration/deceleration may also be inappropriate in your case.

 

On 8/30/2019 at 10:36 AM, nbohr1more said:

 

Thanks guys! I got the speaker to move along the spline just fine! The only problem is that it moves there and stops, I want it to continuously move back and forth along the spline. I assume a bit of script-fu could solve that, but I don't know what I would need to add. This is what the script looks like at the moment:

void Roll5()
{

   $Mover5.time(25);              // How many seconds it will take to move along the spline
   $Mover5.startSpline($Spline5); // Start the func_mover $Mover5 moving along $Spline5

}

 

My Fan Missions:

   Series:                                                                           Standalone:

Chronicles of Skulduggery 0: To Catch a Thief                     The Night of Reluctant Benefaction

Chronicles of Skulduggery 1: Pearls and Swine                    Langhorne Lodge

Chronicles of Skulduggery 2: A Precarious Position              

Chronicles of Skulduggery 3: Sacricide

 

 

 

Link to comment
Share on other sites

@Bienie to get the script to repeat you can insert a while(1){} so that your 2 mover5 lines are within the curly brackets. You'll need to add a 3rd line sys.waitFor($Mover5); so that the script doesn't try to repeat the script an infinite number of times per second ('runaway loop'). There's a finished example in Down by the Riverside's Invernesse map, look for wisps.

If you want it to go back and forth you'd have to extend the spline path to retrace  its path back to the starting point. Or duplicate your spline path, mirror it in all 3 axes and extend your script to use 2 spline paths.

Link to comment
Share on other sites

16 hours ago, Dragofer said:

@Bienie to get the script to repeat you can insert a while(1){} so that your 2 mover5 lines are within the curly brackets. You'll need to add a 3rd line sys.waitFor($Mover5); so that the script doesn't try to repeat the script an infinite number of times per second ('runaway loop'). There's a finished example in Down by the Riverside's Invernesse map, look for wisps.

If you want it to go back and forth you'd have to extend the spline path to retrace  its path back to the starting point. Or duplicate your spline path, mirror it in all 3 axes and extend your script to use 2 spline paths.

I think I get what you're saying, I'll try adding those lines to the script and see if it repeats at least. In order to retrace the path of the spline I would need to add more nodes to it, is that possible? I didn't see a button for it, and the cutscene tutorial doesn't mention it.

My Fan Missions:

   Series:                                                                           Standalone:

Chronicles of Skulduggery 0: To Catch a Thief                     The Night of Reluctant Benefaction

Chronicles of Skulduggery 1: Pearls and Swine                    Langhorne Lodge

Chronicles of Skulduggery 2: A Precarious Position              

Chronicles of Skulduggery 3: Sacricide

 

 

 

Link to comment
Share on other sites

@Bienie You can append more nodes to a NURBS curve, like the one used in the spline, by using the curve-related buttons at the bottom of the left pane of DR's interface.

  • Like 1
Link to comment
Share on other sites

What exactly does the translucent keyword do?

https://www.iddevnet.com/doom3/materials.html says it draws 'with an alpha blend'.

A source I can't find any more rich_is_bored in this archived discussion said it averaged the source and destination colours.

https://modwiki.dhewm3.org/Translucent_(Material_global_keyword) says it renders 'at 50% transparency'. (It doesn't detail the actual calculation.)

http://wiki.thedarkmod.com/index.php?title=Making_Semi-transparent_textures includes a comment saying it 'avoids implicit opaque black stage used for filling the depth buffer' (but the only stage in that material uses blend add, so I'd have thought it would be redundant there).

SteveL used to think it used screen door transparency, but changed his mind. In particular, his comment here about it maybe drawing (additively) after the opaque surfaces seems consistent with my experimental results (and with that comment above about it not clearing the destination to black first).

Edited by VanishedOne
  • Confused 1

Some things I'm repeatedly thinking about...

 

- louder scream when you're dying

Link to comment
Share on other sites

I want to give a brush texture the illusion that it radiates light, but I prefer not to use a light source so I can cut down on the number of light sources in a scene. The texture just needs to be lit. It doesn't actually have to radiate light. Is it possible to have a brush face texture always fully lit, regardless whether a light source hits it?

Link to comment
Share on other sites

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

    • Petike the Taffer

      I've finally managed to log in to The Dark Mod Wiki. I'm back in the saddle and before the holidays start in full, I'll be adding a few new FM articles and doing other updates. Written in Stone is already done.
      · 4 replies
    • nbohr1more

      TDM 15th Anniversary Contest is now active! Please declare your participation: https://forums.thedarkmod.com/index.php?/topic/22413-the-dark-mod-15th-anniversary-contest-entry-thread/
       
      · 0 replies
    • JackFarmer

      @TheUnbeholden
      You cannot receive PMs. Could you please be so kind and check your mailbox if it is full (or maybe you switched off the function)?
      · 1 reply
    • OrbWeaver

      I like the new frob highlight but it would nice if it was less "flickery" while moving over objects (especially barred metal doors).
      · 4 replies
    • nbohr1more

      Please vote in the 15th Anniversary Contest Theme Poll
       
      · 0 replies
×
×
  • Create New...